From eedbeed27da8179a9cad88bd85ffa03d0bff5e54 Mon Sep 17 00:00:00 2001 From: Kittapath Date: Tue, 19 Mar 2024 11:30:44 +0700 Subject: [PATCH] no message --- src/controllers/ProfileEmployeeController.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/controllers/ProfileEmployeeController.ts b/src/controllers/ProfileEmployeeController.ts index ddc3f9a3..7c420ad9 100644 --- a/src/controllers/ProfileEmployeeController.ts +++ b/src/controllers/ProfileEmployeeController.ts @@ -926,7 +926,6 @@ export class ProfileEmployeeController extends Controller { .leftJoinAndSelect("employeePosMaster.orgChild3", "orgChild3") .leftJoinAndSelect("employeePosMaster.orgChild4", "orgChild4") .leftJoinAndSelect("employeePosMaster.positions", "positions") - .leftJoinAndSelect("positions.posExecutive", "posExecutive") .leftJoinAndSelect("current_holder.profileSalary", "profileSalary") .leftJoinAndSelect("current_holder.profileDiscipline", "profileDiscipline") .leftJoinAndSelect("current_holder.posLevel", "posLevel") @@ -1059,8 +1058,10 @@ export class ProfileEmployeeController extends Controller { posMasterNoSuffix: item.posMasterNoSuffix, orgShortName: orgShortName, position: item.current_holder.position, - posType: item.current_holder.posType.posTypeName, - posLevel: item.current_holder.posLevel.posLevelName, + posType: + item.current_holder.posType == null ? null : item.current_holder.posType.posTypeName, + posLevel: + item.current_holder.posLevel == null ? null : item.current_holder.posLevel.posLevelName, amount: amount ? amount : null, rootId: item.orgRootId, root: item.orgRoot?.orgRootName ? item.orgRoot.orgRootName : null,