Merge pull request #1744 from Frappet/task/1728-ออกคำสั่งลาออก
1728-ยกเลิกคำสั่ง
This commit is contained in:
commit
b89f394f1e
2 changed files with 5 additions and 17 deletions
|
|
@ -1741,7 +1741,7 @@ namespace BMA.EHR.Retirement.Service.Controllers
|
||||||
client.DefaultRequestHeaders.Add("api_key", _configuration["API_KEY"]);
|
client.DefaultRequestHeaders.Add("api_key", _configuration["API_KEY"]);
|
||||||
var _res = await client.DeleteAsync($"{_configuration["API"]}/org/command/tab2Cancel17/{updated.Id}");
|
var _res = await client.DeleteAsync($"{_configuration["API"]}/org/command/tab2Cancel17/{updated.Id}");
|
||||||
}
|
}
|
||||||
updated.Status = "CANCELING";
|
updated.Status = "CANCEL";
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
@ -3605,8 +3605,8 @@ namespace BMA.EHR.Retirement.Service.Controllers
|
||||||
updated.ReasonResign = !string.IsNullOrEmpty(ReasonResign) ? ReasonResign : updated.ReasonResign;
|
updated.ReasonResign = !string.IsNullOrEmpty(ReasonResign) ? ReasonResign : updated.ReasonResign;
|
||||||
updated.Reason = req.ReasonResign;
|
updated.Reason = req.ReasonResign;
|
||||||
updated.Remark = !string.IsNullOrEmpty(req.Remark) ? req.Remark : null;
|
updated.Remark = !string.IsNullOrEmpty(req.Remark) ? req.Remark : null;
|
||||||
updated.SendDate = req.SendDate.HasValue ? req.SendDate : updated.SendDate;
|
updated.SendDate = req.SendDate.HasValue ? req.SendDate : updated.SendDate;
|
||||||
updated.ActiveDate = req.ActiveDate.HasValue ? req.ActiveDate : updated.ActiveDate;
|
updated.ActiveDate = req.ActiveDate.HasValue ? req.ActiveDate : updated.ActiveDate;
|
||||||
updated.LastUpdateFullName = FullName ?? "System Administrator";
|
updated.LastUpdateFullName = FullName ?? "System Administrator";
|
||||||
updated.LastUpdateUserId = UserId ?? "";
|
updated.LastUpdateUserId = UserId ?? "";
|
||||||
updated.LastUpdatedAt = DateTime.Now;
|
updated.LastUpdatedAt = DateTime.Now;
|
||||||
|
|
|
||||||
|
|
@ -1648,18 +1648,6 @@ namespace BMA.EHR.Retirement.Service.Controllers
|
||||||
}
|
}
|
||||||
await _context.AddRangeAsync(addList);
|
await _context.AddRangeAsync(addList);
|
||||||
await _context.SaveChangesAsync();
|
await _context.SaveChangesAsync();
|
||||||
// using (var client = new HttpClient())
|
|
||||||
// {
|
|
||||||
// client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", token.Replace("Bearer ", ""));
|
|
||||||
// client.DefaultRequestHeaders.Add("api_key", _configuration["API_KEY"]);
|
|
||||||
// var _res = await client.PostAsJsonAsync($"{_configuration["API"]}/org/workflow/add-workflow", new
|
|
||||||
// {
|
|
||||||
// refId = retirementResignEmployeeCancel.Id,
|
|
||||||
// sysName = "RETIREMENT_CANCEL_EMP",
|
|
||||||
// posLevelName = retirementResignEmployeeCancel.PositionLevelOld,
|
|
||||||
// posTypeName = retirementResignEmployeeCancel.PositionTypeOld,
|
|
||||||
// });
|
|
||||||
// }
|
|
||||||
updated.IsCancel = true;
|
updated.IsCancel = true;
|
||||||
updated.Status = "CANCELING";
|
updated.Status = "CANCELING";
|
||||||
}
|
}
|
||||||
|
|
@ -1671,7 +1659,7 @@ namespace BMA.EHR.Retirement.Service.Controllers
|
||||||
client.DefaultRequestHeaders.Add("api_key", _configuration["API_KEY"]);
|
client.DefaultRequestHeaders.Add("api_key", _configuration["API_KEY"]);
|
||||||
var _res = await client.DeleteAsync($"{_configuration["API"]}/org/command/tab2Cancel23/{updated.Id}");
|
var _res = await client.DeleteAsync($"{_configuration["API"]}/org/command/tab2Cancel23/{updated.Id}");
|
||||||
}
|
}
|
||||||
updated.Status = "CANCELING";
|
updated.Status = "CANCEL";
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue