api บันทึกข้อมูลลูกจ้าง

This commit is contained in:
DESKTOP-2S5P7D1\Windows 10 2023-08-31 11:52:04 +07:00
parent fd682007f8
commit 83c79e4c0a
11 changed files with 155 additions and 63 deletions

View file

@ -514,7 +514,8 @@ namespace BMA.EHR.Retirement.Service.Controllers
.FirstOrDefaultAsync(x => x.Id == id);
if (updated == null)
return Error(GlobalMessages.RetirementResignNotFound, 404);
if ((DateTime.Now - updated.CreatedAt).TotalDays > 90)
return Error("สามารถยับยั้งได้ไม่เกิน 90 วัน");
// updated.Status = "REJECT";
updated.CommanderReject = true;
updated.CommanderRejectReason = req.Reason;
@ -570,7 +571,8 @@ namespace BMA.EHR.Retirement.Service.Controllers
.FirstOrDefaultAsync(x => x.Id == id);
if (updated == null)
return Error(GlobalMessages.RetirementResignNotFound, 404);
if ((DateTime.Now - updated.CreatedAt).TotalDays > 90)
return Error("สามารถยับยั้งได้ไม่เกิน 90 วัน");
updated.Status = "REJECT";
updated.OligarchReject = true;
updated.OligarchRejectReason = req.Reason;