update: order for compounding medicine, now ir can be ordered different compounding
This commit is contained in:
@ -7,7 +7,9 @@ import {
|
||||
DeleteDateColumn,
|
||||
OneToMany,
|
||||
ManyToOne,
|
||||
JoinColumn
|
||||
JoinColumn,
|
||||
ManyToMany,
|
||||
JoinTable
|
||||
} from "typeorm";
|
||||
|
||||
import { EmrRegistrationOutpatient } from "./emr_registration_outpatient";
|
||||
@ -44,9 +46,20 @@ export class EmrPharmacyOrderList {
|
||||
@JoinColumn()
|
||||
emrregistrationoutpatient: EmrRegistrationOutpatient;
|
||||
|
||||
@ManyToOne(() => EmrCompoundingMedicine, { onDelete: "CASCADE" })
|
||||
@JoinColumn()
|
||||
emrcompoundingmedicine: EmrCompoundingMedicine;
|
||||
@Column({
|
||||
type: 'text',
|
||||
nullable: true,
|
||||
array: true,
|
||||
})
|
||||
emrcompoundingmedicine: string[];
|
||||
|
||||
@ManyToMany(() => EmrCompoundingMedicine)
|
||||
@JoinTable({
|
||||
name: "compounding_medicine_order_list",
|
||||
joinColumn: { name: "emr_pharmacy_order_list_id", referencedColumnName: "id" },
|
||||
inverseJoinColumn: { name: "emr_compounding_medicine_id", referencedColumnName: "id" },
|
||||
})
|
||||
emrcompoundingmedicines: EmrCompoundingMedicine[];
|
||||
|
||||
@ManyToOne(() => EmrPrescription, { onDelete: "CASCADE" })
|
||||
@JoinColumn()
|
||||
|
||||
Reference in New Issue
Block a user