#2427 and migration
This commit is contained in:
parent
7f3408e2f5
commit
28b5408d5b
6 changed files with 159 additions and 5 deletions
|
|
@ -3,6 +3,7 @@ import { AppDataSource } from "../database/data-source";
|
|||
import { Command } from "../entities/Command";
|
||||
import { chunkArray, commandTypePath } from "../interfaces/utils";
|
||||
import CallAPI from "../interfaces/call-api";
|
||||
import { getPosMasterNo, getOrgFullName } from "../utils/org-formatting";
|
||||
import HttpError from "../interfaces/http-error";
|
||||
import HttpStatusCode from "../interfaces/http-status";
|
||||
import { PosMaster } from "../entities/PosMaster";
|
||||
|
|
@ -668,6 +669,12 @@ async function handler_org(msg: amqp.ConsumeMessage): Promise<boolean> {
|
|||
profile.posLevelId = position?.posLevelId ?? _null;
|
||||
profile.posTypeId = position?.posTypeId ?? _null;
|
||||
profile.position = position?.positionName ?? _null;
|
||||
profile.positionField = position?.positionField ?? _null;
|
||||
profile.posExecutive = position?.posExecutive?.posExecutiveName ?? _null;
|
||||
profile.positionArea = position?.positionArea ?? _null;
|
||||
profile.positionExecutiveField = position?.positionExecutiveField ?? _null;
|
||||
profile.posMasterNo = getPosMasterNo(item) ?? _null;
|
||||
profile.org = getOrgFullName(item) ?? _null;
|
||||
await repoProfile.save(profile);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue