53 lines
2 KiB
TypeScript
53 lines
2 KiB
TypeScript
|
|
import { Entity, Column, ManyToOne, JoinColumn, OneToOne } from "typeorm";
|
||
|
|
import { EntityBase } from "./base/Base";
|
||
|
|
import { Evaluation } from "./Evaluation";
|
||
|
|
|
||
|
|
@Entity("salary")
|
||
|
|
export class Salary extends EntityBase {
|
||
|
|
@Column({
|
||
|
|
comment: "Id การทำรายการระบบประเมิน",
|
||
|
|
length: 40,
|
||
|
|
default: "00000000-0000-0000-0000-000000000000",
|
||
|
|
})
|
||
|
|
evaluationId: string;
|
||
|
|
|
||
|
|
@Column({ nullable: true, type: "datetime", comment: "วัน เดือน ปี รับตำแหน่ง" })
|
||
|
|
date: Date;
|
||
|
|
|
||
|
|
@Column({ nullable: true, type: "double precision", comment: "เงินเดือน" })
|
||
|
|
amount: number;
|
||
|
|
|
||
|
|
@Column({ nullable: true, type: "double precision", comment: "เงินประจำตำแหน่ง" })
|
||
|
|
positionSalaryAmount: number;
|
||
|
|
|
||
|
|
@Column({ nullable: true, type: "double precision", comment: "เงินค่าตอบแทนรายเดือน" })
|
||
|
|
mouthSalaryAmount: number;
|
||
|
|
|
||
|
|
@Column({ nullable: true, comment: "ตำแหน่ง" })
|
||
|
|
position: string;
|
||
|
|
|
||
|
|
@Column({ nullable: true, comment: "เลขที่ตำแหน่ง" })
|
||
|
|
posNo: string;
|
||
|
|
|
||
|
|
@Column({ nullable: true, comment: "ตำแหน่ง (รายละเอียด)" })
|
||
|
|
salaryClass: string;
|
||
|
|
|
||
|
|
@Column({ nullable: true, comment: "เอกสารอ้างอิง" })
|
||
|
|
salaryRef: string;
|
||
|
|
|
||
|
|
@Column({ nullable: true, comment: "เอกสารอ้างอิง (เลขที่คำสั่ง)" })
|
||
|
|
refCommandNo: string;
|
||
|
|
|
||
|
|
@Column({ nullable: true, type: "datetime", comment: "เอกสารอ้างอิง (ลงวันที่)" })
|
||
|
|
refCommandDate: Date;
|
||
|
|
|
||
|
|
@Column({ nullable: true, comment: "ประเภทตำแหน่งกรณีพิเศษ" })
|
||
|
|
salaryStatus: string;
|
||
|
|
|
||
|
|
@ManyToOne(() => Evaluation, (Evaluation) => Evaluation.salaries)
|
||
|
|
@JoinColumn({ name: "evaluationId" })
|
||
|
|
evaluation: Evaluation;
|
||
|
|
}
|
||
|
|
|
||
|
|
export type UpdateSalary = Partial<Salary>;
|