แก้ไขข้อความ Notofication
All checks were successful
Build & Deploy Leave Service / build (push) Successful in 1m55s
All checks were successful
Build & Deploy Leave Service / build (push) Successful in 1m55s
This commit is contained in:
parent
e5f6a44f5f
commit
76697c4f63
1 changed files with 11 additions and 11 deletions
|
|
@ -951,7 +951,7 @@ namespace BMA.EHR.Leave.Service.Controllers
|
|||
{
|
||||
await _checkInJobStatusRepository.UpdateToFailedAsync(taskId, "เกิดข้อผิดพลาดจากการเรียก API [GetProfileByCheckInAsync] : ไม่พบข้อมูลผู้ใช้");
|
||||
await _notificationService.SendNotificationAsync(data.Token, true,
|
||||
"เกิดข้อผิดพลาดจากการเรียก API [GetProfileByCheckInAsync] : ไม่พบข้อมูลผู้ใช้");
|
||||
$"ลงเวลาไม่สำเร็จ \r\nเนื่องจาก ไม่พบข้อมูลผู้ใช้ \r\nกรุณาลองใหม่อีกครั้ง");
|
||||
//var staffList = await _userProfileRepository.GetOCStaffAsync(profile)
|
||||
return Error(GlobalMessages.DataNotFound, StatusCodes.Status404NotFound);
|
||||
}
|
||||
|
|
@ -962,7 +962,7 @@ namespace BMA.EHR.Leave.Service.Controllers
|
|||
{
|
||||
//throw new Exception(GlobalMessages.NoFileToUpload);
|
||||
await _checkInJobStatusRepository.UpdateToFailedAsync(taskId, GlobalMessages.NoFileToUpload);
|
||||
await _notificationService.SendNotificationAsync(data.Token, true, $"ประมวลผลการลงเวลาวันที่ {currentDate.ToString("dd-MM-yyyy")} ไม่สำเร็จ \r\nเนื่องจาก {GlobalMessages.NoFileToUpload}");
|
||||
await _notificationService.SendNotificationAsync(data.Token, true, $"ลงเวลาไม่สำเร็จ \r\nเนื่องจาก {GlobalMessages.NoFileToUpload}\r\nกรุณาลองใหม่อีกครั้ง");
|
||||
|
||||
// send notification to user
|
||||
var noti1 = new Notification
|
||||
|
|
@ -1000,7 +1000,7 @@ namespace BMA.EHR.Leave.Service.Controllers
|
|||
catch (Exception ex)
|
||||
{
|
||||
await _checkInJobStatusRepository.UpdateToFailedAsync(taskId, $"ไม่สามารถอัปโหลดรูปภาพได้: {ex.Message}");
|
||||
await _notificationService.SendNotificationAsync(data.Token, true, $"ประมวลผลการลงเวลาวันที่ {currentDate.ToString("dd-MM-yyyy")} ไม่สำเร็จ \r\nเนื่องจากไม่สามารถอัปโหลดรูปภาพได้ {ex.Message}");
|
||||
await _notificationService.SendNotificationAsync(data.Token, true, $"ลงเวลาไม่สำเร็จ \r\nเนื่องจากไม่สามารถอัปโหลดรูปภาพได้ {ex.Message}\r\nกรุณาลองใหม่อีกครั้ง");
|
||||
|
||||
// send notification to user
|
||||
var noti1 = new Notification
|
||||
|
|
@ -1035,7 +1035,7 @@ namespace BMA.EHR.Leave.Service.Controllers
|
|||
catch (Exception ex)
|
||||
{
|
||||
await _checkInJobStatusRepository.UpdateToFailedAsync(taskId, $"ไม่สามารถอัปโหลดรูปภาพได้: {ex.Message}");
|
||||
await _notificationService.SendNotificationAsync(data.Token, true, $"ประมวลผลการลงเวลาวันที่ {currentDate.ToString("dd-MM-yyyy")} ไม่สำเร็จ \r\nเนื่องจากไม่สามารถอัปโหลดรูปภาพได้ {ex.Message}");
|
||||
await _notificationService.SendNotificationAsync(data.Token, true, $"ลงเวลาไม่สำเร็จ \r\nเนื่องจากไม่สามารถอัปโหลดรูปภาพได้ {ex.Message}\r\nกรุณาลองใหม่อีกครั้ง");
|
||||
|
||||
// send notification to user
|
||||
var noti1 = new Notification
|
||||
|
|
@ -1061,7 +1061,7 @@ namespace BMA.EHR.Leave.Service.Controllers
|
|||
{
|
||||
await _checkInJobStatusRepository.UpdateToFailedAsync(taskId, "ไม่พบรอบการลงเวลาทำงาน Default");
|
||||
await _notificationService.SendNotificationAsync(data.Token, true,
|
||||
$"ประมวลผลการลงเวลาวันที่ {currentDate.ToString("dd-MM-yyyy")} ไม่สำเร็จ \r\nเนื่องจากไม่พบรอบการลงเวลาทำงาน Default");
|
||||
$"ลงเวลาไม่สำเร็จ \r\nเนื่องจากไม่พบรอบการลงเวลาทำงาน Default\r\nกรุณาลองใหม่อีกครั้ง");
|
||||
// send notification to user
|
||||
var noti1 = new Notification
|
||||
{
|
||||
|
|
@ -1215,12 +1215,12 @@ namespace BMA.EHR.Leave.Service.Controllers
|
|||
if (currentCheckIn != null)
|
||||
{
|
||||
await _checkInJobStatusRepository.UpdateToFailedAsync(taskId, "ไม่สามารถลงเวลาได้ เนื่องจากมีการลงเวลาในวันนี้แล้ว");
|
||||
await _notificationService.SendNotificationAsync(data.Token, true,$"ประมวลผลการลงเวลาวันที่ {currentDate.ToString("dd-MM-yyyy")} ไม่สำเร็จ \r\nเนื่องจากมีการลงเวลาในวันนี้แล้ว");
|
||||
await _notificationService.SendNotificationAsync(data.Token, true,$"ลงเวลาไม่สำเร็จ \r\nเนื่องจากมีการลงเวลาในวันนี้แล้ว\r\nกรุณาลองใหม่อีกครั้ง");
|
||||
|
||||
// send notification to user
|
||||
var noti1 = new Notification
|
||||
{
|
||||
Body = $"ประมวลผลการลงเวลาวันที่ {currentDate.ToString("dd-MM-yyyy")} ไม่สำเร็จ \r\nเนื่องจากมีการลงเวลาในวันนี้แล้ว",
|
||||
Body = $"ลงเวลาไม่สำเร็จ \r\nเนื่องจากมีการลงเวลาในวันนี้แล้ว",
|
||||
ReceiverUserId = profile.Id,
|
||||
Type = "",
|
||||
Payload = "",
|
||||
|
|
@ -1373,7 +1373,7 @@ namespace BMA.EHR.Leave.Service.Controllers
|
|||
if (checkout == null)
|
||||
{
|
||||
await _checkInJobStatusRepository.UpdateToFailedAsync(taskId, "ไม่พบข้อมูลการลงเวลาทำงาน");
|
||||
await _notificationService.SendNotificationAsync(data.Token,true, $"ประมวลผลการลงเวลาวันที่ {currentDate.ToString("dd-MM-yyyy")} ไม่สำเร็จ \r\nเนื่องจากไม่พบข้อมูลการลงเวลาทำงาน");
|
||||
await _notificationService.SendNotificationAsync(data.Token,true, $"ลงเวลาไม่สำเร็จ \r\nเนื่องจากไม่พบข้อมูลการลงเวลาทำงาน\r\nกรุณาลองใหม่อีกครั้ง");
|
||||
|
||||
// send notification to user
|
||||
var noti1 = new Notification
|
||||
|
|
@ -1394,7 +1394,7 @@ namespace BMA.EHR.Leave.Service.Controllers
|
|||
if (currentCheckInProcess == null)
|
||||
{
|
||||
await _checkInJobStatusRepository.UpdateToFailedAsync(taskId, "ไม่พบข้อมูลการประมวลผลเวลาทำงาน (CheckIn)");
|
||||
await _notificationService.SendNotificationAsync(data.Token, true, $"ประมวลผลการลงเวลาวันที่ {currentDate.ToString("dd-MM-yyyy")} ไม่สำเร็จ \r\nเนื่องจากไม่พบข้อมูลการประมวลผลเวลาทำงาน (CheckIn)");
|
||||
await _notificationService.SendNotificationAsync(data.Token, true, $"ลงเวลาไม่สำเร็จ \r\nเนื่องจากไม่พบข้อมูลการประมวลผลเวลาทำงาน (CheckIn)\r\nกรุณาลองใหม่อีกครั้ง");
|
||||
|
||||
// send notification to user
|
||||
var noti1 = new Notification
|
||||
|
|
@ -1572,7 +1572,7 @@ namespace BMA.EHR.Leave.Service.Controllers
|
|||
else
|
||||
{
|
||||
await _checkInJobStatusRepository.UpdateToFailedAsync(taskId, "ไม่พบข้อมูลการประมวลผลเวลาทำงาน");
|
||||
await _notificationService.SendNotificationAsync(data.Token,true, $"ประมวลผลการลงเวลาวันที่ {currentDate.ToString("dd-MM-yyyy")} ไม่สำเร็จ \r\nเนื่องจากไม่พบข้อมูลการประมวลผลเวลาทำงาน");
|
||||
await _notificationService.SendNotificationAsync(data.Token,true, $"ลงเวลาไม่สำเร็จ \r\nเนื่องจากไม่พบข้อมูลการประมวลผลเวลาทำงาน\r\nกรุณาลองใหม่อีกครั้ง");
|
||||
// send notification to user
|
||||
var noti1 = new Notification
|
||||
{
|
||||
|
|
@ -1597,7 +1597,7 @@ namespace BMA.EHR.Leave.Service.Controllers
|
|||
});
|
||||
await _checkInJobStatusRepository.UpdateToCompletedAsync(taskId, additionalData);
|
||||
await _notificationService.SendNotificationAsync(data.Token, false,
|
||||
$"ประมวลผลการลงเวลาวันที่ {currentDate.ToString("dd-MM-yyyy")} สำเร็จ");
|
||||
$"ลงเวลาสำเร็จ");
|
||||
}
|
||||
|
||||
var checkInType = data.CheckInId == null ? "check-in" : "check-out";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue