import { Column, Entity, ManyToOne, PrimaryGeneratedColumn } from "typeorm"; import { protocol } from "./protocol"; @Entity() export class protocolDecision { @PrimaryGeneratedColumn("increment") id: number; @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; }