228 lines
3.7 KiB
TypeScript
228 lines
3.7 KiB
TypeScript
|
|
import { Entity, Column, ManyToOne, JoinColumn, OneToOne, OneToMany } from "typeorm";
|
||
|
|
import { EntityBase } from "./base/Base";
|
||
|
|
|
||
|
|
@Entity("salaryProfile")
|
||
|
|
export class SalaryProfile extends EntityBase {
|
||
|
|
@Column({
|
||
|
|
comment: "",
|
||
|
|
length: 40,
|
||
|
|
})
|
||
|
|
salaryOrgId: string;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
nullable: true,
|
||
|
|
comment: "คำนำหน้า",
|
||
|
|
length: 255,
|
||
|
|
default: null,
|
||
|
|
})
|
||
|
|
prefix: string;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
nullable: true,
|
||
|
|
comment: "ชื่อ",
|
||
|
|
length: 255,
|
||
|
|
default: null,
|
||
|
|
})
|
||
|
|
firstName: string;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
nullable: true,
|
||
|
|
comment: "สกุล",
|
||
|
|
length: 255,
|
||
|
|
default: null,
|
||
|
|
})
|
||
|
|
lastName: string;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
comment:"เลขที่ตำแหน่ง",
|
||
|
|
})
|
||
|
|
posNumber : number;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
nullable: true,
|
||
|
|
comment: "ตำแหน่ง",
|
||
|
|
length: 255,
|
||
|
|
default: null,
|
||
|
|
})
|
||
|
|
position: string;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
comment: "ประเภทตำแหน่ง",
|
||
|
|
length: 40,
|
||
|
|
})
|
||
|
|
posTypeId: string;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
comment: "ระดับตำแหน่ง",
|
||
|
|
length: 40,
|
||
|
|
})
|
||
|
|
posLevelId: string;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
comment: "เงินเดือนฐาน",
|
||
|
|
})
|
||
|
|
amount: number;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
comment: "จำนวนเงินที่ใช้เลื่อน",
|
||
|
|
})
|
||
|
|
amountUse: number;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
comment: "เงินเดือนหลังเลื่อน",
|
||
|
|
})
|
||
|
|
positionSalaryAmount: number;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
nullable: true,
|
||
|
|
comment: "ประเภทการเลื่อน NONE->ไม่ได้เลื่อน HAFT->ครึ่งขั้น FULL->1ขั้น FULLHAFT->1.5ขั้น group กลุ่ม GROUP1->กลุ่ม1 GROUP2->กลุ่ม2",
|
||
|
|
length: 255,
|
||
|
|
default: null,
|
||
|
|
})
|
||
|
|
type: string;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
comment: "",
|
||
|
|
length: 40,
|
||
|
|
})
|
||
|
|
rootId: string;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
nullable: true,
|
||
|
|
comment: "",
|
||
|
|
length: 255,
|
||
|
|
default: null,
|
||
|
|
})
|
||
|
|
root: string;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
comment: "",
|
||
|
|
length: 40,
|
||
|
|
})
|
||
|
|
child1Id: string;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
nullable: true,
|
||
|
|
comment: "",
|
||
|
|
length: 255,
|
||
|
|
default: null,
|
||
|
|
})
|
||
|
|
child1: string;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
comment: "",
|
||
|
|
length: 40,
|
||
|
|
})
|
||
|
|
child2Id: string;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
nullable: true,
|
||
|
|
comment: "",
|
||
|
|
length: 255,
|
||
|
|
default: null,
|
||
|
|
})
|
||
|
|
child2: string;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
comment: "",
|
||
|
|
length: 40,
|
||
|
|
})
|
||
|
|
child3Id: string;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
nullable: true,
|
||
|
|
comment: "",
|
||
|
|
length: 255,
|
||
|
|
default: null,
|
||
|
|
})
|
||
|
|
child3: string;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
comment: "",
|
||
|
|
length: 40,
|
||
|
|
})
|
||
|
|
child4Id: string;
|
||
|
|
|
||
|
|
@Column({
|
||
|
|
nullable: true,
|
||
|
|
comment: "",
|
||
|
|
length: 255,
|
||
|
|
default: null,
|
||
|
|
})
|
||
|
|
child4: string;
|
||
|
|
|
||
|
|
}
|
||
|
|
|
||
|
|
export class CreateSalaryProfile {
|
||
|
|
|
||
|
|
@Column("uuid")
|
||
|
|
salaryOrgId: string;
|
||
|
|
|
||
|
|
@Column()
|
||
|
|
prefix: string;
|
||
|
|
|
||
|
|
@Column()
|
||
|
|
firstName: string;
|
||
|
|
|
||
|
|
@Column()
|
||
|
|
lastName: string;
|
||
|
|
|
||
|
|
@Column()
|
||
|
|
posNumber : number;
|
||
|
|
|
||
|
|
@Column()
|
||
|
|
position: string;
|
||
|
|
|
||
|
|
@Column("uuid")
|
||
|
|
posTypeId: string;
|
||
|
|
|
||
|
|
@Column("uuid")
|
||
|
|
posLevelId: string;
|
||
|
|
|
||
|
|
@Column()
|
||
|
|
amount: number;
|
||
|
|
|
||
|
|
@Column()
|
||
|
|
amountUse: number;
|
||
|
|
|
||
|
|
@Column()
|
||
|
|
positionSalaryAmount: number;
|
||
|
|
|
||
|
|
@Column()
|
||
|
|
type: string;
|
||
|
|
|
||
|
|
@Column("uuid")
|
||
|
|
rootId: string;
|
||
|
|
|
||
|
|
@Column()
|
||
|
|
root: string;
|
||
|
|
|
||
|
|
@Column("uuid")
|
||
|
|
child1Id: string;
|
||
|
|
|
||
|
|
@Column()
|
||
|
|
child1: string;
|
||
|
|
|
||
|
|
@Column("uuid")
|
||
|
|
child2Id: string;
|
||
|
|
|
||
|
|
@Column()
|
||
|
|
child2: string;
|
||
|
|
|
||
|
|
@Column("uuid")
|
||
|
|
child3Id: string;
|
||
|
|
|
||
|
|
@Column()
|
||
|
|
child3: string;
|
||
|
|
|
||
|
|
@Column("uuid")
|
||
|
|
child4Id: string;
|
||
|
|
|
||
|
|
@Column()
|
||
|
|
child4: string;
|
||
|
|
|
||
|
|
|
||
|
|
}
|
||
|
|
|
||
|
|
export type UpdateSalaryProfile = Partial<CreateSalaryProfile>;
|