check การ reprocess ถ้า task นั้นไม่ได้ pedning แล้วให้ข้ามงานนั้นไป
All checks were successful
Build & Deploy Leave Service / build (push) Successful in 1m52s
All checks were successful
Build & Deploy Leave Service / build (push) Successful in 1m52s
This commit is contained in:
parent
bea7960ea7
commit
122f02ac97
1 changed files with 14 additions and 0 deletions
|
|
@ -30,6 +30,7 @@ using RabbitMQ.Client.Events;
|
||||||
using Swashbuckle.AspNetCore.Annotations;
|
using Swashbuckle.AspNetCore.Annotations;
|
||||||
using System.ComponentModel.DataAnnotations;
|
using System.ComponentModel.DataAnnotations;
|
||||||
using System.Diagnostics;
|
using System.Diagnostics;
|
||||||
|
using System.Reflection.Metadata.Ecma335;
|
||||||
using System.Security.Claims;
|
using System.Security.Claims;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
|
@ -779,6 +780,16 @@ namespace BMA.EHR.Leave.Service.Controllers
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
// var get current status
|
||||||
|
var task = await _checkInJobStatusRepository.GetByTaskIdAsync(job.TaskId);
|
||||||
|
|
||||||
|
// return if stask status != "PENDING"
|
||||||
|
if (task is not null)
|
||||||
|
{
|
||||||
|
if (task.Status != "PENDING")
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
// อ่านข้อมูลเดิมจาก AdditionalData
|
// อ่านข้อมูลเดิมจาก AdditionalData
|
||||||
if (string.IsNullOrEmpty(job.AdditionalData))
|
if (string.IsNullOrEmpty(job.AdditionalData))
|
||||||
{
|
{
|
||||||
|
|
@ -1075,6 +1086,9 @@ namespace BMA.EHR.Leave.Service.Controllers
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// อัปเดตสถานะเป็น PROCESSING
|
// อัปเดตสถานะเป็น PROCESSING
|
||||||
if (taskId != Guid.Empty)
|
if (taskId != Guid.Empty)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue