19 lines
512 B
TypeScript
19 lines
512 B
TypeScript
import { Column, Entity, ManyToMany, PrimaryColumn } from "typeorm";
|
|
import { member } from "./member";
|
|
|
|
@Entity()
|
|
export class qualification {
|
|
@PrimaryColumn({ generated: "uuid", type: "varchar", length: 36 })
|
|
id: string;
|
|
|
|
@Column({ type: "varchar", length: 255 })
|
|
qualification: string;
|
|
|
|
@Column({ type: "varchar", length: 255, nullable: true, default: null })
|
|
description?: string;
|
|
|
|
@ManyToMany(() => member, (member) => member.positions, {
|
|
onDelete: "RESTRICT",
|
|
})
|
|
members: member[];
|
|
}
|