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
3 years ago
|
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({
|
||
3 years ago
|
enum: ['normalUser', 'pluginBot', 'openapiBot'],
|
||
3 years ago
|
default: 'normalUser',
|
||
|
})
|
||
|
type: string;
|
||
|
|
||
|
@Column({
|
||
|
default: {},
|
||
|
})
|
||
|
settings: string;
|
||
|
}
|