แก้ format ฟิว posMasterNo (5) สำหรับบันทึกลงระบบที่พัฒนาบน .net
1.ปรับระดับชั้นงาน-ย้ายลูกจ้าง (เลข Prefix / Suffix ไม่แสดง) 2.รายการอื่นๆ (เลข Prefix / Suffix ไม่แสดง) 3.รายการลาออก (เลข Prefix / Suffix ไม่แสดง) 4.รายการลาออกลูกจ้างฯ (เลข Prefix / Suffix ไม่แสดง) 5.เรื่องร้องเรียน (เลข Prefix / Suffix ไม่แสดง) 6.สืบสวนฯ (เลข Prefix / Suffix ไม่แสดง) 7.สอบสวนฯ (เลข Prefix / Suffix ไม่แสดง) 8.สรุปผลการพิจารณาฯ (เลข Prefix / Suffix ไม่แสดง)
This commit is contained in:
parent
755ae992dd
commit
219a2908a3
2 changed files with 49 additions and 80 deletions
|
|
@ -7935,40 +7935,38 @@ export class ProfileController extends Controller {
|
||||||
privacyUser: profile.privacyUser,
|
privacyUser: profile.privacyUser,
|
||||||
privacyMgt: profile.privacyMgt,
|
privacyMgt: profile.privacyMgt,
|
||||||
isDeputy: root?.isDeputy ?? false,
|
isDeputy: root?.isDeputy ?? false,
|
||||||
// root?.orgRootShortName && posMaster?.posMasterNo
|
|
||||||
// ? `${root?.orgRootShortName} ${posMaster?.posMasterNo}`
|
|
||||||
// : "",
|
|
||||||
};
|
};
|
||||||
|
const _numPart = posMaster ? [posMaster.posMasterNoPrefix, posMaster.posMasterNo, posMaster.posMasterNoSuffix].filter((p) => p !== null && p !== undefined && p !== '').join(' ') : '';
|
||||||
if (_profile.child4Id != null) {
|
if (_profile.child4Id != null) {
|
||||||
_profile.node = 4;
|
_profile.node = 4;
|
||||||
_profile.nodeId = _profile.child4Id;
|
_profile.nodeId = _profile.child4Id;
|
||||||
_profile.nodeDnaId = _profile.child4DnaId;
|
_profile.nodeDnaId = _profile.child4DnaId;
|
||||||
_profile.nodeShortName = _profile.child4ShortName;
|
_profile.nodeShortName = _profile.child4ShortName;
|
||||||
_profile.posNo = `${_profile.child4ShortName} ${_profile.posMasterNo}`;
|
_profile.posNo = `${_profile.child4ShortName} ${_numPart}`;
|
||||||
} else if (_profile.child3Id != null) {
|
} else if (_profile.child3Id != null) {
|
||||||
_profile.node = 3;
|
_profile.node = 3;
|
||||||
_profile.nodeId = _profile.child3Id;
|
_profile.nodeId = _profile.child3Id;
|
||||||
_profile.nodeDnaId = _profile.child3DnaId;
|
_profile.nodeDnaId = _profile.child3DnaId;
|
||||||
_profile.nodeShortName = _profile.child3ShortName;
|
_profile.nodeShortName = _profile.child3ShortName;
|
||||||
_profile.posNo = `${_profile.child3ShortName} ${_profile.posMasterNo}`;
|
_profile.posNo = `${_profile.child3ShortName} ${_numPart}`;
|
||||||
} else if (_profile.child2Id != null) {
|
} else if (_profile.child2Id != null) {
|
||||||
_profile.node = 2;
|
_profile.node = 2;
|
||||||
_profile.nodeId = _profile.child2Id;
|
_profile.nodeId = _profile.child2Id;
|
||||||
_profile.nodeDnaId = _profile.child2DnaId;
|
_profile.nodeDnaId = _profile.child2DnaId;
|
||||||
_profile.nodeShortName = _profile.child2ShortName;
|
_profile.nodeShortName = _profile.child2ShortName;
|
||||||
_profile.posNo = `${_profile.child2ShortName} ${_profile.posMasterNo}`;
|
_profile.posNo = `${_profile.child2ShortName} ${_numPart}`;
|
||||||
} else if (_profile.child1Id != null) {
|
} else if (_profile.child1Id != null) {
|
||||||
_profile.node = 1;
|
_profile.node = 1;
|
||||||
_profile.nodeId = _profile.child1Id;
|
_profile.nodeId = _profile.child1Id;
|
||||||
_profile.nodeDnaId = _profile.child1DnaId;
|
_profile.nodeDnaId = _profile.child1DnaId;
|
||||||
_profile.nodeShortName = _profile.child1ShortName;
|
_profile.nodeShortName = _profile.child1ShortName;
|
||||||
_profile.posNo = `${_profile.child1ShortName} ${_profile.posMasterNo}`;
|
_profile.posNo = `${_profile.child1ShortName} ${_numPart}`;
|
||||||
} else if (_profile.rootId != null) {
|
} else if (_profile.rootId != null) {
|
||||||
_profile.node = 0;
|
_profile.node = 0;
|
||||||
_profile.nodeId = _profile.rootId;
|
_profile.nodeId = _profile.rootId;
|
||||||
_profile.nodeDnaId = _profile.rootDnaId;
|
_profile.nodeDnaId = _profile.rootDnaId;
|
||||||
_profile.nodeShortName = _profile.rootShortName;
|
_profile.nodeShortName = _profile.rootShortName;
|
||||||
_profile.posNo = `${_profile.rootShortName} ${_profile.posMasterNo}`;
|
_profile.posNo = `${_profile.rootShortName} ${_numPart}`;
|
||||||
}
|
}
|
||||||
return new HttpSuccess(_profile);
|
return new HttpSuccess(_profile);
|
||||||
}
|
}
|
||||||
|
|
@ -8108,41 +8106,39 @@ export class ProfileController extends Controller {
|
||||||
privacyUser: profile.privacyUser,
|
privacyUser: profile.privacyUser,
|
||||||
privacyMgt: profile.privacyMgt,
|
privacyMgt: profile.privacyMgt,
|
||||||
isDeputy: root?.isDeputy ?? false,
|
isDeputy: root?.isDeputy ?? false,
|
||||||
// root?.orgRootShortName && posMaster?.posMasterNo
|
|
||||||
// ? `${root?.orgRootShortName} ${posMaster?.posMasterNo}`
|
|
||||||
// : "",
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const _numPart = posMaster ? [posMaster.posMasterNoPrefix, posMaster.posMasterNo, posMaster.posMasterNoSuffix].filter((p) => p !== null && p !== undefined && p !== '').join(' ') : '';
|
||||||
if (_profile.child4Id != null) {
|
if (_profile.child4Id != null) {
|
||||||
_profile.node = 4;
|
_profile.node = 4;
|
||||||
_profile.nodeId = _profile.child4Id;
|
_profile.nodeId = _profile.child4Id;
|
||||||
_profile.nodeDnaId = _profile.child4DnaId;
|
_profile.nodeDnaId = _profile.child4DnaId;
|
||||||
_profile.nodeShortName = _profile.child4ShortName;
|
_profile.nodeShortName = _profile.child4ShortName;
|
||||||
_profile.posNo = `${_profile.child4ShortName} ${posMaster?.posMasterNo}`;
|
_profile.posNo = `${_profile.child4ShortName} ${_numPart}`;
|
||||||
} else if (_profile.child3Id != null) {
|
} else if (_profile.child3Id != null) {
|
||||||
_profile.node = 3;
|
_profile.node = 3;
|
||||||
_profile.nodeId = _profile.child3Id;
|
_profile.nodeId = _profile.child3Id;
|
||||||
_profile.nodeDnaId = _profile.child3DnaId;
|
_profile.nodeDnaId = _profile.child3DnaId;
|
||||||
_profile.nodeShortName = _profile.child3ShortName;
|
_profile.nodeShortName = _profile.child3ShortName;
|
||||||
_profile.posNo = `${_profile.child3ShortName} ${posMaster?.posMasterNo}`;
|
_profile.posNo = `${_profile.child3ShortName} ${_numPart}`;
|
||||||
} else if (_profile.child2Id != null) {
|
} else if (_profile.child2Id != null) {
|
||||||
_profile.node = 2;
|
_profile.node = 2;
|
||||||
_profile.nodeId = _profile.child2Id;
|
_profile.nodeId = _profile.child2Id;
|
||||||
_profile.nodeDnaId = _profile.child2DnaId;
|
_profile.nodeDnaId = _profile.child2DnaId;
|
||||||
_profile.nodeShortName = _profile.child2ShortName;
|
_profile.nodeShortName = _profile.child2ShortName;
|
||||||
_profile.posNo = `${_profile.child2ShortName} ${posMaster?.posMasterNo}`;
|
_profile.posNo = `${_profile.child2ShortName} ${_numPart}`;
|
||||||
} else if (_profile.child1Id != null) {
|
} else if (_profile.child1Id != null) {
|
||||||
_profile.node = 1;
|
_profile.node = 1;
|
||||||
_profile.nodeId = _profile.child1Id;
|
_profile.nodeId = _profile.child1Id;
|
||||||
_profile.nodeDnaId = _profile.child1DnaId;
|
_profile.nodeDnaId = _profile.child1DnaId;
|
||||||
_profile.nodeShortName = _profile.child1ShortName;
|
_profile.nodeShortName = _profile.child1ShortName;
|
||||||
_profile.posNo = `${_profile.child1ShortName} ${posMaster?.posMasterNo}`;
|
_profile.posNo = `${_profile.child1ShortName} ${_numPart}`;
|
||||||
} else if (_profile.rootId != null) {
|
} else if (_profile.rootId != null) {
|
||||||
_profile.node = 0;
|
_profile.node = 0;
|
||||||
_profile.nodeId = _profile.rootId;
|
_profile.nodeId = _profile.rootId;
|
||||||
_profile.nodeDnaId = _profile.rootDnaId;
|
_profile.nodeDnaId = _profile.rootDnaId;
|
||||||
_profile.nodeShortName = _profile.rootShortName;
|
_profile.nodeShortName = _profile.rootShortName;
|
||||||
_profile.posNo = `${_profile.rootShortName} ${posMaster?.posMasterNo}`;
|
_profile.posNo = `${_profile.rootShortName} ${_numPart}`;
|
||||||
}
|
}
|
||||||
return new HttpSuccess(_profile);
|
return new HttpSuccess(_profile);
|
||||||
}
|
}
|
||||||
|
|
@ -9313,26 +9309,32 @@ export class ProfileController extends Controller {
|
||||||
: "-",
|
: "-",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const _numPart = posMaster ? [posMaster.posMasterNoPrefix, posMaster.posMasterNo, posMaster.posMasterNoSuffix].filter((p) => p !== null && p !== undefined && p !== '').join(' ') : '';
|
||||||
if (_profile.child4Id != null) {
|
if (_profile.child4Id != null) {
|
||||||
_profile.node = 4;
|
_profile.node = 4;
|
||||||
_profile.nodeId = _profile.child4Id;
|
_profile.nodeId = _profile.child4Id;
|
||||||
_profile.nodeShortName = _profile.child4ShortName;
|
_profile.nodeShortName = _profile.child4ShortName;
|
||||||
|
_profile.posNo = `${_profile.child4ShortName} ${_numPart}`;
|
||||||
} else if (_profile.child3Id != null) {
|
} else if (_profile.child3Id != null) {
|
||||||
_profile.node = 3;
|
_profile.node = 3;
|
||||||
_profile.nodeId = _profile.child3Id;
|
_profile.nodeId = _profile.child3Id;
|
||||||
_profile.nodeShortName = _profile.child3ShortName;
|
_profile.nodeShortName = _profile.child3ShortName;
|
||||||
|
_profile.posNo = `${_profile.child3ShortName} ${_numPart}`;
|
||||||
} else if (_profile.child2Id != null) {
|
} else if (_profile.child2Id != null) {
|
||||||
_profile.node = 2;
|
_profile.node = 2;
|
||||||
_profile.nodeId = _profile.child2Id;
|
_profile.nodeId = _profile.child2Id;
|
||||||
_profile.nodeShortName = _profile.child2ShortName;
|
_profile.nodeShortName = _profile.child2ShortName;
|
||||||
|
_profile.posNo = `${_profile.child2ShortName} ${_numPart}`;
|
||||||
} else if (_profile.child1Id != null) {
|
} else if (_profile.child1Id != null) {
|
||||||
_profile.node = 1;
|
_profile.node = 1;
|
||||||
_profile.nodeId = _profile.child1Id;
|
_profile.nodeId = _profile.child1Id;
|
||||||
_profile.nodeShortName = _profile.child1ShortName;
|
_profile.nodeShortName = _profile.child1ShortName;
|
||||||
|
_profile.posNo = `${_profile.child1ShortName} ${_numPart}`;
|
||||||
} else if (_profile.rootId != null) {
|
} else if (_profile.rootId != null) {
|
||||||
_profile.node = 0;
|
_profile.node = 0;
|
||||||
_profile.nodeId = _profile.rootId;
|
_profile.nodeId = _profile.rootId;
|
||||||
_profile.nodeShortName = _profile.rootShortName;
|
_profile.nodeShortName = _profile.rootShortName;
|
||||||
|
_profile.posNo = `${_profile.rootShortName} ${_numPart}`;
|
||||||
}
|
}
|
||||||
return new HttpSuccess(_profile);
|
return new HttpSuccess(_profile);
|
||||||
}
|
}
|
||||||
|
|
@ -9513,38 +9515,28 @@ export class ProfileController extends Controller {
|
||||||
const mapDataProfile = await Promise.all(
|
const mapDataProfile = await Promise.all(
|
||||||
findProfile.map(async (item: Profile) => {
|
findProfile.map(async (item: Profile) => {
|
||||||
const fullName = `${item.prefix}${item.firstName} ${item.lastName}`;
|
const fullName = `${item.prefix}${item.firstName} ${item.lastName}`;
|
||||||
const shortName =
|
const holder = item.current_holders?.find((x) => x.orgRevisionId == findRevision.id);
|
||||||
item.current_holders.length == 0
|
const _numPart = holder ? [holder.posMasterNoPrefix, holder.posMasterNo, holder.posMasterNoSuffix].filter((p) => p !== null && p !== undefined && p !== '').join(' ') : '';
|
||||||
|
const shortName = !holder
|
||||||
? null
|
? null
|
||||||
: item.current_holders.find((x) => x.orgRevisionId == findRevision.id) != null &&
|
: holder.orgChild4 != null
|
||||||
item.current_holders.find((x) => x.orgRevisionId == findRevision.id)?.orgChild4 !=
|
? `${holder.orgChild4.orgChild4ShortName} ${_numPart}`
|
||||||
null
|
: holder.orgChild3 != null
|
||||||
? `${item.current_holders.find((x) => x.orgRevisionId == findRevision.id)?.orgChild4.orgChild4ShortName} ${item.current_holders.find((x) => x.orgRevisionId == findRevision.id)?.posMasterNo}`
|
? `${holder.orgChild3.orgChild3ShortName} ${_numPart}`
|
||||||
: item.current_holders.find((x) => x.orgRevisionId == findRevision.id) != null &&
|
: holder.orgChild2 != null
|
||||||
item.current_holders.find((x) => x.orgRevisionId == findRevision.id)?.orgChild3 !=
|
? `${holder.orgChild2.orgChild2ShortName} ${_numPart}`
|
||||||
null
|
: holder.orgChild1 != null
|
||||||
? `${item.current_holders.find((x) => x.orgRevisionId == findRevision.id)?.orgChild3.orgChild3ShortName} ${item.current_holders.find((x) => x.orgRevisionId == findRevision.id)?.posMasterNo}`
|
? `${holder.orgChild1.orgChild1ShortName} ${_numPart}`
|
||||||
: item.current_holders.find((x) => x.orgRevisionId == findRevision.id) != null &&
|
: holder.orgRoot != null
|
||||||
item.current_holders.find((x) => x.orgRevisionId == findRevision.id)
|
? `${holder.orgRoot.orgRootShortName} ${_numPart}`
|
||||||
?.orgChild2 != null
|
|
||||||
? `${item.current_holders.find((x) => x.orgRevisionId == findRevision.id)?.orgChild2.orgChild2ShortName} ${item.current_holders.find((x) => x.orgRevisionId == findRevision.id)?.posMasterNo}`
|
|
||||||
: item.current_holders.find((x) => x.orgRevisionId == findRevision.id) != null &&
|
|
||||||
item.current_holders.find((x) => x.orgRevisionId == findRevision.id)
|
|
||||||
?.orgChild1 != null
|
|
||||||
? `${item.current_holders.find((x) => x.orgRevisionId == findRevision.id)?.orgChild1.orgChild1ShortName} ${item.current_holders.find((x) => x.orgRevisionId == findRevision.id)?.posMasterNo}`
|
|
||||||
: item.current_holders.find((x) => x.orgRevisionId == findRevision.id) !=
|
|
||||||
null &&
|
|
||||||
item.current_holders.find((x) => x.orgRevisionId == findRevision.id)
|
|
||||||
?.orgRoot != null
|
|
||||||
? `${item.current_holders.find((x) => x.orgRevisionId == findRevision.id)?.orgRoot.orgRootShortName} ${item.current_holders.find((x) => x.orgRevisionId == findRevision.id)?.posMasterNo}`
|
|
||||||
: null;
|
: null;
|
||||||
|
|
||||||
const root =
|
const root =
|
||||||
item.current_holders.length == 0 ||
|
item.current_holders.length == 0 ||
|
||||||
(item.current_holders.find((x) => x.orgRevisionId == findRevision.id) != null &&
|
(holder != null &&
|
||||||
item.current_holders.find((x) => x.orgRevisionId == findRevision.id)?.orgRoot == null)
|
holder?.orgRoot == null)
|
||||||
? null
|
? null
|
||||||
: item.current_holders.find((x) => x.orgRevisionId == findRevision.id)?.orgRoot;
|
: holder?.orgRoot;
|
||||||
|
|
||||||
const rootHolder = item.current_holders?.find(
|
const rootHolder = item.current_holders?.find(
|
||||||
(x) => x.orgRevisionId == findRevision.id,
|
(x) => x.orgRevisionId == findRevision.id,
|
||||||
|
|
|
||||||
|
|
@ -4003,40 +4003,38 @@ export class ProfileEmployeeController extends Controller {
|
||||||
salary: profile ? profile.amount : null,
|
salary: profile ? profile.amount : null,
|
||||||
amountSpecial: profile ? profile.amountSpecial : null,
|
amountSpecial: profile ? profile.amountSpecial : null,
|
||||||
posNo: null,
|
posNo: null,
|
||||||
// root?.orgRootShortName && posMaster?.posMasterNo
|
|
||||||
// ? `${root?.orgRootShortName} ${posMaster?.posMasterNo}`
|
|
||||||
// : "",
|
|
||||||
};
|
};
|
||||||
|
const _numPart = posMaster ? [posMaster.posMasterNoPrefix, posMaster.posMasterNo, posMaster.posMasterNoSuffix].filter((p) => p !== null && p !== undefined && p !== '').join(' ') : '';
|
||||||
if (_profile.child4Id != null) {
|
if (_profile.child4Id != null) {
|
||||||
_profile.node = 4;
|
_profile.node = 4;
|
||||||
_profile.nodeId = _profile.child4Id;
|
_profile.nodeId = _profile.child4Id;
|
||||||
_profile.nodeDnaId = _profile.child4DnaId;
|
_profile.nodeDnaId = _profile.child4DnaId;
|
||||||
_profile.nodeShortName = _profile.child4ShortName;
|
_profile.nodeShortName = _profile.child4ShortName;
|
||||||
_profile.posNo = `${_profile.child4ShortName} ${_profile.posMasterNo}`;
|
_profile.posNo = `${_profile.child4ShortName} ${_numPart}`;
|
||||||
} else if (_profile.child3Id != null) {
|
} else if (_profile.child3Id != null) {
|
||||||
_profile.node = 3;
|
_profile.node = 3;
|
||||||
_profile.nodeId = _profile.child3Id;
|
_profile.nodeId = _profile.child3Id;
|
||||||
_profile.nodeDnaId = _profile.child3DnaId;
|
_profile.nodeDnaId = _profile.child3DnaId;
|
||||||
_profile.nodeShortName = _profile.child3ShortName;
|
_profile.nodeShortName = _profile.child3ShortName;
|
||||||
_profile.posNo = `${_profile.child3ShortName} ${_profile.posMasterNo}`;
|
_profile.posNo = `${_profile.child3ShortName} ${_numPart}`;
|
||||||
} else if (_profile.child2Id != null) {
|
} else if (_profile.child2Id != null) {
|
||||||
_profile.node = 2;
|
_profile.node = 2;
|
||||||
_profile.nodeId = _profile.child2Id;
|
_profile.nodeId = _profile.child2Id;
|
||||||
_profile.nodeDnaId = _profile.child2DnaId;
|
_profile.nodeDnaId = _profile.child2DnaId;
|
||||||
_profile.nodeShortName = _profile.child2ShortName;
|
_profile.nodeShortName = _profile.child2ShortName;
|
||||||
_profile.posNo = `${_profile.child2ShortName} ${_profile.posMasterNo}`;
|
_profile.posNo = `${_profile.child2ShortName} ${_numPart}`;
|
||||||
} else if (_profile.child1Id != null) {
|
} else if (_profile.child1Id != null) {
|
||||||
_profile.node = 1;
|
_profile.node = 1;
|
||||||
_profile.nodeId = _profile.child1Id;
|
_profile.nodeId = _profile.child1Id;
|
||||||
_profile.nodeDnaId = _profile.child1DnaId;
|
_profile.nodeDnaId = _profile.child1DnaId;
|
||||||
_profile.nodeShortName = _profile.child1ShortName;
|
_profile.nodeShortName = _profile.child1ShortName;
|
||||||
_profile.posNo = `${_profile.child1ShortName} ${_profile.posMasterNo}`;
|
_profile.posNo = `${_profile.child1ShortName} ${_numPart}`;
|
||||||
} else if (_profile.rootId != null) {
|
} else if (_profile.rootId != null) {
|
||||||
_profile.node = 0;
|
_profile.node = 0;
|
||||||
_profile.nodeId = _profile.rootId;
|
_profile.nodeId = _profile.rootId;
|
||||||
_profile.nodeDnaId = _profile.rootDnaId;
|
_profile.nodeDnaId = _profile.rootDnaId;
|
||||||
_profile.nodeShortName = _profile.rootShortName;
|
_profile.nodeShortName = _profile.rootShortName;
|
||||||
_profile.posNo = `${_profile.rootShortName} ${_profile.posMasterNo}`;
|
_profile.posNo = `${_profile.rootShortName} ${_numPart}`;
|
||||||
}
|
}
|
||||||
return new HttpSuccess(_profile);
|
return new HttpSuccess(_profile);
|
||||||
}
|
}
|
||||||
|
|
@ -6444,33 +6442,7 @@ export class ProfileEmployeeController extends Controller {
|
||||||
null
|
null
|
||||||
? null
|
? null
|
||||||
: profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id)?.orgChild4;
|
: profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id)?.orgChild4;
|
||||||
const shortName =
|
const _numPart = posMaster ? [posMaster.posMasterNoPrefix, posMaster.posMasterNo, posMaster.posMasterNoSuffix].filter((p) => p !== null && p !== undefined && p !== '').join(' ') : '';
|
||||||
profile.current_holders.length == 0
|
|
||||||
? null
|
|
||||||
: profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id) != null &&
|
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id)
|
|
||||||
?.orgChild4 != null
|
|
||||||
? `${profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id)?.orgChild4.orgChild4ShortName} ${profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id)?.posMasterNo}`
|
|
||||||
: profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id) != null &&
|
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id)
|
|
||||||
?.orgChild3 != null
|
|
||||||
? `${profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id)?.orgChild3.orgChild3ShortName} ${profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id)?.posMasterNo}`
|
|
||||||
: profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id) !=
|
|
||||||
null &&
|
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id)
|
|
||||||
?.orgChild2 != null
|
|
||||||
? `${profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id)?.orgChild2.orgChild2ShortName} ${profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id)?.posMasterNo}`
|
|
||||||
: profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id) !=
|
|
||||||
null &&
|
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id)
|
|
||||||
?.orgChild1 != null
|
|
||||||
? `${profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id)?.orgChild1.orgChild1ShortName} ${profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id)?.posMasterNo}`
|
|
||||||
: profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id) !=
|
|
||||||
null &&
|
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id)
|
|
||||||
?.orgRoot != null
|
|
||||||
? `${profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id)?.orgRoot.orgRootShortName} ${profile.current_holders.find((x) => x.orgRevisionId == orgRevisionPublish.id)?.posMasterNo}`
|
|
||||||
: null;
|
|
||||||
const _profile: any = {
|
const _profile: any = {
|
||||||
profileId: profile.id,
|
profileId: profile.id,
|
||||||
prefix: profile.prefix,
|
prefix: profile.prefix,
|
||||||
|
|
@ -6512,7 +6484,7 @@ export class ProfileEmployeeController extends Controller {
|
||||||
child4ShortName: child4 == null ? null : child4.orgChild4ShortName,
|
child4ShortName: child4 == null ? null : child4.orgChild4ShortName,
|
||||||
node: null,
|
node: null,
|
||||||
nodeId: null,
|
nodeId: null,
|
||||||
posNo: shortName,
|
posNo: null,
|
||||||
salary: profile.amount,
|
salary: profile.amount,
|
||||||
education:
|
education:
|
||||||
profile && profile.profileEducations.length > 0
|
profile && profile.profileEducations.length > 0
|
||||||
|
|
@ -6527,22 +6499,27 @@ export class ProfileEmployeeController extends Controller {
|
||||||
_profile.node = 4;
|
_profile.node = 4;
|
||||||
_profile.nodeId = _profile.child4Id;
|
_profile.nodeId = _profile.child4Id;
|
||||||
_profile.nodeShortName = _profile.child4ShortName;
|
_profile.nodeShortName = _profile.child4ShortName;
|
||||||
|
_profile.posNo = `${_profile.child4ShortName} ${_numPart}`;
|
||||||
} else if (_profile.child3Id != null) {
|
} else if (_profile.child3Id != null) {
|
||||||
_profile.node = 3;
|
_profile.node = 3;
|
||||||
_profile.nodeId = _profile.child3Id;
|
_profile.nodeId = _profile.child3Id;
|
||||||
_profile.nodeShortName = _profile.child3ShortName;
|
_profile.nodeShortName = _profile.child3ShortName;
|
||||||
|
_profile.posNo = `${_profile.child3ShortName} ${_numPart}`;
|
||||||
} else if (_profile.child2Id != null) {
|
} else if (_profile.child2Id != null) {
|
||||||
_profile.node = 2;
|
_profile.node = 2;
|
||||||
_profile.nodeId = _profile.child2Id;
|
_profile.nodeId = _profile.child2Id;
|
||||||
_profile.nodeShortName = _profile.child2ShortName;
|
_profile.nodeShortName = _profile.child2ShortName;
|
||||||
|
_profile.posNo = `${_profile.child2ShortName} ${_numPart}`;
|
||||||
} else if (_profile.child1Id != null) {
|
} else if (_profile.child1Id != null) {
|
||||||
_profile.node = 1;
|
_profile.node = 1;
|
||||||
_profile.nodeId = _profile.child1Id;
|
_profile.nodeId = _profile.child1Id;
|
||||||
_profile.nodeShortName = _profile.child1ShortName;
|
_profile.nodeShortName = _profile.child1ShortName;
|
||||||
|
_profile.posNo = `${_profile.child1ShortName} ${_numPart}`;
|
||||||
} else if (_profile.rootId != null) {
|
} else if (_profile.rootId != null) {
|
||||||
_profile.node = 0;
|
_profile.node = 0;
|
||||||
_profile.nodeId = _profile.rootId;
|
_profile.nodeId = _profile.rootId;
|
||||||
_profile.nodeShortName = _profile.rootShortName;
|
_profile.nodeShortName = _profile.rootShortName;
|
||||||
|
_profile.posNo = `${_profile.rootShortName} ${_numPart}`;
|
||||||
}
|
}
|
||||||
return new HttpSuccess(_profile);
|
return new HttpSuccess(_profile);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue