Merge branch 'main' into develop
This commit is contained in:
commit
a61825eb57
2 changed files with 66 additions and 22 deletions
|
|
@ -4759,11 +4759,11 @@ export class CommandController extends Controller {
|
|||
mouthSalaryAmount?: Double | null;
|
||||
commandNo: string | null;
|
||||
commandYear: number | null;
|
||||
posNo: string | null;
|
||||
posNoAbb: string | null;
|
||||
// posNo: string | null;
|
||||
// posNoAbb: string | null;
|
||||
commandDateAffect?: Date | null;
|
||||
commandDateSign?: Date | null;
|
||||
positionName: string | null;
|
||||
positionName?: string | null;
|
||||
commandCode?: string | null;
|
||||
commandName?: string | null;
|
||||
remark: string | null;
|
||||
|
|
@ -5458,17 +5458,49 @@ export class CommandController extends Controller {
|
|||
profile.lastUpdatedAt = new Date();
|
||||
|
||||
//เพิ่มใหม่จากรับโอน
|
||||
profile.prefix = item.bodyProfile.prefix && item.bodyProfile.prefix != "" ? item.bodyProfile.prefix : profile.prefix;
|
||||
profile.firstName = item.bodyProfile.firstName && item.bodyProfile.firstName != "" ? item.bodyProfile.firstName : profile.firstName;
|
||||
profile.lastName = item.bodyProfile.lastName && item.bodyProfile.lastName != "" ? item.bodyProfile.lastName : profile.lastName;
|
||||
profile.birthDate = item.bodyProfile.birthDate ? item.bodyProfile.birthDate : profile.birthDate;
|
||||
profile.gender = item.bodyProfile.gender && item.bodyProfile.gender != "" ? item.bodyProfile.gender : profile.gender;
|
||||
profile.relationship = item.bodyProfile.relationship && item.bodyProfile.relationship != "" ? item.bodyProfile.relationship : profile.relationship;
|
||||
profile.religion = item.bodyProfile.religion && item.bodyProfile.religion != "" ? item.bodyProfile.religion : profile.religion;
|
||||
profile.ethnicity = item.bodyProfile.ethnicity && item.bodyProfile.ethnicity != "" ? item.bodyProfile.ethnicity : profile.ethnicity;
|
||||
profile.nationality = item.bodyProfile.nationality && item.bodyProfile.nationality != "" ? item.bodyProfile.nationality : profile.nationality;
|
||||
profile.bloodGroup = item.bodyProfile.bloodGroup && item.bodyProfile.bloodGroup != "" ? item.bodyProfile.bloodGroup : profile.bloodGroup;
|
||||
profile.phone = item.bodyProfile.phone && item.bodyProfile.phone != "" ? item.bodyProfile.phone : profile.phone;
|
||||
profile.prefix =
|
||||
item.bodyProfile.prefix && item.bodyProfile.prefix != ""
|
||||
? item.bodyProfile.prefix
|
||||
: profile.prefix;
|
||||
profile.firstName =
|
||||
item.bodyProfile.firstName && item.bodyProfile.firstName != ""
|
||||
? item.bodyProfile.firstName
|
||||
: profile.firstName;
|
||||
profile.lastName =
|
||||
item.bodyProfile.lastName && item.bodyProfile.lastName != ""
|
||||
? item.bodyProfile.lastName
|
||||
: profile.lastName;
|
||||
profile.birthDate = item.bodyProfile.birthDate
|
||||
? item.bodyProfile.birthDate
|
||||
: profile.birthDate;
|
||||
profile.gender =
|
||||
item.bodyProfile.gender && item.bodyProfile.gender != ""
|
||||
? item.bodyProfile.gender
|
||||
: profile.gender;
|
||||
profile.relationship =
|
||||
item.bodyProfile.relationship && item.bodyProfile.relationship != ""
|
||||
? item.bodyProfile.relationship
|
||||
: profile.relationship;
|
||||
profile.religion =
|
||||
item.bodyProfile.religion && item.bodyProfile.religion != ""
|
||||
? item.bodyProfile.religion
|
||||
: profile.religion;
|
||||
profile.ethnicity =
|
||||
item.bodyProfile.ethnicity && item.bodyProfile.ethnicity != ""
|
||||
? item.bodyProfile.ethnicity
|
||||
: profile.ethnicity;
|
||||
profile.nationality =
|
||||
item.bodyProfile.nationality && item.bodyProfile.nationality != ""
|
||||
? item.bodyProfile.nationality
|
||||
: profile.nationality;
|
||||
profile.bloodGroup =
|
||||
item.bodyProfile.bloodGroup && item.bodyProfile.bloodGroup != ""
|
||||
? item.bodyProfile.bloodGroup
|
||||
: profile.bloodGroup;
|
||||
profile.phone =
|
||||
item.bodyProfile.phone && item.bodyProfile.phone != ""
|
||||
? item.bodyProfile.phone
|
||||
: profile.phone;
|
||||
await this.profileRepository.save(profile);
|
||||
setLogDataDiff(req, { before, after: profile });
|
||||
}
|
||||
|
|
@ -5868,11 +5900,11 @@ export class CommandController extends Controller {
|
|||
positionType: profile.posTypeNameTemp,
|
||||
positionLevel: profile.posLevelNameTemp,
|
||||
order: dest_item == null ? 1 : dest_item.order + 1,
|
||||
orgRoot: orgRootRef?.orgRootName??null,
|
||||
orgChild1: orgChild1Ref?.orgChild1Name??null,
|
||||
orgChild2: orgChild2Ref?.orgChild2Name??null,
|
||||
orgChild3: orgChild3Ref?.orgChild3Name??null,
|
||||
orgChild4: orgChild4Ref?.orgChild4Name??null,
|
||||
orgRoot: orgRootRef?.orgRootName ?? null,
|
||||
orgChild1: orgChild1Ref?.orgChild1Name ?? null,
|
||||
orgChild2: orgChild2Ref?.orgChild2Name ?? null,
|
||||
orgChild3: orgChild3Ref?.orgChild3Name ?? null,
|
||||
orgChild4: orgChild4Ref?.orgChild4Name ?? null,
|
||||
createdUserId: req.user.sub,
|
||||
createdFullName: req.user.name,
|
||||
lastUpdateUserId: req.user.sub,
|
||||
|
|
@ -6070,8 +6102,10 @@ export class CommandController extends Controller {
|
|||
current_holderId: profile.id,
|
||||
},
|
||||
});
|
||||
if(posMasterTemp){
|
||||
await this.employeeTempPosMasterRepository.update(posMasterTemp.id,{current_holderId: _null});
|
||||
if (posMasterTemp) {
|
||||
await this.employeeTempPosMasterRepository.update(posMasterTemp.id, {
|
||||
current_holderId: _null,
|
||||
});
|
||||
}
|
||||
}
|
||||
}),
|
||||
|
|
|
|||
|
|
@ -5647,7 +5647,17 @@ export class OrganizationController extends Controller {
|
|||
}
|
||||
|
||||
const data = await this.orgRootRepository.find({
|
||||
where: { orgRevisionId: orgRevisionActive.id },
|
||||
where: {
|
||||
orgRevisionId: orgRevisionActive.id,
|
||||
id: In([
|
||||
"d7e98989-b5ce-47d6-93c3-ab63ed486348",
|
||||
"6f9b30e1-757a-40d5-b053-61eb1b91c0f0",
|
||||
"eaf65f33-25e9-4956-9dba-5d909f5eb595",
|
||||
"87c5bc89-300c-4b6a-99e4-26371436caa2",
|
||||
"982d33af-4eb5-4cc8-9c9f-b3ccadbb66d7",
|
||||
"e0545eca-5d0a-4a1c-8bbd-e3e25c2521db",
|
||||
]),
|
||||
},
|
||||
order: {
|
||||
orgRootOrder: "ASC",
|
||||
},
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue