UNPKG

@jfln/marvin-db

Version:

biblioteca de objetos para normalizar o acesso a um banco mongo db

38 lines (29 loc) 780 B
import {Entity, Property, Enum} from '@mikro-orm/core' import {BaseEntity} from '../BaseEntity' @Entity({tableName: 'setting-confession'}) export class SettingsConfession extends BaseEntity { @Property() color: string @Property() comment: string @Property() number: number public setColor(color: string): SettingsConfession { this.color = color return this } public setComment(comment: string): SettingsConfession { this.comment = comment return this } public setNumber(number: number): SettingsConfession { this.number = number return this } constructor(guildId: string, color: string, comment: string, number: number) { super(guildId) this.color = color this.comment = comment this.number = number } }