import { Column, Entity, PrimaryGeneratedColumn } from 'typeorm';

@Entity('chat_ads')
export class ChatAdEntity {
    @PrimaryGeneratedColumn() id: number;
    @Column({ type: 'varchar', width: 40 }) character_name: string;
    @Column({ type: 'int' }) character_id: number;
    @Column({ type: 'int' }) account_id: number;
    @Column({ type: 'varchar', width: 296 }) advert: string;
    @Column({ type: 'datetime' }) time: Date;
    @Column({ type: 'int' }) paid: number;
    @Column({ type: 'datetime', default: null, nullable: true }) aired: Date | null;
    @Column({ type: 'datetime', default: null, nullable: true }) removed: Date | null;
    @Column({ type: 'varchar', width: 40, default: null, nullable: true }) removed_by: string | null;

    @Column({ type: 'boolean', default: false }) premium: boolean;
}
