fix
This commit is contained in:
parent
3b067ef714
commit
59eec3d7b9
2 changed files with 31 additions and 9 deletions
|
|
@ -7798,6 +7798,7 @@ export class ReportController extends Controller {
|
|||
}),
|
||||
)
|
||||
.andWhere("salaryProfile.status35 = :status", { status: "PENDING" })
|
||||
.andWhere("salaryProfile.isRetired = :isRetired", { isRetired: true})
|
||||
.select([
|
||||
"salaryProfile.id",
|
||||
"salaryProfile.orgShortName",
|
||||
|
|
|
|||
|
|
@ -1698,7 +1698,7 @@ export class SalaryPeriodController extends Controller {
|
|||
...profile,
|
||||
posExecutive:
|
||||
profile.positionExecutiveField
|
||||
? `${profile.posExecutive} (${profile.positionExecutiveField})`
|
||||
? `${profile.posExecutive}(${profile.positionExecutiveField})`
|
||||
: profile.posExecutive ?? null,
|
||||
}));
|
||||
|
||||
|
|
@ -2565,6 +2565,7 @@ export class SalaryPeriodController extends Controller {
|
|||
let orgs = await new CallAPI().GetData(request, "/org/unauthorize/active/root/id");
|
||||
|
||||
//snap บางสำนัก
|
||||
//.chin
|
||||
// const targetRootIds = [
|
||||
// "d7e98989-b5ce-47d6-93c3-ab63ed486348",
|
||||
// "e0545eca-5d0a-4a1c-8bbd-e3e25c2521db",
|
||||
|
|
@ -2573,15 +2574,16 @@ export class SalaryPeriodController extends Controller {
|
|||
// "eaf65f33-25e9-4956-9dba-5d909f5eb595",
|
||||
// "a3efed2c-3f4b-476d-95e6-9f7e0585ae25",
|
||||
// ];
|
||||
const targetRootIds = [
|
||||
"b89a4467-7ee3-4706-8db7-f366555f826c",
|
||||
"585648a9-e634-43fc-9360-5fd4189136ab",
|
||||
"d6e3daa0-284a-428f-aa43-0750fa74e974",
|
||||
"ed3ddcfb-f882-4499-817b-aff73e5be87c",
|
||||
"f8ce98ca-a691-4c89-abde-875f559afb3a",
|
||||
];
|
||||
//.me
|
||||
// const targetRootIds = [
|
||||
// "b89a4467-7ee3-4706-8db7-f366555f826c",
|
||||
// "585648a9-e634-43fc-9360-5fd4189136ab",
|
||||
// "d6e3daa0-284a-428f-aa43-0750fa74e974",
|
||||
// "ed3ddcfb-f882-4499-817b-aff73e5be87c",
|
||||
// "f8ce98ca-a691-4c89-abde-875f559afb3a",
|
||||
// ];
|
||||
|
||||
orgs = orgs.filter((x: any) => targetRootIds.includes(x.rootId));
|
||||
// orgs = orgs.filter((x: any) => targetRootIds.includes(x.rootId));
|
||||
let total = 1000;
|
||||
// let _orgProfiles = await new CallAPI().PostData(request, "/org/unauthorize/salary/gen", {
|
||||
let _orgProfiles = await new CallAPI().PostData(request, "/org/unauthorize/new-salary/gen", {
|
||||
|
|
@ -2773,6 +2775,25 @@ export class SalaryPeriodController extends Controller {
|
|||
salaryOrgId: In(salaryOrgOld.map((x) => x.id)),
|
||||
},
|
||||
});
|
||||
// const salaryOrgOldList = await this.salaryOrgRepository.find({
|
||||
// where: {
|
||||
// salaryPeriodId: salaryPeriod.id,
|
||||
// snapshot: "SNAP1",
|
||||
// },
|
||||
// });
|
||||
|
||||
// const salaryProfileOldList = await this.salaryProfileRepository.find({
|
||||
// where: {
|
||||
// salaryOrgId: In(salaryOrgOldList.map((org) => org.id)),
|
||||
// },
|
||||
// });
|
||||
|
||||
// const salaryProfileMap = new Map<string, any>();
|
||||
// salaryProfileOldList.forEach((item) => {
|
||||
// salaryProfileMap.set(item.citizenId, item);
|
||||
// });
|
||||
|
||||
// const salaryOld = salaryProfileMap.get(salaryProfileNew.citizenId);
|
||||
|
||||
salaryProfileNew.type = salaryOld == null ? "PENDING" : salaryOld.type;
|
||||
salaryProfileNew.amount = salaryOld == null ? 0 : salaryOld.amount;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue