add dna
This commit is contained in:
parent
4aae619e90
commit
b0b1e06a78
5 changed files with 350 additions and 38 deletions
|
|
@ -4749,7 +4749,7 @@ export class CommandController extends Controller {
|
||||||
|
|
||||||
const posMaster = await this.employeePosMasterRepository.findOne({
|
const posMaster = await this.employeePosMasterRepository.findOne({
|
||||||
where: { id: profile.posmasterIdTemp },
|
where: { id: profile.posmasterIdTemp },
|
||||||
relations: ["orgRoot"],
|
relations: ["orgRoot", "orgChild1", "orgChild2", "orgChild3", "orgChild4"],
|
||||||
});
|
});
|
||||||
if (posMaster == null)
|
if (posMaster == null)
|
||||||
throw new HttpError(HttpStatusCode.NOT_FOUND, "ไม่พบข้อมูลตำแหน่งนี้");
|
throw new HttpError(HttpStatusCode.NOT_FOUND, "ไม่พบข้อมูลตำแหน่งนี้");
|
||||||
|
|
@ -4865,6 +4865,10 @@ export class CommandController extends Controller {
|
||||||
rootId: posMaster.orgRootId,
|
rootId: posMaster.orgRootId,
|
||||||
rootShortName: posMaster.orgRoot.orgRootShortName,
|
rootShortName: posMaster.orgRoot.orgRootShortName,
|
||||||
rootDnaId: posMaster.orgRoot.ancestorDNA,
|
rootDnaId: posMaster.orgRoot.ancestorDNA,
|
||||||
|
child1DnaId: posMaster.orgChild1.ancestorDNA,
|
||||||
|
child2DnaId: posMaster.orgChild2.ancestorDNA,
|
||||||
|
child3DnaId: posMaster.orgChild3.ancestorDNA,
|
||||||
|
child4DnaId: posMaster.orgChild4.ancestorDNA,
|
||||||
});
|
});
|
||||||
await this.profileEmployeeRepository.save(profile);
|
await this.profileEmployeeRepository.save(profile);
|
||||||
await this.employeePositionRepository.save(positionNew);
|
await this.employeePositionRepository.save(positionNew);
|
||||||
|
|
@ -4872,9 +4876,9 @@ export class CommandController extends Controller {
|
||||||
}),
|
}),
|
||||||
);
|
);
|
||||||
await new CallAPI()
|
await new CallAPI()
|
||||||
.PostData(req,
|
.PostData(req, "/placement/appointment/employee-appoint-21/report/excecute", {
|
||||||
"/placement/appointment/employee-appoint-21/report/excecute", { profileEmps: _reqBody }
|
profileEmps: _reqBody,
|
||||||
)
|
})
|
||||||
.catch((error) => {
|
.catch((error) => {
|
||||||
throw new Error("Failed. Cannot update status. ", error);
|
throw new Error("Failed. Cannot update status. ", error);
|
||||||
});
|
});
|
||||||
|
|
|
||||||
|
|
@ -5522,45 +5522,273 @@ export class OrganizationController extends Controller {
|
||||||
rootId: y.id,
|
rootId: y.id,
|
||||||
rootDnaId: y.ancestorDNA,
|
rootDnaId: y.ancestorDNA,
|
||||||
child1Id: null,
|
child1Id: null,
|
||||||
|
child1DnaId: null,
|
||||||
child2Id: null,
|
child2Id: null,
|
||||||
|
child2DnaId: null,
|
||||||
child3Id: null,
|
child3Id: null,
|
||||||
|
child3DnaId: null,
|
||||||
child4Id: null,
|
child4Id: null,
|
||||||
|
child4DnaId: null,
|
||||||
}));
|
}));
|
||||||
data2 = _data2.map((y) => ({
|
data2 = _data2.map((y) => ({
|
||||||
name: y.orgRootName,
|
name: y.orgRootName,
|
||||||
rootId: y.id,
|
rootId: y.id,
|
||||||
rootDnaId: y.ancestorDNA,
|
rootDnaId: y.ancestorDNA,
|
||||||
child1Id: null,
|
child1Id: null,
|
||||||
|
child1DnaId: null,
|
||||||
child2Id: null,
|
child2Id: null,
|
||||||
|
child2DnaId: null,
|
||||||
child3Id: null,
|
child3Id: null,
|
||||||
|
child3DnaId: null,
|
||||||
child4Id: null,
|
child4Id: null,
|
||||||
|
child4DnaId: null,
|
||||||
|
}));
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 1: {
|
||||||
|
const _data1 = await this.child1Repository.find({
|
||||||
|
where: {
|
||||||
|
id: requestBody.nodeId ?? "",
|
||||||
|
orgRoot: {
|
||||||
|
orgRootRankSub: In(orgRootRankSub1),
|
||||||
|
},
|
||||||
|
},
|
||||||
|
order: {
|
||||||
|
orgRoot: { orgRootOrder: "ASC" },
|
||||||
|
},
|
||||||
|
relations: ["orgRoot"],
|
||||||
|
});
|
||||||
|
const _data2 = await this.child1Repository.find({
|
||||||
|
where: [
|
||||||
|
{
|
||||||
|
id: requestBody.nodeId ?? "",
|
||||||
|
orgRoot: {
|
||||||
|
orgRootRankSub: In(orgRootRankSub2),
|
||||||
|
},
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: requestBody.nodeId ?? "",
|
||||||
|
orgRoot: {
|
||||||
|
orgRootRankSub: IsNull(),
|
||||||
|
},
|
||||||
|
},
|
||||||
|
],
|
||||||
|
order: {
|
||||||
|
orgRoot: { orgRootOrder: "ASC" },
|
||||||
|
},
|
||||||
|
relations: ["orgRoot"],
|
||||||
|
});
|
||||||
|
data1 = _data1.map((y) => ({
|
||||||
|
name: y.orgRoot.orgRootName,
|
||||||
|
rootId: y.orgRoot.id,
|
||||||
|
rootDnaId: y.orgRoot.ancestorDNA,
|
||||||
|
child1Id: y.id,
|
||||||
|
child1DnaId: y.ancestorDNA,
|
||||||
|
child2Id: null,
|
||||||
|
child2DnaId: null,
|
||||||
|
child3Id: null,
|
||||||
|
child3DnaId: null,
|
||||||
|
child4Id: null,
|
||||||
|
child4DnaId: null,
|
||||||
|
}));
|
||||||
|
data2 = _data2.map((y) => ({
|
||||||
|
name: y.orgRoot.orgRootName,
|
||||||
|
rootId: y.orgRoot.id,
|
||||||
|
rootDnaId: y.orgRoot.ancestorDNA,
|
||||||
|
child1Id: y.id,
|
||||||
|
child1DnaId: y.ancestorDNA,
|
||||||
|
child2Id: null,
|
||||||
|
child2DnaId: null,
|
||||||
|
child3Id: null,
|
||||||
|
child3DnaId: null,
|
||||||
|
child4Id: null,
|
||||||
|
child4DnaId: null,
|
||||||
|
}));
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 2: {
|
||||||
|
const _data1 = await this.child2Repository.find({
|
||||||
|
where: {
|
||||||
|
id: requestBody.nodeId ?? "",
|
||||||
|
orgRoot: {
|
||||||
|
orgRootRankSub: In(orgRootRankSub1),
|
||||||
|
},
|
||||||
|
},
|
||||||
|
order: {
|
||||||
|
orgRoot: { orgRootOrder: "ASC" },
|
||||||
|
},
|
||||||
|
relations: ["orgRoot", "orgChild1"],
|
||||||
|
});
|
||||||
|
const _data2 = await this.child2Repository.find({
|
||||||
|
where: [
|
||||||
|
{
|
||||||
|
id: requestBody.nodeId ?? "",
|
||||||
|
orgRoot: {
|
||||||
|
orgRootRankSub: In(orgRootRankSub2),
|
||||||
|
},
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: requestBody.nodeId ?? "",
|
||||||
|
orgRoot: {
|
||||||
|
orgRootRankSub: IsNull(),
|
||||||
|
},
|
||||||
|
},
|
||||||
|
],
|
||||||
|
order: {
|
||||||
|
orgRoot: { orgRootOrder: "ASC" },
|
||||||
|
},
|
||||||
|
relations: ["orgRoot", "orgChild1"],
|
||||||
|
});
|
||||||
|
data1 = _data1.map((y) => ({
|
||||||
|
name: y.orgRoot.orgRootName,
|
||||||
|
rootId: y.orgRoot.id,
|
||||||
|
rootDnaId: y.orgRoot.ancestorDNA,
|
||||||
|
child1Id: y.orgChild1.id,
|
||||||
|
child1DnaId: y.orgChild1.ancestorDNA,
|
||||||
|
child2Id: y.id,
|
||||||
|
child2DnaId: y.ancestorDNA,
|
||||||
|
child3Id: null,
|
||||||
|
child3DnaId: null,
|
||||||
|
child4Id: null,
|
||||||
|
child4DnaId: null,
|
||||||
|
}));
|
||||||
|
data2 = _data2.map((y) => ({
|
||||||
|
name: y.orgRoot.orgRootName,
|
||||||
|
rootId: y.orgRoot.id,
|
||||||
|
rootDnaId: y.orgRoot.ancestorDNA,
|
||||||
|
child1Id: y.orgChild1.id,
|
||||||
|
child1DnaId: y.orgChild1.ancestorDNA,
|
||||||
|
child2Id: y.id,
|
||||||
|
child2DnaId: y.ancestorDNA,
|
||||||
|
child3Id: null,
|
||||||
|
child3DnaId: null,
|
||||||
|
child4Id: null,
|
||||||
|
child4DnaId: null,
|
||||||
|
}));
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 3: {
|
||||||
|
const _data1 = await this.child3Repository.find({
|
||||||
|
where: {
|
||||||
|
id: requestBody.nodeId ?? "",
|
||||||
|
orgRoot: {
|
||||||
|
orgRootRankSub: In(orgRootRankSub1),
|
||||||
|
},
|
||||||
|
},
|
||||||
|
order: {
|
||||||
|
orgRoot: { orgRootOrder: "ASC" },
|
||||||
|
},
|
||||||
|
relations: ["orgRoot", "orgChild1", "orgChild2"],
|
||||||
|
});
|
||||||
|
const _data2 = await this.child3Repository.find({
|
||||||
|
where: [
|
||||||
|
{
|
||||||
|
id: requestBody.nodeId ?? "",
|
||||||
|
orgRoot: {
|
||||||
|
orgRootRankSub: In(orgRootRankSub2),
|
||||||
|
},
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: requestBody.nodeId ?? "",
|
||||||
|
orgRoot: {
|
||||||
|
orgRootRankSub: IsNull(),
|
||||||
|
},
|
||||||
|
},
|
||||||
|
],
|
||||||
|
order: {
|
||||||
|
orgRoot: { orgRootOrder: "ASC" },
|
||||||
|
},
|
||||||
|
relations: ["orgRoot", "orgChild1", "orgChild2"],
|
||||||
|
});
|
||||||
|
data1 = _data1.map((y) => ({
|
||||||
|
name: y.orgRoot.orgRootName,
|
||||||
|
rootId: y.orgRoot.id,
|
||||||
|
rootDnaId: y.orgRoot.ancestorDNA,
|
||||||
|
child1Id: y.orgChild1.id,
|
||||||
|
child1DnaId: y.orgChild1.ancestorDNA,
|
||||||
|
child2Id: y.orgChild2.id,
|
||||||
|
child2DnaId: y.orgChild2.ancestorDNA,
|
||||||
|
child3Id: y.id,
|
||||||
|
child3DnaId: y.ancestorDNA,
|
||||||
|
child4Id: null,
|
||||||
|
child4DnaId: null,
|
||||||
|
}));
|
||||||
|
data2 = _data2.map((y) => ({
|
||||||
|
name: y.orgRoot.orgRootName,
|
||||||
|
rootId: y.orgRoot.id,
|
||||||
|
rootDnaId: y.orgRoot.ancestorDNA,
|
||||||
|
child1Id: y.orgChild1.id,
|
||||||
|
child1DnaId: y.orgChild1.ancestorDNA,
|
||||||
|
child2Id: y.orgChild2.id,
|
||||||
|
child2DnaId: y.orgChild2.ancestorDNA,
|
||||||
|
child3Id: y.id,
|
||||||
|
child3DnaId: y.ancestorDNA,
|
||||||
|
child4Id: null,
|
||||||
|
child4DnaId: null,
|
||||||
|
}));
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 4: {
|
||||||
|
const _data1 = await this.child4Repository.find({
|
||||||
|
where: {
|
||||||
|
id: requestBody.nodeId ?? "",
|
||||||
|
orgRoot: {
|
||||||
|
orgRootRankSub: In(orgRootRankSub1),
|
||||||
|
},
|
||||||
|
},
|
||||||
|
order: {
|
||||||
|
orgRoot: { orgRootOrder: "ASC" },
|
||||||
|
},
|
||||||
|
relations: ["orgRoot", "orgChild1", "orgChild2", "orgChild3"],
|
||||||
|
});
|
||||||
|
const _data2 = await this.child4Repository.find({
|
||||||
|
where: [
|
||||||
|
{
|
||||||
|
id: requestBody.nodeId ?? "",
|
||||||
|
orgRoot: {
|
||||||
|
orgRootRankSub: In(orgRootRankSub2),
|
||||||
|
},
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: requestBody.nodeId ?? "",
|
||||||
|
orgRoot: {
|
||||||
|
orgRootRankSub: IsNull(),
|
||||||
|
},
|
||||||
|
},
|
||||||
|
],
|
||||||
|
order: {
|
||||||
|
orgRoot: { orgRootOrder: "ASC" },
|
||||||
|
},
|
||||||
|
relations: ["orgRoot", "orgChild1", "orgChild2", "orgChild3"],
|
||||||
|
});
|
||||||
|
data1 = _data1.map((y) => ({
|
||||||
|
name: y.orgRoot.orgRootName,
|
||||||
|
rootId: y.orgRoot.id,
|
||||||
|
rootDnaId: y.orgRoot.ancestorDNA,
|
||||||
|
child1Id: y.orgChild1.id,
|
||||||
|
child1DnaId: y.orgChild1.ancestorDNA,
|
||||||
|
child2Id: y.orgChild2.id,
|
||||||
|
child2DnaId: y.orgChild2.ancestorDNA,
|
||||||
|
child3Id: y.orgChild3.id,
|
||||||
|
child3DnaId: y.orgChild3.ancestorDNA,
|
||||||
|
child4Id: y.id,
|
||||||
|
child4DnaId: y.ancestorDNA,
|
||||||
|
}));
|
||||||
|
data2 = _data2.map((y) => ({
|
||||||
|
name: y.orgRoot.orgRootName,
|
||||||
|
rootId: y.orgRoot.id,
|
||||||
|
rootDnaId: y.orgRoot.ancestorDNA,
|
||||||
|
child1Id: y.orgChild1.id,
|
||||||
|
child1DnaId: y.orgChild1.ancestorDNA,
|
||||||
|
child2Id: y.orgChild2.id,
|
||||||
|
child2DnaId: y.orgChild2.ancestorDNA,
|
||||||
|
child3Id: y.orgChild3.id,
|
||||||
|
child3DnaId: y.orgChild3.ancestorDNA,
|
||||||
|
child4Id: y.id,
|
||||||
|
child4DnaId: y.ancestorDNA,
|
||||||
}));
|
}));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
// case 1: {
|
|
||||||
// const data = await this.child1Repository.find({
|
|
||||||
// where: { id: requestBody.nodeId },
|
|
||||||
// });
|
|
||||||
// return new HttpSuccess(data);
|
|
||||||
// }
|
|
||||||
// case 2: {
|
|
||||||
// const data = await this.child2Repository.find({
|
|
||||||
// where: { id: requestBody.nodeId },
|
|
||||||
// });
|
|
||||||
// return new HttpSuccess(data);
|
|
||||||
// }
|
|
||||||
// case 3: {
|
|
||||||
// const data = await this.child3Repository.find({
|
|
||||||
// where: { id: requestBody.nodeId },
|
|
||||||
// });
|
|
||||||
// return new HttpSuccess(data);
|
|
||||||
// }
|
|
||||||
// case 4: {
|
|
||||||
// const data = await this.child4Repository.find({
|
|
||||||
// where: { id: requestBody.nodeId },
|
|
||||||
// });
|
|
||||||
// return new HttpSuccess(data);
|
|
||||||
// }
|
|
||||||
default: {
|
default: {
|
||||||
const orgRevision = await this.orgRevisionRepository.findOne({
|
const orgRevision = await this.orgRevisionRepository.findOne({
|
||||||
where: {
|
where: {
|
||||||
|
|
@ -5646,7 +5874,7 @@ export class OrganizationController extends Controller {
|
||||||
}
|
}
|
||||||
return new HttpSuccess({
|
return new HttpSuccess({
|
||||||
rootId: data.orgRootId,
|
rootId: data.orgRootId,
|
||||||
rootDnaId: data.ancestorDNA,
|
rootDnaId: data.orgRoot == null ? null : data.orgRoot.ancestorDNA,
|
||||||
root: data.orgRoot == null ? null : data.orgRoot.orgRootName,
|
root: data.orgRoot == null ? null : data.orgRoot.orgRootName,
|
||||||
rootShortName: data.orgRoot == null ? null : data.orgRoot.orgRootShortName,
|
rootShortName: data.orgRoot == null ? null : data.orgRoot.orgRootShortName,
|
||||||
child1Id: data.id,
|
child1Id: data.id,
|
||||||
|
|
@ -5668,11 +5896,11 @@ export class OrganizationController extends Controller {
|
||||||
}
|
}
|
||||||
return new HttpSuccess({
|
return new HttpSuccess({
|
||||||
rootId: data.orgRootId,
|
rootId: data.orgRootId,
|
||||||
rootDnaId: data.ancestorDNA,
|
rootDnaId: data.orgRoot == null ? null : data.orgRoot.ancestorDNA,
|
||||||
root: data.orgRoot == null ? null : data.orgRoot.orgRootName,
|
root: data.orgRoot == null ? null : data.orgRoot.orgRootName,
|
||||||
rootShortName: data.orgRoot == null ? null : data.orgRoot.orgRootShortName,
|
rootShortName: data.orgRoot == null ? null : data.orgRoot.orgRootShortName,
|
||||||
child1Id: data.orgChild1Id,
|
child1Id: data.orgChild1Id,
|
||||||
child1DnaId: data.ancestorDNA,
|
child1DnaId: data.orgChild1 == null ? null : data.orgChild1.ancestorDNA,
|
||||||
child1: data.orgChild1 == null ? null : data.orgChild1.orgChild1Name,
|
child1: data.orgChild1 == null ? null : data.orgChild1.orgChild1Name,
|
||||||
child1ShortName: data.orgChild1 == null ? null : data.orgChild1.orgChild1ShortName,
|
child1ShortName: data.orgChild1 == null ? null : data.orgChild1.orgChild1ShortName,
|
||||||
child2Id: data.id,
|
child2Id: data.id,
|
||||||
|
|
@ -5695,15 +5923,15 @@ export class OrganizationController extends Controller {
|
||||||
}
|
}
|
||||||
return new HttpSuccess({
|
return new HttpSuccess({
|
||||||
rootId: data.orgRootId,
|
rootId: data.orgRootId,
|
||||||
rootDnaId: data.ancestorDNA,
|
rootDnaId: data.orgRoot == null ? null : data.orgRoot.ancestorDNA,
|
||||||
root: data.orgRoot == null ? null : data.orgRoot.orgRootName,
|
root: data.orgRoot == null ? null : data.orgRoot.orgRootName,
|
||||||
rootShortName: data.orgRoot == null ? null : data.orgRoot.orgRootShortName,
|
rootShortName: data.orgRoot == null ? null : data.orgRoot.orgRootShortName,
|
||||||
child1Id: data.orgChild1Id,
|
child1Id: data.orgChild1Id,
|
||||||
child1DnaId: data.ancestorDNA,
|
child1DnaId: data.orgChild1 == null ? null : data.orgChild1.ancestorDNA,
|
||||||
child1: data.orgChild1 == null ? null : data.orgChild1.orgChild1Name,
|
child1: data.orgChild1 == null ? null : data.orgChild1.orgChild1Name,
|
||||||
child1ShortName: data.orgChild1 == null ? null : data.orgChild1.orgChild1ShortName,
|
child1ShortName: data.orgChild1 == null ? null : data.orgChild1.orgChild1ShortName,
|
||||||
child2Id: data.orgChild2Id,
|
child2Id: data.orgChild2Id,
|
||||||
child2DnaId: data.ancestorDNA,
|
child2DnaId: data.orgChild2 == null ? null : data.orgChild2.ancestorDNA,
|
||||||
child2: data.orgChild2 == null ? null : data.orgChild2.orgChild2Name,
|
child2: data.orgChild2 == null ? null : data.orgChild2.orgChild2Name,
|
||||||
child2ShortName: data.orgChild2 == null ? null : data.orgChild2.orgChild2ShortName,
|
child2ShortName: data.orgChild2 == null ? null : data.orgChild2.orgChild2ShortName,
|
||||||
child3Id: data.id,
|
child3Id: data.id,
|
||||||
|
|
@ -5727,19 +5955,19 @@ export class OrganizationController extends Controller {
|
||||||
}
|
}
|
||||||
return new HttpSuccess({
|
return new HttpSuccess({
|
||||||
rootId: data.orgRootId,
|
rootId: data.orgRootId,
|
||||||
rootDnaId: data.ancestorDNA,
|
rootDnaId: data.orgRoot == null ? null : data.orgRoot.ancestorDNA,
|
||||||
root: data.orgRoot == null ? null : data.orgRoot.orgRootName,
|
root: data.orgRoot == null ? null : data.orgRoot.orgRootName,
|
||||||
rootShortName: data.orgRoot == null ? null : data.orgRoot.orgRootShortName,
|
rootShortName: data.orgRoot == null ? null : data.orgRoot.orgRootShortName,
|
||||||
child1Id: data.orgChild1Id,
|
child1Id: data.orgChild1Id,
|
||||||
child1DnaId: data.ancestorDNA,
|
child1DnaId: data.orgChild1 == null ? null : data.orgChild1.ancestorDNA,
|
||||||
child1: data.orgChild1 == null ? null : data.orgChild1.orgChild1Name,
|
child1: data.orgChild1 == null ? null : data.orgChild1.orgChild1Name,
|
||||||
child1ShortName: data.orgChild1 == null ? null : data.orgChild1.orgChild1ShortName,
|
child1ShortName: data.orgChild1 == null ? null : data.orgChild1.orgChild1ShortName,
|
||||||
child2Id: data.orgChild2Id,
|
child2Id: data.orgChild2Id,
|
||||||
child2DnaId: data.ancestorDNA,
|
child2DnaId: data.orgChild2 == null ? null : data.orgChild2.ancestorDNA,
|
||||||
child2: data.orgChild2 == null ? null : data.orgChild2.orgChild2Name,
|
child2: data.orgChild2 == null ? null : data.orgChild2.orgChild2Name,
|
||||||
child2ShortName: data.orgChild2 == null ? null : data.orgChild2.orgChild2ShortName,
|
child2ShortName: data.orgChild2 == null ? null : data.orgChild2.orgChild2ShortName,
|
||||||
child3Id: data.orgChild3Id,
|
child3Id: data.orgChild3Id,
|
||||||
child3DnaId: data.ancestorDNA,
|
child3DnaId: data.orgChild3 == null ? null : data.orgChild3.ancestorDNA,
|
||||||
child3: data.orgChild3 == null ? null : data.orgChild3.orgChild3Name,
|
child3: data.orgChild3 == null ? null : data.orgChild3.orgChild3Name,
|
||||||
child3ShortName: data.orgChild3 == null ? null : data.orgChild3.orgChild3ShortName,
|
child3ShortName: data.orgChild3 == null ? null : data.orgChild3.orgChild3ShortName,
|
||||||
child4Id: data.id,
|
child4Id: data.id,
|
||||||
|
|
|
||||||
|
|
@ -6452,18 +6452,23 @@ export class ProfileController extends Controller {
|
||||||
posTypeId: profile.posType == null ? null : profile.posType.id,
|
posTypeId: profile.posType == null ? null : profile.posType.id,
|
||||||
orgRevisionId: root == null ? null : root.orgRevisionId,
|
orgRevisionId: root == null ? null : root.orgRevisionId,
|
||||||
rootId: root == null ? null : root.id,
|
rootId: root == null ? null : root.id,
|
||||||
|
rootDnaId: root == null ? null : root.ancestorDNA,
|
||||||
root: root == null ? null : root.orgRootName,
|
root: root == null ? null : root.orgRootName,
|
||||||
rootShortName: root == null ? null : root.orgRootShortName,
|
rootShortName: root == null ? null : root.orgRootShortName,
|
||||||
child1Id: child1 == null ? null : child1.id,
|
child1Id: child1 == null ? null : child1.id,
|
||||||
|
child1DnaId: child1 == null ? null : child1.ancestorDNA,
|
||||||
child1: child1 == null ? null : child1.orgChild1Name,
|
child1: child1 == null ? null : child1.orgChild1Name,
|
||||||
child1ShortName: child1 == null ? null : child1.orgChild1ShortName,
|
child1ShortName: child1 == null ? null : child1.orgChild1ShortName,
|
||||||
child2Id: child2 == null ? null : child2.id,
|
child2Id: child2 == null ? null : child2.id,
|
||||||
|
child2DnaId: child2 == null ? null : child2.ancestorDNA,
|
||||||
child2: child2 == null ? null : child2.orgChild2Name,
|
child2: child2 == null ? null : child2.orgChild2Name,
|
||||||
child2ShortName: child2 == null ? null : child2.orgChild2ShortName,
|
child2ShortName: child2 == null ? null : child2.orgChild2ShortName,
|
||||||
child3Id: child3 == null ? null : child3.id,
|
child3Id: child3 == null ? null : child3.id,
|
||||||
|
child3DnaId: child3 == null ? null : child3.ancestorDNA,
|
||||||
child3: child3 == null ? null : child3.orgChild3Name,
|
child3: child3 == null ? null : child3.orgChild3Name,
|
||||||
child3ShortName: child3 == null ? null : child3.orgChild3ShortName,
|
child3ShortName: child3 == null ? null : child3.orgChild3ShortName,
|
||||||
child4Id: child4 == null ? null : child4.id,
|
child4Id: child4 == null ? null : child4.id,
|
||||||
|
child4DnaId: child4 == null ? null : child4.ancestorDNA,
|
||||||
child4: child4 == null ? null : child4.orgChild4Name,
|
child4: child4 == null ? null : child4.orgChild4Name,
|
||||||
child4ShortName: child4 == null ? null : child4.orgChild4ShortName,
|
child4ShortName: child4 == null ? null : child4.orgChild4ShortName,
|
||||||
node: null,
|
node: null,
|
||||||
|
|
@ -8038,6 +8043,12 @@ export class ProfileController extends Controller {
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgRoot == null
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgRoot == null
|
||||||
? null
|
? null
|
||||||
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgRootId,
|
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgRootId,
|
||||||
|
rootDnaId:
|
||||||
|
profile.current_holders == null ||
|
||||||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
||||||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgRoot == null
|
||||||
|
? null
|
||||||
|
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.ancestorDNA,
|
||||||
root:
|
root:
|
||||||
profile.current_holders == null ||
|
profile.current_holders == null ||
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
||||||
|
|
@ -8050,6 +8061,12 @@ export class ProfileController extends Controller {
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild1 == null
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild1 == null
|
||||||
? null
|
? null
|
||||||
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild1Id,
|
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild1Id,
|
||||||
|
child1DnaId:
|
||||||
|
profile.current_holders == null ||
|
||||||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
||||||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild1 == null
|
||||||
|
? null
|
||||||
|
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.ancestorDNA,
|
||||||
child1:
|
child1:
|
||||||
profile.current_holders == null ||
|
profile.current_holders == null ||
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
||||||
|
|
@ -8063,6 +8080,12 @@ export class ProfileController extends Controller {
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild2 == null
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild2 == null
|
||||||
? null
|
? null
|
||||||
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild2Id,
|
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild2Id,
|
||||||
|
child2DnaId:
|
||||||
|
profile.current_holders == null ||
|
||||||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
||||||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild2 == null
|
||||||
|
? null
|
||||||
|
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.ancestorDNA,
|
||||||
child2:
|
child2:
|
||||||
profile.current_holders == null ||
|
profile.current_holders == null ||
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
||||||
|
|
@ -8076,6 +8099,12 @@ export class ProfileController extends Controller {
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild3 == null
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild3 == null
|
||||||
? null
|
? null
|
||||||
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild3Id,
|
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild3Id,
|
||||||
|
child3DnaId:
|
||||||
|
profile.current_holders == null ||
|
||||||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
||||||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild3 == null
|
||||||
|
? null
|
||||||
|
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.ancestorDNA,
|
||||||
child3:
|
child3:
|
||||||
profile.current_holders == null ||
|
profile.current_holders == null ||
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
||||||
|
|
@ -8089,6 +8118,12 @@ export class ProfileController extends Controller {
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild4 == null
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild4 == null
|
||||||
? null
|
? null
|
||||||
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild4Id,
|
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild4Id,
|
||||||
|
child4DnaId:
|
||||||
|
profile.current_holders == null ||
|
||||||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
||||||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild4 == null
|
||||||
|
? null
|
||||||
|
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.ancestorDNA,
|
||||||
child4:
|
child4:
|
||||||
profile.current_holders == null ||
|
profile.current_holders == null ||
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
||||||
|
|
|
||||||
|
|
@ -2242,18 +2242,23 @@ export class ProfileEmployeeController extends Controller {
|
||||||
posExecutiveId:
|
posExecutiveId:
|
||||||
position == null || position.posExecutive == null ? null : position.posExecutive.id,
|
position == null || position.posExecutive == null ? null : position.posExecutive.id,
|
||||||
rootId: root == null ? null : root.id,
|
rootId: root == null ? null : root.id,
|
||||||
|
rootDnaId: root == null ? null : root.ancestorDNA,
|
||||||
root: root == null ? null : root.orgRootName,
|
root: root == null ? null : root.orgRootName,
|
||||||
rootShortName: root == null ? null : root.orgRootShortName,
|
rootShortName: root == null ? null : root.orgRootShortName,
|
||||||
child1Id: child1 == null ? null : child1.id,
|
child1Id: child1 == null ? null : child1.id,
|
||||||
|
child1DnaId: child1 == null ? null : child1.ancestorDNA,
|
||||||
child1: child1 == null ? null : child1.orgChild1Name,
|
child1: child1 == null ? null : child1.orgChild1Name,
|
||||||
child1ShortName: child1 == null ? null : child1.orgChild1ShortName,
|
child1ShortName: child1 == null ? null : child1.orgChild1ShortName,
|
||||||
child2Id: child2 == null ? null : child2.id,
|
child2Id: child2 == null ? null : child2.id,
|
||||||
|
child2DnaId: child2 == null ? null : child2.ancestorDNA,
|
||||||
child2: child2 == null ? null : child2.orgChild2Name,
|
child2: child2 == null ? null : child2.orgChild2Name,
|
||||||
child2ShortName: child2 == null ? null : child2.orgChild2ShortName,
|
child2ShortName: child2 == null ? null : child2.orgChild2ShortName,
|
||||||
child3Id: child3 == null ? null : child3.id,
|
child3Id: child3 == null ? null : child3.id,
|
||||||
|
child3DnaId: child3 == null ? null : child3.ancestorDNA,
|
||||||
child3: child3 == null ? null : child3.orgChild3Name,
|
child3: child3 == null ? null : child3.orgChild3Name,
|
||||||
child3ShortName: child3 == null ? null : child3.orgChild3ShortName,
|
child3ShortName: child3 == null ? null : child3.orgChild3ShortName,
|
||||||
child4Id: child4 == null ? null : child4.id,
|
child4Id: child4 == null ? null : child4.id,
|
||||||
|
child4DnaId: child4 == null ? null : child4.ancestorDNA,
|
||||||
child4: child4 == null ? null : child4.orgChild4Name,
|
child4: child4 == null ? null : child4.orgChild4Name,
|
||||||
child4ShortName: child4 == null ? null : child4.orgChild4ShortName,
|
child4ShortName: child4 == null ? null : child4.orgChild4ShortName,
|
||||||
node: null,
|
node: null,
|
||||||
|
|
@ -3607,6 +3612,12 @@ export class ProfileEmployeeController extends Controller {
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgRoot == null
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgRoot == null
|
||||||
? null
|
? null
|
||||||
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgRootId,
|
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgRootId,
|
||||||
|
rootDnaId:
|
||||||
|
profile.current_holders == null ||
|
||||||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
||||||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgRoot == null
|
||||||
|
? null
|
||||||
|
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.ancestorDNA,
|
||||||
root:
|
root:
|
||||||
profile.current_holders == null ||
|
profile.current_holders == null ||
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
||||||
|
|
@ -3619,6 +3630,12 @@ export class ProfileEmployeeController extends Controller {
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild1 == null
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild1 == null
|
||||||
? null
|
? null
|
||||||
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild1Id,
|
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild1Id,
|
||||||
|
child1DnaId:
|
||||||
|
profile.current_holders == null ||
|
||||||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
||||||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild1 == null
|
||||||
|
? null
|
||||||
|
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.ancestorDNA,
|
||||||
child1:
|
child1:
|
||||||
profile.current_holders == null ||
|
profile.current_holders == null ||
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
||||||
|
|
@ -3632,6 +3649,12 @@ export class ProfileEmployeeController extends Controller {
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild2 == null
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild2 == null
|
||||||
? null
|
? null
|
||||||
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild2Id,
|
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild2Id,
|
||||||
|
child2DnaId:
|
||||||
|
profile.current_holders == null ||
|
||||||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
||||||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild2 == null
|
||||||
|
? null
|
||||||
|
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.ancestorDNA,
|
||||||
child2:
|
child2:
|
||||||
profile.current_holders == null ||
|
profile.current_holders == null ||
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
||||||
|
|
@ -3645,6 +3668,12 @@ export class ProfileEmployeeController extends Controller {
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild3 == null
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild3 == null
|
||||||
? null
|
? null
|
||||||
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild3Id,
|
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild3Id,
|
||||||
|
child3DnaId:
|
||||||
|
profile.current_holders == null ||
|
||||||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
||||||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild3 == null
|
||||||
|
? null
|
||||||
|
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.ancestorDNA,
|
||||||
child3:
|
child3:
|
||||||
profile.current_holders == null ||
|
profile.current_holders == null ||
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
||||||
|
|
@ -3658,6 +3687,12 @@ export class ProfileEmployeeController extends Controller {
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild4 == null
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild4 == null
|
||||||
? null
|
? null
|
||||||
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild4Id,
|
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild4Id,
|
||||||
|
child4DnaId:
|
||||||
|
profile.current_holders == null ||
|
||||||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
||||||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.orgChild4 == null
|
||||||
|
? null
|
||||||
|
: profile.current_holders.find((x) => x.orgRevisionId == revisionId)?.ancestorDNA,
|
||||||
child4:
|
child4:
|
||||||
profile.current_holders == null ||
|
profile.current_holders == null ||
|
||||||
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
profile.current_holders.find((x) => x.orgRevisionId == revisionId) == null ||
|
||||||
|
|
@ -4550,18 +4585,23 @@ export class ProfileEmployeeController extends Controller {
|
||||||
posTypeId: profile.posType == null ? null : profile.posType.id,
|
posTypeId: profile.posType == null ? null : profile.posType.id,
|
||||||
// posExecutiveName: "",
|
// posExecutiveName: "",
|
||||||
rootId: root == null ? null : root.id,
|
rootId: root == null ? null : root.id,
|
||||||
|
rootDnaId: root == null ? null : root.ancestorDNA,
|
||||||
root: root == null ? null : root.orgRootName,
|
root: root == null ? null : root.orgRootName,
|
||||||
rootShortName: root == null ? null : root.orgRootShortName,
|
rootShortName: root == null ? null : root.orgRootShortName,
|
||||||
child1Id: child1 == null ? null : child1.id,
|
child1Id: child1 == null ? null : child1.id,
|
||||||
|
child1DnaId: child1 == null ? null : child1.ancestorDNA,
|
||||||
child1: child1 == null ? null : child1.orgChild1Name,
|
child1: child1 == null ? null : child1.orgChild1Name,
|
||||||
child1ShortName: child1 == null ? null : child1.orgChild1ShortName,
|
child1ShortName: child1 == null ? null : child1.orgChild1ShortName,
|
||||||
child2Id: child2 == null ? null : child2.id,
|
child2Id: child2 == null ? null : child2.id,
|
||||||
|
child2DnaId: child2 == null ? null : child2.ancestorDNA,
|
||||||
child2: child2 == null ? null : child2.orgChild2Name,
|
child2: child2 == null ? null : child2.orgChild2Name,
|
||||||
child2ShortName: child2 == null ? null : child2.orgChild2ShortName,
|
child2ShortName: child2 == null ? null : child2.orgChild2ShortName,
|
||||||
child3Id: child3 == null ? null : child3.id,
|
child3Id: child3 == null ? null : child3.id,
|
||||||
|
child3DnaId: child3 == null ? null : child3.ancestorDNA,
|
||||||
child3: child3 == null ? null : child3.orgChild3Name,
|
child3: child3 == null ? null : child3.orgChild3Name,
|
||||||
child3ShortName: child3 == null ? null : child3.orgChild3ShortName,
|
child3ShortName: child3 == null ? null : child3.orgChild3ShortName,
|
||||||
child4Id: child4 == null ? null : child4.id,
|
child4Id: child4 == null ? null : child4.id,
|
||||||
|
child4DnaId: child4 == null ? null : child4.ancestorDNA,
|
||||||
child4: child4 == null ? null : child4.orgChild4Name,
|
child4: child4 == null ? null : child4.orgChild4Name,
|
||||||
child4ShortName: child4 == null ? null : child4.orgChild4ShortName,
|
child4ShortName: child4 == null ? null : child4.orgChild4ShortName,
|
||||||
node: null,
|
node: null,
|
||||||
|
|
|
||||||
|
|
@ -3814,18 +3814,23 @@ export class ProfileEmployeeTempController extends Controller {
|
||||||
posTypeId: profile.posType == null ? null : profile.posType.id,
|
posTypeId: profile.posType == null ? null : profile.posType.id,
|
||||||
// posExecutiveName: "",
|
// posExecutiveName: "",
|
||||||
rootId: root == null ? null : root.id,
|
rootId: root == null ? null : root.id,
|
||||||
|
rootDnaId: root == null ? null : root.ancestorDNA,
|
||||||
root: root == null ? null : root.orgRootName,
|
root: root == null ? null : root.orgRootName,
|
||||||
rootShortName: root == null ? null : root.orgRootShortName,
|
rootShortName: root == null ? null : root.orgRootShortName,
|
||||||
child1Id: child1 == null ? null : child1.id,
|
child1Id: child1 == null ? null : child1.id,
|
||||||
|
child1DnaId: child1 == null ? null : child1.ancestorDNA,
|
||||||
child1: child1 == null ? null : child1.orgChild1Name,
|
child1: child1 == null ? null : child1.orgChild1Name,
|
||||||
child1ShortName: child1 == null ? null : child1.orgChild1ShortName,
|
child1ShortName: child1 == null ? null : child1.orgChild1ShortName,
|
||||||
child2Id: child2 == null ? null : child2.id,
|
child2Id: child2 == null ? null : child2.id,
|
||||||
|
child2DnaId: child2 == null ? null : child2.ancestorDNA,
|
||||||
child2: child2 == null ? null : child2.orgChild2Name,
|
child2: child2 == null ? null : child2.orgChild2Name,
|
||||||
child2ShortName: child2 == null ? null : child2.orgChild2ShortName,
|
child2ShortName: child2 == null ? null : child2.orgChild2ShortName,
|
||||||
child3Id: child3 == null ? null : child3.id,
|
child3Id: child3 == null ? null : child3.id,
|
||||||
|
child3DnaId: child3 == null ? null : child3.ancestorDNA,
|
||||||
child3: child3 == null ? null : child3.orgChild3Name,
|
child3: child3 == null ? null : child3.orgChild3Name,
|
||||||
child3ShortName: child3 == null ? null : child3.orgChild3ShortName,
|
child3ShortName: child3 == null ? null : child3.orgChild3ShortName,
|
||||||
child4Id: child4 == null ? null : child4.id,
|
child4Id: child4 == null ? null : child4.id,
|
||||||
|
child4DnaId: child4 == null ? null : child4.ancestorDNA,
|
||||||
child4: child4 == null ? null : child4.orgChild4Name,
|
child4: child4 == null ? null : child4.orgChild4Name,
|
||||||
child4ShortName: child4 == null ? null : child4.orgChild4ShortName,
|
child4ShortName: child4 == null ? null : child4.orgChild4ShortName,
|
||||||
node: null,
|
node: null,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue