22 lines
485 B
TypeScript
22 lines
485 B
TypeScript
|
import { Column, Entity, ManyToOne, PrimaryGeneratedColumn } from "typeorm";
|
||
|
import { protocol } from "./protocol";
|
||
|
|
||
|
@Entity()
|
||
|
export class protocolDecisions {
|
||
|
@PrimaryGeneratedColumn("increment")
|
||
|
id: string;
|
||
|
|
||
|
@Column({ type: "varchar", length: 255 })
|
||
|
topic: string;
|
||
|
|
||
|
@Column({ type: "varchar", length: 255, default: "" })
|
||
|
context: string;
|
||
|
|
||
|
@ManyToOne(() => protocol, {
|
||
|
nullable: false,
|
||
|
onDelete: "CASCADE",
|
||
|
onUpdate: "RESTRICT",
|
||
|
})
|
||
|
protocol: protocol;
|
||
|
}
|