Merge branch 'develop'
All checks were successful
Build & Deploy Leave Service / build (push) Successful in 1m3s
All checks were successful
Build & Deploy Leave Service / build (push) Successful in 1m3s
This commit is contained in:
commit
199d0c90e3
1 changed files with 10 additions and 2 deletions
|
|
@ -1318,9 +1318,17 @@ namespace BMA.EHR.Application.Repositories.Leaves.LeaveRequests
|
|||
throw new Exception(GlobalMessages.DataNotFound);
|
||||
}
|
||||
|
||||
if (rawData.ApproveStep != "st3")
|
||||
// ถ้าไม่มี commander ข้ามไปเช็ค approver ได้เลย
|
||||
var commanders = rawData.Approvers
|
||||
.Where(x => x.ApproveType!.ToUpper() == "COMMANDER")
|
||||
.OrderBy(x => x.Seq)
|
||||
.ToList();
|
||||
if (commanders.Count > 0 && commanders != null)
|
||||
{
|
||||
throw new Exception("คำขอนี้ยังไม่ได้อยู่ในขั้นตอนที่สามารถอนุมัติได้ ไม่สามารถทำรายการได้");
|
||||
if (rawData.ApproveStep != "st3")
|
||||
{
|
||||
throw new Exception("คำขอนี้ยังไม่ได้อยู่ในขั้นตอนที่สามารถอนุมัติได้ ไม่สามารถทำรายการได้");
|
||||
}
|
||||
}
|
||||
|
||||
// check commander approve
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue