Files
markov-discord/src/entity/Channel.ts
2021-12-23 21:54:42 -06:00

18 lines
381 B
TypeScript

/* eslint-disable import/no-cycle */
import { PrimaryColumn, Entity, ManyToOne, BaseEntity, Column } from 'typeorm';
import { Guild } from './Guild';
@Entity()
export class Channel extends BaseEntity {
@PrimaryColumn({ type: 'text' })
id: string;
@Column({
default: false,
})
listen: boolean;
@ManyToOne(() => Guild, (guild) => guild.channels)
guild: Guild;
}