maybe fix mariadb

This commit is contained in:
diced 2021-03-26 15:04:06 -07:00
parent 0bd83f731f
commit 1745298f47
No known key found for this signature in database
GPG key ID: 9F93C5E963C42895
4 changed files with 9 additions and 9 deletions

View file

@ -2,10 +2,10 @@ import { Entity, Column, PrimaryColumn } from 'typeorm';
@Entity({ name: 'zipline_images' })
export class Image {
@PrimaryColumn('text')
@PrimaryColumn('varchar', { length: 255 })
public id: string;
@Column('text', { default: null })
@Column('varchar', { default: null, length: 255 })
public file: string;
@Column('bigint')

View file

@ -5,10 +5,10 @@ export class URL {
@PrimaryColumn('text')
public id: string;
@Column('text', { default: null })
@Column('varchar', { default: null, length: 255 })
public url: string;
@Column('text', { default: null, nullable: true })
@Column('varchar', { default: null, nullable: true, length: 255 })
public vanity: string;
@Column('bigint')

View file

@ -5,19 +5,19 @@ export class User {
@PrimaryGeneratedColumn()
public id: number;
@Column('text')
@Column('varchar', { length: 255 })
public username: string;
@Column('text')
@Column('varchar', { length: 255 })
public password: string;
@Column('text', { default: null }) /* used for gravatar avatar! */
@Column('varchar', { default: null, length: 255 }) /* used for gravatar avatar! */
public email: string;
@Column('boolean', { default: false })
public administrator: boolean;
@Column('text')
@Column('varchar', { length: 255 })
public token: string;
@Column('simple-json', { default: null })

View file

@ -3,7 +3,7 @@ import { Entity, Column, PrimaryColumn } from 'typeorm';
// this will be used for more stuff other than first setups
@Entity({ name: 'zipline_data' })
export class Zipline {
@PrimaryColumn('text')
@PrimaryColumn('varchar', { length: 255 })
public id: string;
@Column('boolean', { default: true })