fix test
This commit is contained in:
parent
16622b4768
commit
acbd0604f8
1 changed files with 3 additions and 3 deletions
|
|
@ -33,14 +33,14 @@ export async function CreatePosMasterHistoryOfficer(
|
||||||
});
|
});
|
||||||
|
|
||||||
if (!pm) return false;
|
if (!pm) return false;
|
||||||
if (!pm.ancestorDNA) return false;
|
// if (!pm.ancestorDNA) return false; // ทำให้สร้างตำแหน่งใหม่โครงสร้างปัจจุบัน(ไม่มีancestorDNA)แล้วไม่ปั๊มประวัติ
|
||||||
const _null: any = null;
|
const _null: any = null;
|
||||||
const h = new PosMasterHistory();
|
const h = new PosMasterHistory();
|
||||||
const selectedPosition =
|
const selectedPosition =
|
||||||
pm.positions.length > 0
|
pm.positions.length > 0
|
||||||
? pm.positions.find((p) => p.positionIsSelected === true) ?? null
|
? pm.positions.find((p) => p.positionIsSelected === true) ?? null
|
||||||
: null;
|
: null;
|
||||||
h.ancestorDNA = pm.ancestorDNA;
|
h.ancestorDNA = pm.ancestorDNA? pm.ancestorDNA : _null;
|
||||||
h.prefix = pm.current_holder?.prefix || _null;
|
h.prefix = pm.current_holder?.prefix || _null;
|
||||||
h.firstName = pm.current_holder?.firstName || _null;
|
h.firstName = pm.current_holder?.firstName || _null;
|
||||||
h.lastName = pm.current_holder?.lastName || _null;
|
h.lastName = pm.current_holder?.lastName || _null;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue