diff --git a/plugins/tickets/src/entity/Template.entry.ts b/plugins/tickets/src/entity/Template.entry.ts index e92c4004..ede7a31d 100644 --- a/plugins/tickets/src/entity/Template.entry.ts +++ b/plugins/tickets/src/entity/Template.entry.ts @@ -1,5 +1,5 @@ import { APIEmbed } from "discord.js"; -import { BaseEntity, Column, Entity, ManyToOne, OneToMany, PrimaryGeneratedColumn, Relation } from "typeorm"; +import { BaseEntity, Column, CreateDateColumn, Entity, ManyToOne, OneToMany, PrimaryGeneratedColumn, Relation, UpdateDateColumn } from "typeorm"; import Guild from "./Guild.entry.js"; import Ticket from "./Ticket.entry.js"; @@ -19,84 +19,104 @@ export interface Select { emoji: string } -interface Category { +export interface Category { title: string emoji: string } +export interface System { + name: string + isEnabled: boolean +} + @Entity({ name: 'tickets_templates' }) export default class Template extends BaseEntity { - @PrimaryGeneratedColumn() - id!: number - - @ManyToOne(() => Guild, (guild) => guild.templates, { cascade: true }) - guild!: Relation - - @OneToMany(() => Ticket, (ticket) => ticket.template) - tickets!: Relation