update: service cashier done
This commit is contained in:
@ -7,20 +7,26 @@ import {
|
|||||||
DeleteDateColumn,
|
DeleteDateColumn,
|
||||||
JoinColumn,
|
JoinColumn,
|
||||||
OneToOne,
|
OneToOne,
|
||||||
|
OneToMany,
|
||||||
|
ManyToOne
|
||||||
} from "typeorm";
|
} from "typeorm";
|
||||||
import { EmrRegistration } from "../emr/emr_registration";
|
import { EmrRegistration } from "../emr/emr_registration";
|
||||||
import { Room } from "../room";
|
import { Room } from "../room";
|
||||||
|
import { CashierItem } from "./cashier_item";
|
||||||
|
|
||||||
@Entity("cashiers", { schema: "cashier" })
|
@Entity("cashiers", { schema: "cashier" })
|
||||||
export class Cashier {
|
export class Cashier {
|
||||||
@PrimaryGeneratedColumn("uuid")
|
@PrimaryGeneratedColumn("uuid")
|
||||||
id: string;
|
id: string;
|
||||||
|
|
||||||
@OneToOne(() => EmrRegistration, { onDelete: "CASCADE" })
|
@ManyToOne(() => EmrRegistration, { onDelete: "CASCADE" })
|
||||||
@JoinColumn()
|
@JoinColumn()
|
||||||
emrregistration: EmrRegistration;
|
emrregistration: EmrRegistration;
|
||||||
|
|
||||||
@OneToOne(() => Room, { onDelete: "CASCADE" })
|
@OneToMany(() => CashierItem, (detail) => detail.cashier)
|
||||||
|
cashieritem: CashierItem[];
|
||||||
|
|
||||||
|
@ManyToOne(() => Room, { onDelete: "CASCADE" })
|
||||||
@JoinColumn()
|
@JoinColumn()
|
||||||
room: Room;
|
room: Room;
|
||||||
|
|
||||||
|
|||||||
@ -2,7 +2,12 @@
|
|||||||
"compilerOptions": {
|
"compilerOptions": {
|
||||||
"target": "es6",
|
"target": "es6",
|
||||||
"module": "commonjs",
|
"module": "commonjs",
|
||||||
"lib": ["dom", "es6", "es2017", "esnext.asynciterable"],
|
"lib": [
|
||||||
|
"dom",
|
||||||
|
"es6",
|
||||||
|
"es2017",
|
||||||
|
"esnext.asynciterable"
|
||||||
|
],
|
||||||
"sourceMap": true,
|
"sourceMap": true,
|
||||||
"outDir": "./dist",
|
"outDir": "./dist",
|
||||||
"rootDir": "./",
|
"rootDir": "./",
|
||||||
@ -13,15 +18,28 @@
|
|||||||
"emitDecoratorMetadata": true,
|
"emitDecoratorMetadata": true,
|
||||||
"experimentalDecorators": true,
|
"experimentalDecorators": true,
|
||||||
"resolveJsonModule": true,
|
"resolveJsonModule": true,
|
||||||
"typeRoots": ["./src/types", "./node_modules/@types"],
|
"ignoreDeprecations": "5.0",
|
||||||
|
"typeRoots": [
|
||||||
|
"./src/types",
|
||||||
|
"./node_modules/@types"
|
||||||
|
],
|
||||||
// "baseUrl": "src/",
|
// "baseUrl": "src/",
|
||||||
"noImplicitReturns": true,
|
"noImplicitReturns": true,
|
||||||
"noFallthroughCasesInSwitch": true
|
"noFallthroughCasesInSwitch": true,
|
||||||
// "allowJs": true,
|
// "allowJs": true,
|
||||||
// "declaration": true
|
// "declaration": true
|
||||||
// "emitDeclarationOnly": true,
|
// "emitDeclarationOnly": true,
|
||||||
// "declarationMap": true
|
// "declarationMap": true
|
||||||
|
"strictPropertyInitialization": false
|
||||||
},
|
},
|
||||||
"include": ["src/swagger-output.json", "src/langs/json/*.json", "./src/**/*.tsx", "./src/**/*.ts"],
|
"include": [
|
||||||
"exclude": ["node_modules", "test/**/*.ts"]
|
"src/swagger-output.json",
|
||||||
|
"src/langs/json/*.json",
|
||||||
|
"./src/**/*.tsx",
|
||||||
|
"./src/**/*.ts"
|
||||||
|
],
|
||||||
|
"exclude": [
|
||||||
|
"node_modules",
|
||||||
|
"test/**/*.ts"
|
||||||
|
]
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user