add entity org part 2
This commit is contained in:
parent
8717494690
commit
d5e79acb82
11 changed files with 1442 additions and 1 deletions
|
|
@ -13,6 +13,9 @@ import { ProfileHonor } from "./ProfileHonor";
|
||||||
import { ProfileAssessment } from "./ProfileAssessment";
|
import { ProfileAssessment } from "./ProfileAssessment";
|
||||||
import { ProfileLeave } from "./ProfileLeave";
|
import { ProfileLeave } from "./ProfileLeave";
|
||||||
import { ProfileAbility } from "./ProfileAbility";
|
import { ProfileAbility } from "./ProfileAbility";
|
||||||
|
import { ProfileDuty } from "./ProfileDutys";
|
||||||
|
import { ProfileNopaid } from "./ProfileNopaid";
|
||||||
|
import { ProfileOther } from "./ProfileOther";
|
||||||
|
|
||||||
@Entity("profile")
|
@Entity("profile")
|
||||||
export class Profile extends EntityBase {
|
export class Profile extends EntityBase {
|
||||||
|
|
@ -169,6 +172,15 @@ export class Profile extends EntityBase {
|
||||||
@OneToMany(() => ProfileAbility, (profileAbility) => profileAbility.profile)
|
@OneToMany(() => ProfileAbility, (profileAbility) => profileAbility.profile)
|
||||||
profileAbilities: ProfileAbility[];
|
profileAbilities: ProfileAbility[];
|
||||||
|
|
||||||
|
@OneToMany(() => ProfileDuty, (profileDuty) => profileDuty.profile)
|
||||||
|
profileDutys: ProfileDuty[];
|
||||||
|
|
||||||
|
@OneToMany(() => ProfileNopaid, (profileNopaid) => profileNopaid.profile)
|
||||||
|
profileNopaids: ProfileNopaid[];
|
||||||
|
|
||||||
|
@OneToMany(() => ProfileOther, (profileOther) => profileOther.profile)
|
||||||
|
profileOthers: ProfileOther[];
|
||||||
|
|
||||||
@ManyToOne(() => PosLevel, (posLevel) => posLevel.posLevels)
|
@ManyToOne(() => PosLevel, (posLevel) => posLevel.posLevels)
|
||||||
@JoinColumn({ name: "posLevelId" })
|
@JoinColumn({ name: "posLevelId" })
|
||||||
posLevel: PosLevel;
|
posLevel: PosLevel;
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
import { Entity, Column, ManyToOne, JoinColumn } from "typeorm";
|
import { Entity, Column, ManyToOne, JoinColumn, OneToMany } from "typeorm";
|
||||||
import { EntityBase } from "./base/Base";
|
import { EntityBase } from "./base/Base";
|
||||||
import { Profile } from "./Profile";
|
import { Profile } from "./Profile";
|
||||||
|
import { ProfileDisciplineHistory } from "./ProfileDisciplineHistory";
|
||||||
|
|
||||||
@Entity("profileDiscipline")
|
@Entity("profileDiscipline")
|
||||||
export class ProfileDiscipline extends EntityBase {
|
export class ProfileDiscipline extends EntityBase {
|
||||||
|
|
@ -19,6 +20,55 @@ export class ProfileDiscipline extends EntityBase {
|
||||||
})
|
})
|
||||||
profileId: string;
|
profileId: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
comment: "สถานะการใช้งาน",
|
||||||
|
default: false,
|
||||||
|
})
|
||||||
|
isActive: boolean;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "ระดับความผิด",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
level: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "รายละเอียด",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
detail: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "datetime",
|
||||||
|
comment: "เอกสารอ้างอิง (ลงวันที่)",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
refCommandDate: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "เอกสารอ้างอิง (เลขที่คำสั่ง)",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
refCommandNo: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "ล้างมลทิน",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
unStigma: string;
|
||||||
|
|
||||||
|
@OneToMany(() => ProfileDisciplineHistory, (profileDisciplineHistory) => profileDisciplineHistory.histories)
|
||||||
|
profileDisciplineHistories: ProfileDisciplineHistory[];
|
||||||
|
|
||||||
@ManyToOne(() => Profile, (profile) => profile.profileDiscipline)
|
@ManyToOne(() => Profile, (profile) => profile.profileDiscipline)
|
||||||
@JoinColumn({ name: "profileId" })
|
@JoinColumn({ name: "profileId" })
|
||||||
profile: Profile;
|
profile: Profile;
|
||||||
|
|
|
||||||
72
src/entities/ProfileDisciplineHistory.ts
Normal file
72
src/entities/ProfileDisciplineHistory.ts
Normal file
|
|
@ -0,0 +1,72 @@
|
||||||
|
import { Entity, Column, ManyToOne, JoinColumn } from "typeorm";
|
||||||
|
import { EntityBase } from "./base/Base";
|
||||||
|
import { Profile } from "./Profile";
|
||||||
|
import { ProfileDiscipline } from "./ProfileDiscipline";
|
||||||
|
|
||||||
|
@Entity("profileDisciplineHistory")
|
||||||
|
export class ProfileDisciplineHistory extends EntityBase {
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "datetime",
|
||||||
|
comment: "วันที่",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
date: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
length: 40,
|
||||||
|
comment: "ล้างมลทิน",
|
||||||
|
type: "uuid",
|
||||||
|
})
|
||||||
|
profileDisciplineId: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
comment: "สถานะการใช้งาน",
|
||||||
|
default: false,
|
||||||
|
})
|
||||||
|
isActive: boolean;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "ระดับความผิด",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
level: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "รายละเอียด",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
detail: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "datetime",
|
||||||
|
comment: "เอกสารอ้างอิง (ลงวันที่)",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
refCommandDate: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "เอกสารอ้างอิง (เลขที่คำสั่ง)",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
refCommandNo: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "ล้างมลทิน",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
unStigma: string;
|
||||||
|
|
||||||
|
@ManyToOne(() => ProfileDiscipline, (profileDiscipline) => profileDiscipline.profileDisciplineHistories)
|
||||||
|
@JoinColumn({ name: "profileDisciplineId" })
|
||||||
|
histories: ProfileDiscipline;
|
||||||
|
}
|
||||||
104
src/entities/ProfileDutyHistory.ts
Normal file
104
src/entities/ProfileDutyHistory.ts
Normal file
|
|
@ -0,0 +1,104 @@
|
||||||
|
import { Entity, Column, ManyToOne, JoinColumn } from "typeorm";
|
||||||
|
import { EntityBase } from "./base/Base";
|
||||||
|
import { Profile } from "./Profile";
|
||||||
|
import { ProfileDuty } from "./ProfileDutys";
|
||||||
|
|
||||||
|
@Entity("profileDutyHistory")
|
||||||
|
export class ProfileDutyHistory extends EntityBase {
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
comment: "สถานะการใช้งาน",
|
||||||
|
default: false,
|
||||||
|
})
|
||||||
|
isActive: boolean;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "datetime",
|
||||||
|
comment: "เริ่มต้น",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
dateStart: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "datetime",
|
||||||
|
comment: "สิ้นสุด",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
dateEnd: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "รายละเอียด",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
detail: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "เอกสารอ้างอิง",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
reference: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "datetime",
|
||||||
|
comment: "เอกสารอ้างอิง (ลงวันที่)",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
refCommandDate: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "เอกสารอ้างอิง (เลขที่คำสั่ง)",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
refCommandNo: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "คีย์นอก(FK)ของตาราง ProfileDuty",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
profileDutyId: string;
|
||||||
|
|
||||||
|
|
||||||
|
@ManyToOne(() => ProfileDuty, (profileDuty) => profileDuty.profileDutyHistories)
|
||||||
|
@JoinColumn({ name: "profileDutyId" })
|
||||||
|
histories: ProfileDuty;
|
||||||
|
}
|
||||||
|
|
||||||
|
export class CreateProfileDutyHistory {
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
isActive: boolean;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
dateStart: Date | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
dateEnd: Date | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
detail: string | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
reference: string | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
refCommandDate: Date | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
refCommandNo: string | null;
|
||||||
|
|
||||||
|
@Column("uuid")
|
||||||
|
profileDutyId: string | null;
|
||||||
|
}
|
||||||
|
|
||||||
|
export type UpdateProfileDutyHistory = Partial<CreateProfileDutyHistory>;
|
||||||
104
src/entities/ProfileDutys.ts
Normal file
104
src/entities/ProfileDutys.ts
Normal file
|
|
@ -0,0 +1,104 @@
|
||||||
|
import { Entity, Column, ManyToOne, JoinColumn, OneToMany } from "typeorm";
|
||||||
|
import { EntityBase } from "./base/Base";
|
||||||
|
import { Profile } from "./Profile";
|
||||||
|
import { ProfileDutyHistory } from "./ProfileDutyHistory";
|
||||||
|
|
||||||
|
@Entity("profileDuty")
|
||||||
|
export class ProfileDuty extends EntityBase {
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "คีย์นอก(FK)ของตาราง Profile",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
profileId: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
comment: "สถานะการใช้งาน",
|
||||||
|
default: false,
|
||||||
|
})
|
||||||
|
isActive: boolean;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "datetime",
|
||||||
|
comment: "เริ่มต้น",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
dateStart: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "datetime",
|
||||||
|
comment: "สิ้นสุด",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
dateEnd: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "รายละเอียด",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
detail: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "เอกสารอ้างอิง",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
reference: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "datetime",
|
||||||
|
comment: "เอกสารอ้างอิง (ลงวันที่)",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
refCommandDate: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "เอกสารอ้างอิง (เลขที่คำสั่ง)",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
refCommandNo: string;
|
||||||
|
|
||||||
|
@OneToMany(() => ProfileDutyHistory, (profileDutyHistory) => profileDutyHistory.histories)
|
||||||
|
profileDutyHistories: ProfileDutyHistory[];
|
||||||
|
|
||||||
|
@ManyToOne(() => Profile, (profile) => profile.profileDutys)
|
||||||
|
@JoinColumn({ name: "profileId" })
|
||||||
|
profile: Profile;
|
||||||
|
}
|
||||||
|
|
||||||
|
export class CreateProfileDuty {
|
||||||
|
@Column("uuid")
|
||||||
|
profileId: string | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
isActive: boolean;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
dateStart: Date | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
dateEnd: Date | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
detail: string | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
reference: string | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
refCommandDate: Date | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
refCommandNo: string | null;
|
||||||
|
}
|
||||||
|
|
||||||
|
export type UpdateProfileDuty = Partial<CreateProfileDuty>;
|
||||||
94
src/entities/ProfileNopaid.ts
Normal file
94
src/entities/ProfileNopaid.ts
Normal file
|
|
@ -0,0 +1,94 @@
|
||||||
|
import { Entity, Column, OneToMany, ManyToOne, JoinColumn } from "typeorm";
|
||||||
|
import { EntityBase } from "./base/Base";
|
||||||
|
import { Profile } from "./Profile";
|
||||||
|
import { ProfileNopaidHistory } from "./ProfileNopaidHistory";
|
||||||
|
|
||||||
|
@Entity("profileNopaid")
|
||||||
|
export class ProfileNopaid extends EntityBase {
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "คีย์นอก(FK)ของตาราง Profile",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
profileId: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
comment: "สถานะการใช้งาน",
|
||||||
|
default: false,
|
||||||
|
})
|
||||||
|
isActive: boolean;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "datetime",
|
||||||
|
comment: "วัน เดือน ปี",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
date: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "รายละเอียด",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
detail: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "เอกสารอ้างอิง",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
reference: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "datetime",
|
||||||
|
comment: "เอกสารอ้างอิง (ลงวันที่)",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
refCommandDate: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "เอกสารอ้างอิง (เลขที่คำสั่ง)",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
refCommandNo: string;
|
||||||
|
|
||||||
|
@OneToMany(() => ProfileNopaidHistory, (profileNopaidHistory) => profileNopaidHistory.histories)
|
||||||
|
profileNopaidHistories: ProfileNopaidHistory[];
|
||||||
|
|
||||||
|
@ManyToOne(() => Profile, (profile) => profile.profileNopaids)
|
||||||
|
@JoinColumn({ name: "profileId" })
|
||||||
|
profile: Profile;
|
||||||
|
}
|
||||||
|
|
||||||
|
export class CreateProfileNopaid {
|
||||||
|
@Column("uuid")
|
||||||
|
profileId: string | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
isActive: boolean;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
date: Date | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
detail: string | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
reference: string | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
refCommandDate: Date | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
refCommandNo: string | null;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
export type UpdateProfileNopaid = Partial<CreateProfileNopaid>;
|
||||||
94
src/entities/ProfileNopaidHistory.ts
Normal file
94
src/entities/ProfileNopaidHistory.ts
Normal file
|
|
@ -0,0 +1,94 @@
|
||||||
|
import { Entity, Column, OneToMany, ManyToOne, JoinColumn } from "typeorm";
|
||||||
|
import { EntityBase } from "./base/Base";
|
||||||
|
import { Profile } from "./Profile";
|
||||||
|
import { ProfileNopaid } from "./ProfileNopaid";
|
||||||
|
|
||||||
|
@Entity("profileNopaidHistory")
|
||||||
|
export class ProfileNopaidHistory extends EntityBase {
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
comment: "สถานะการใช้งาน",
|
||||||
|
default: false,
|
||||||
|
})
|
||||||
|
isActive: boolean;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "datetime",
|
||||||
|
comment: "วัน เดือน ปี",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
date: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "รายละเอียด",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
detail: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "เอกสารอ้างอิง",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
reference: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "datetime",
|
||||||
|
comment: "เอกสารอ้างอิง (ลงวันที่)",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
refCommandDate: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "เอกสารอ้างอิง (เลขที่คำสั่ง)",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
refCommandNo: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "คีย์นอก(FK)ของตาราง ProfileNopaid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
profileNopaidId: string;
|
||||||
|
|
||||||
|
|
||||||
|
@ManyToOne(() => ProfileNopaid, (profileNopaid) => profileNopaid.profileNopaidHistories)
|
||||||
|
@JoinColumn({ name: "profileNopaidId" })
|
||||||
|
histories: ProfileNopaid;
|
||||||
|
}
|
||||||
|
|
||||||
|
export class CreateProfileNopaidHistory {
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
isActive: boolean;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
date: Date | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
detail: string | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
reference: string | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
refCommandDate: Date | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
refCommandNo: string | null;
|
||||||
|
|
||||||
|
@Column("uuid")
|
||||||
|
profileNopaidId: string | null;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
export type UpdateProfileNopaidHistory = Partial<CreateProfileNopaidHistory>;
|
||||||
60
src/entities/ProfileOther.ts
Normal file
60
src/entities/ProfileOther.ts
Normal file
|
|
@ -0,0 +1,60 @@
|
||||||
|
import { Entity, Column, OneToMany, ManyToOne, JoinColumn } from "typeorm";
|
||||||
|
import { EntityBase } from "./base/Base";
|
||||||
|
import { Profile } from "./Profile";
|
||||||
|
import { ProfileOtherHistory } from "./ProfileOtherHistory";
|
||||||
|
|
||||||
|
@Entity("profileOther")
|
||||||
|
export class ProfileOther extends EntityBase {
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "คีย์นอก(FK)ของตาราง Profile",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
profileId: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
comment: "สถานะการใช้งาน",
|
||||||
|
default: false,
|
||||||
|
})
|
||||||
|
isActive: boolean;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "รายละเอียด",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
detail: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "datetime",
|
||||||
|
comment: "วันที่",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
date: Date;
|
||||||
|
|
||||||
|
@OneToMany(() => ProfileOtherHistory, (profileOtherHistory) => profileOtherHistory.histories)
|
||||||
|
profileOtherHistories: ProfileOtherHistory[];
|
||||||
|
|
||||||
|
@ManyToOne(() => Profile, (profile) => profile.profileOthers)
|
||||||
|
@JoinColumn({ name: "profileId" })
|
||||||
|
profile: Profile;
|
||||||
|
}
|
||||||
|
|
||||||
|
export class CreateProfileOther {
|
||||||
|
@Column("uuid")
|
||||||
|
profileId: string | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
isActive: boolean;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
detail: string | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
date: Date | null;
|
||||||
|
}
|
||||||
|
|
||||||
|
export type UpdateProfileOther = Partial<CreateProfileOther>;
|
||||||
56
src/entities/ProfileOtherHistory.ts
Normal file
56
src/entities/ProfileOtherHistory.ts
Normal file
|
|
@ -0,0 +1,56 @@
|
||||||
|
import { Entity, Column, ManyToOne, JoinColumn } from "typeorm";
|
||||||
|
import { EntityBase } from "./base/Base";
|
||||||
|
import { ProfileOther } from "./ProfileOther";
|
||||||
|
|
||||||
|
@Entity("profileOtherHistory")
|
||||||
|
export class ProfileOtherHistory extends EntityBase {
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "คีย์นอก(FK)ของตาราง Profile",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
profileId: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
comment: "สถานะการใช้งาน",
|
||||||
|
default: false,
|
||||||
|
})
|
||||||
|
isActive: boolean;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "รายละเอียด",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
detail: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "datetime",
|
||||||
|
comment: "วันที่",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
date: Date;
|
||||||
|
|
||||||
|
@ManyToOne(() => ProfileOther, (profileOther) => profileOther.profileOtherHistories)
|
||||||
|
@JoinColumn({ name: "profileId" })
|
||||||
|
histories: ProfileOther;
|
||||||
|
}
|
||||||
|
|
||||||
|
export class CreateProfileOtherHistory {
|
||||||
|
@Column("uuid")
|
||||||
|
profileId: string | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
isActive: boolean;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
detail: string | null;
|
||||||
|
|
||||||
|
@Column()
|
||||||
|
date: Date | null;
|
||||||
|
}
|
||||||
|
|
||||||
|
export type UpdateProfileOtherHistory = Partial<CreateProfileOtherHistory>;
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
import { Entity, Column, OneToMany, OneToOne, JoinColumn, ManyToMany, ManyToOne, Double } from "typeorm";
|
import { Entity, Column, OneToMany, OneToOne, JoinColumn, ManyToMany, ManyToOne, Double } from "typeorm";
|
||||||
import { EntityBase } from "./base/Base";
|
import { EntityBase } from "./base/Base";
|
||||||
import { Profile } from "./Profile" ;
|
import { Profile } from "./Profile" ;
|
||||||
|
import { ProfileSalaryHistory } from "./ProfileSalaryHistory";
|
||||||
|
|
||||||
@Entity("profileSalary")
|
@Entity("profileSalary")
|
||||||
export class ProfileSalary extends EntityBase {
|
export class ProfileSalary extends EntityBase {
|
||||||
|
|
@ -42,6 +43,209 @@ export class ProfileSalary extends EntityBase {
|
||||||
})
|
})
|
||||||
profileId: string;
|
profileId: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
comment: "สถานะการใช้งาน",
|
||||||
|
default: false,
|
||||||
|
})
|
||||||
|
isActive: boolean;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "ตำแหน่ง (รายละเอียด)",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
salaryClass: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "เอกสารอ้างอิง",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
salaryRef: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id เลขที่ตำแหน่ง",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
posNoId: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id เลขที่ตำแหน่ง",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionId: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id สังกัด",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
ocId: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id ตำแหน่งทางการบริหาร",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionExecutiveId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id ด้านทางการบริหาร",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionExecutiveSideId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionLevelId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id สายงาน",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionLineId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id ด้าน/สาขา",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionPathSideId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id ประเภทตำแหน่ง",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionTypeId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id ชื่อย่อหน่วยงาน",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
organizationShortNameId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id กลุ่มงาน",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionEmployeeGroupId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id ระดับชั้นงาน",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionEmployeeLevelId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id ตำแหน่ง",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionEmployeePositionId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id ด้านของตำแหน่ง",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionEmployeePositionSideId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id เลขที่ตำแหน่งลูกจ้าง",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
posNoEmployee : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "datetime",
|
||||||
|
comment: "เอกสารอ้างอิง (ลงวันที่)",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
refCommandDate: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "เอกสารอ้างอิง (เลขที่คำสั่ง)",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
refCommandNo: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "ลำดับ",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
order: number;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
comment: "เลขที่คำสั่ง",
|
||||||
|
type: "text",
|
||||||
|
})
|
||||||
|
commandNo: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
comment: "ประเภทคำสั่ง",
|
||||||
|
type: "text",
|
||||||
|
})
|
||||||
|
commandTypeName: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "ประเภทตำแหน่งกรณีพิเศษ",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
salaryStatus: string;
|
||||||
|
|
||||||
|
@OneToMany(() => ProfileSalaryHistory, (profileSalaryHistory) => profileSalaryHistory.histories)
|
||||||
|
profileSalaryHistories: ProfileSalaryHistory[];
|
||||||
|
|
||||||
@ManyToOne(() => Profile, (profile) => profile.profileSalary)
|
@ManyToOne(() => Profile, (profile) => profile.profileSalary)
|
||||||
@JoinColumn({ name: "profileId" })
|
@JoinColumn({ name: "profileId" })
|
||||||
profile: Profile;
|
profile: Profile;
|
||||||
|
|
@ -75,6 +279,78 @@ export class CreateProfileSalary {
|
||||||
})
|
})
|
||||||
profileId: string;
|
profileId: string;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// isActive: boolean;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// salaryClass: string | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// salaryRef: string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// posNoId: string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionId: string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// ocId: string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionExecutiveId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionExecutiveSideId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionLevelId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionLineId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionPathSideId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionTypeId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// organizationShortNameId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionEmployeeGroupId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionEmployeeLevelId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionEmployeePositionId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionEmployeePositionSideId : string | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// posNoEmployee : string | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// refCommandDate: Date | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// refCommandNo: string | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// order: number | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// commandNo: string;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// commandTypeName: string;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// salaryStatus: string | null;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
export class UpdateProfileSalary {
|
export class UpdateProfileSalary {
|
||||||
|
|
@ -99,5 +375,77 @@ export class UpdateProfileSalary {
|
||||||
})
|
})
|
||||||
mouthSalaryAmount: Double;
|
mouthSalaryAmount: Double;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// isActive: boolean;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// salaryClass: string | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// salaryRef: string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// posNoId: string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionId: string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// ocId: string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionExecutiveId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionExecutiveSideId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionLevelId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionLineId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionPathSideId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionTypeId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// organizationShortNameId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionEmployeeGroupId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionEmployeeLevelId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionEmployeePositionId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionEmployeePositionSideId : string | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// posNoEmployee : string | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// refCommandDate: Date | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// refCommandNo: string | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// order: number | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// commandNo: string;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// commandTypeName: string;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// salaryStatus: string | null;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
447
src/entities/ProfileSalaryHistory.ts
Normal file
447
src/entities/ProfileSalaryHistory.ts
Normal file
|
|
@ -0,0 +1,447 @@
|
||||||
|
import { Entity, Column, OneToMany, OneToOne, JoinColumn, ManyToMany, ManyToOne, Double } from "typeorm";
|
||||||
|
import { EntityBase } from "./base/Base";
|
||||||
|
import { Profile } from "./Profile" ;
|
||||||
|
import { ProfileSalary } from "./ProfileSalary";
|
||||||
|
|
||||||
|
@Entity("profileSalaryHistory")
|
||||||
|
export class ProfileSalaryHistory extends EntityBase {
|
||||||
|
@Column({
|
||||||
|
comment: "วันที่",
|
||||||
|
type: "datetime",
|
||||||
|
nullable: true,
|
||||||
|
})
|
||||||
|
date: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
comment: "เงินเดือนฐาน",
|
||||||
|
default: 0,
|
||||||
|
nullable: true,
|
||||||
|
type: "double"
|
||||||
|
})
|
||||||
|
amount: Double;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
comment: "เงินประจำตำแหน่ง",
|
||||||
|
default: 0,
|
||||||
|
nullable: true,
|
||||||
|
type: "double"
|
||||||
|
})
|
||||||
|
positionSalaryAmount: Double;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
comment: "เงินค่าตอบแทนรายเดือน",
|
||||||
|
default: 0,
|
||||||
|
nullable: true,
|
||||||
|
type: "double"
|
||||||
|
})
|
||||||
|
mouthSalaryAmount: Double;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
length: 40,
|
||||||
|
comment: "คีย์นอก(FK)ของตาราง profile",
|
||||||
|
type: "uuid"
|
||||||
|
})
|
||||||
|
profileId: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
comment: "สถานะการใช้งาน",
|
||||||
|
default: false,
|
||||||
|
})
|
||||||
|
isActive: boolean;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "ตำแหน่ง (รายละเอียด)",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
salaryClass: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "เอกสารอ้างอิง",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
salaryRef: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id เลขที่ตำแหน่ง",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
posNoId: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id เลขที่ตำแหน่ง",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionId: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id สังกัด",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
ocId: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id ตำแหน่งทางการบริหาร",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionExecutiveId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id ด้านทางการบริหาร",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionExecutiveSideId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionLevelId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id สายงาน",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionLineId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id ด้าน/สาขา",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionPathSideId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id ประเภทตำแหน่ง",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionTypeId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id ชื่อย่อหน่วยงาน",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
organizationShortNameId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id กลุ่มงาน",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionEmployeeGroupId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id ระดับชั้นงาน",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionEmployeeLevelId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id ตำแหน่ง",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionEmployeePositionId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id ด้านของตำแหน่ง",
|
||||||
|
type: "uuid",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
positionEmployeePositionSideId : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
length: 40,
|
||||||
|
comment: "Id เลขที่ตำแหน่งลูกจ้าง",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
posNoEmployee : string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "datetime",
|
||||||
|
comment: "เอกสารอ้างอิง (ลงวันที่)",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
refCommandDate: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "เอกสารอ้างอิง (เลขที่คำสั่ง)",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
refCommandNo: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "ลำดับ",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
order: number;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
comment: "เลขที่คำสั่ง",
|
||||||
|
type: "text",
|
||||||
|
})
|
||||||
|
commandNo: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
comment: "ประเภทคำสั่ง",
|
||||||
|
type: "text",
|
||||||
|
})
|
||||||
|
commandTypeName: string;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "ประเภทตำแหน่งกรณีพิเศษ",
|
||||||
|
type: "text",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
salaryStatus: string;
|
||||||
|
|
||||||
|
@ManyToOne(() => ProfileSalary, (profileSalary) => profileSalary.profileSalaryHistories)
|
||||||
|
@JoinColumn({ name: "profileSalaryId" })
|
||||||
|
histories: ProfileSalary;
|
||||||
|
}
|
||||||
|
|
||||||
|
export class CreateProfileSalaryHistory {
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
type: "datetime"
|
||||||
|
})
|
||||||
|
date: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
type: "double"
|
||||||
|
})
|
||||||
|
amount: Double;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
type: "double"
|
||||||
|
})
|
||||||
|
positionSalaryAmount: Double;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
type: "double"
|
||||||
|
})
|
||||||
|
mouthSalaryAmount: Double;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
type: "uuid"
|
||||||
|
})
|
||||||
|
profileId: string;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// isActive: boolean;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// salaryClass: string | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// salaryRef: string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// posNoId: string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionId: string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// ocId: string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionExecutiveId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionExecutiveSideId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionLevelId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionLineId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionPathSideId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionTypeId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// organizationShortNameId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionEmployeeGroupId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionEmployeeLevelId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionEmployeePositionId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionEmployeePositionSideId : string | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// posNoEmployee : string | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// refCommandDate: Date | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// refCommandNo: string | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// order: number | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// commandNo: string;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// commandTypeName: string;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// salaryStatus: string | null;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
export class UpdateProfileSalaryHistory {
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
type: "datetime"
|
||||||
|
})
|
||||||
|
date: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
type: "double"
|
||||||
|
})
|
||||||
|
amount: Double;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
type: "double"
|
||||||
|
})
|
||||||
|
positionSalaryAmount: Double;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
type: "double"
|
||||||
|
})
|
||||||
|
mouthSalaryAmount: Double;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// isActive: boolean;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// salaryClass: string | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// salaryRef: string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// posNoId: string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionId: string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// ocId: string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionExecutiveId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionExecutiveSideId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionLevelId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionLineId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionPathSideId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionTypeId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// organizationShortNameId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionEmployeeGroupId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionEmployeeLevelId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionEmployeePositionId : string | null;
|
||||||
|
|
||||||
|
// @Column("uuid")
|
||||||
|
// positionEmployeePositionSideId : string | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// posNoEmployee : string | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// refCommandDate: Date | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// refCommandNo: string | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// order: number | null;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// commandNo: string;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// commandTypeName: string;
|
||||||
|
|
||||||
|
// @Column()
|
||||||
|
// salaryStatus: string | null;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue