16 lines
407 B
TypeScript
16 lines
407 B
TypeScript
import { Column, Entity, OneToMany, PrimaryColumn } from "typeorm";
|
|
import { member_awards } from "./member_awards";
|
|
|
|
@Entity()
|
|
export class award {
|
|
@PrimaryColumn({ generated: "increment", type: "int" })
|
|
id: number;
|
|
|
|
@Column({ type: "varchar", length: 255 })
|
|
award: string;
|
|
|
|
@OneToMany(() => member_awards, (member) => member.award, {
|
|
onDelete: "RESTRICT",
|
|
})
|
|
members: member_awards[];
|
|
}
|