36 lines
559 B
TypeScript
36 lines
559 B
TypeScript
import {
|
|
Entity,
|
|
PrimaryColumn,
|
|
Column,
|
|
Index
|
|
} from 'typeorm';
|
|
|
|
@Entity('server_bans')
|
|
export class ServerBanEntity {
|
|
@PrimaryColumn('text')
|
|
id!: string;
|
|
|
|
@Index()
|
|
@Column('text')
|
|
serverId!: string;
|
|
|
|
@Index()
|
|
@Column('text')
|
|
userId!: string;
|
|
|
|
@Column('text')
|
|
bannedBy!: string;
|
|
|
|
@Column('text', { nullable: true })
|
|
displayName!: string | null;
|
|
|
|
@Column('text', { nullable: true })
|
|
reason!: string | null;
|
|
|
|
@Column('integer', { nullable: true })
|
|
expiresAt!: number | null;
|
|
|
|
@Column('integer')
|
|
createdAt!: number;
|
|
}
|