update: add relation emr registration in external consultation
This commit is contained in:
@ -10,6 +10,7 @@ import {
|
||||
ManyToOne,
|
||||
} from "typeorm";
|
||||
import { RefferalHospital } from "../refferal_hospital";
|
||||
import { EmrRegistration } from "./emr_registration";
|
||||
|
||||
@Entity("emr_external_consultation", { schema: "emr" })
|
||||
export class EmrExternalConsultation {
|
||||
@ -20,6 +21,10 @@ export class EmrExternalConsultation {
|
||||
@JoinColumn()
|
||||
refferalhospital: RefferalHospital;
|
||||
|
||||
@OneToOne(() => EmrRegistration, { onDelete: "CASCADE" })
|
||||
@JoinColumn()
|
||||
emrregistration: EmrRegistration;
|
||||
|
||||
@Column({ nullable: true, type: "text" })
|
||||
notes: string;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user