From d65b25187c921add3cb11ef3c0896124e77de813 Mon Sep 17 00:00:00 2001 From: Bright Date: Tue, 13 May 2025 10:56:54 +0700 Subject: [PATCH] =?UTF-8?q?=E0=B8=AD=E0=B8=AD=E0=B8=81=E0=B8=88=E0=B8=B2?= =?UTF-8?q?=E0=B8=81=E0=B8=A3=E0=B8=B2=E0=B8=8A=E0=B8=81=E0=B8=B2=E0=B8=A3?= =?UTF-8?q?=20=E0=B9=84=E0=B8=A1=E0=B9=88=E0=B8=95=E0=B9=89=E0=B8=AD?= =?UTF-8?q?=E0=B8=87=E0=B8=A5=E0=B8=9A=E0=B8=95=E0=B8=B3=E0=B9=81=E0=B8=AB?= =?UTF-8?q?=E0=B8=99=E0=B9=88=E0=B8=87=E0=B9=83=E0=B8=99=E0=B8=97=E0=B8=B0?= =?UTF-8?q?=E0=B9=80=E0=B8=9A=E0=B8=B5=E0=B8=A2=E0=B8=99=20issue=20#1516?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/controllers/CommandController.ts | 49 ++++++++++++++++------------ 1 file changed, 28 insertions(+), 21 deletions(-) diff --git a/src/controllers/CommandController.ts b/src/controllers/CommandController.ts index 6bb55426..9af96752 100644 --- a/src/controllers/CommandController.ts +++ b/src/controllers/CommandController.ts @@ -3435,9 +3435,10 @@ export class CommandController extends Controller { profile.leaveRemark = clearProfile.leaveRemark ?? _null; profile.leaveDate = item.commandDateAffect ?? _null; profile.leaveType = clearProfile.LeaveType ?? _null; - profile.position = _null; - profile.posTypeId = _null; - profile.posLevelId = _null; + //ออกจากราชการ ไม่ต้องลบตำแหน่งในทะเบียน (issue #1516) + // profile.position = _null; + // profile.posTypeId = _null; + // profile.posLevelId = _null; } if (item.isGovernment == true) { const returnWork = await checkReturnCommandType(String(item.commandId)); @@ -3657,9 +3658,10 @@ export class CommandController extends Controller { profile.leaveRemark = clearProfile.leaveRemark ?? _null; profile.leaveDate = item.commandDateAffect ?? _null; profile.leaveType = clearProfile.LeaveType ?? _null; - profile.position = _null; - profile.posTypeId = _null; - profile.posLevelId = _null; + //ออกจากราชการ ไม่ต้องลบตำแหน่งในทะเบียน (issue #1516) + // profile.position = _null; + // profile.posTypeId = _null; + // profile.posLevelId = _null; } await this.profileEmployeeRepository.save(profile); }), @@ -3798,9 +3800,10 @@ export class CommandController extends Controller { profile.leaveRemark = clearProfile.leaveRemark ?? _null; profile.leaveDate = item.commandDateAffect ?? _null; profile.leaveType = clearProfile.LeaveType ?? _null; - profile.position = _null; - profile.posTypeId = _null; - profile.posLevelId = _null; + //ออกจากราชการ ไม่ต้องลบตำแหน่งในทะเบียน (issue #1516) + // profile.position = _null; + // profile.posTypeId = _null; + // profile.posLevelId = _null; profile.leaveReason = item.leaveReason ?? _null; profile.dateLeave = item.dateLeave ?? _null; profile.amount = item.amount ?? _null; @@ -4251,9 +4254,10 @@ export class CommandController extends Controller { _profile.leaveRemark = clearProfile.leaveRemark ?? _null; _profile.leaveDate = item.commandDateAffect ?? _null; _profile.leaveType = clearProfile.LeaveType ?? _null; - _profile.position = _null; - _profile.posTypeId = _null; - _profile.posLevelId = _null; + //ออกจากราชการ ไม่ต้องลบตำแหน่งในทะเบียน (issue #1516) + // _profile.position = _null; + // _profile.posTypeId = _null; + // _profile.posLevelId = _null; } await this.profileRepository.save(_profile); } @@ -4449,9 +4453,10 @@ export class CommandController extends Controller { _profile.leaveRemark = clearProfile.leaveRemark ?? _null; _profile.leaveDate = item.commandDateAffect ?? _null; _profile.leaveType = clearProfile.LeaveType ?? _null; - _profile.position = _null; - _profile.posTypeId = _null; - _profile.posLevelId = _null; + //ออกจากราชการ ไม่ต้องลบตำแหน่งในทะเบียน (issue #1516) + // _profile.position = _null; + // _profile.posTypeId = _null; + // _profile.posLevelId = _null; } await this.profileEmployeeRepository.save(_profile); } @@ -4733,9 +4738,10 @@ export class CommandController extends Controller { _profile.leaveRemark = clearProfile.leaveRemark ?? _null; _profile.leaveDate = item.commandDateAffect ?? _null; _profile.leaveType = clearProfile.LeaveType ?? _null; - _profile.position = _null; - _profile.posTypeId = _null; - _profile.posLevelId = _null; + //ออกจากราชการ ไม่ต้องลบตำแหน่งในทะเบียน (issue #1516) + // _profile.position = _null; + // _profile.posTypeId = _null; + // _profile.posLevelId = _null; } await this.profileEmployeeRepository.save(_profile); } @@ -5162,9 +5168,10 @@ export class CommandController extends Controller { _profile.leaveRemark = clearProfile.leaveRemark ?? _null; _profile.leaveDate = item.commandDateAffect ?? _null; _profile.leaveType = clearProfile.LeaveType ?? _null; - _profile.position = _null; - _profile.posTypeId = _null; - _profile.posLevelId = _null; + //ออกจากราชการ ไม่ต้องลบตำแหน่งในทะเบียน (issue #1516) + // _profile.position = _null; + // _profile.posTypeId = _null; + // _profile.posLevelId = _null; } await Promise.all([ this.profileRepository.save(_profile),