mirror of https://github.com/msgbyte/tailchat
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
44 lines
596 B
TypeScript
44 lines
596 B
TypeScript
import { Entity, ObjectIdColumn, Column, PrimaryColumn } from 'tushan';
|
|
|
|
@Entity({
|
|
name: 'users',
|
|
})
|
|
export class User {
|
|
@ObjectIdColumn()
|
|
_id!: string;
|
|
|
|
@Column()
|
|
username!: string;
|
|
|
|
@Column()
|
|
email!: string;
|
|
|
|
@Column()
|
|
password!: string;
|
|
|
|
@Column()
|
|
nickname!: string;
|
|
|
|
@Column()
|
|
discriminator!: string;
|
|
|
|
@Column({
|
|
default: false,
|
|
})
|
|
temporary!: boolean;
|
|
|
|
@Column()
|
|
avatar!: boolean;
|
|
|
|
@Column({
|
|
enum: ['normalUser', 'pluginBot', 'openapiBot'],
|
|
default: 'normalUser',
|
|
})
|
|
type: string;
|
|
|
|
@Column({
|
|
default: {},
|
|
})
|
|
settings: string;
|
|
}
|