From 6f1100cb842a344fcacbec65e41594c623f7f188 Mon Sep 17 00:00:00 2001 From: liguoyang Date: Sat, 23 Mar 2024 19:13:55 +0800 Subject: [PATCH] fix job --- .../CommonJobs/MealSupplementHandlerJob.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Src/Dlhis.ScheduledTask/CommonJobs/MealSupplementHandlerJob.cs b/Src/Dlhis.ScheduledTask/CommonJobs/MealSupplementHandlerJob.cs index 682066d7..ccc6e9e1 100644 --- a/Src/Dlhis.ScheduledTask/CommonJobs/MealSupplementHandlerJob.cs +++ b/Src/Dlhis.ScheduledTask/CommonJobs/MealSupplementHandlerJob.cs @@ -114,13 +114,13 @@ public class MealSupplementHandlerJob } catch (Exception ex) { + await _dbContext.Client.Ado.RollbackTranAsync(); + await _dbContext.Updateable() .SetColumns(x => x.Status == MealSupplementStatusEnumtype.Error) .SetColumns(x => x.Result == ex.Message) .Where(x => x.UniqueId == mealSupplement.UniqueId) .ExecuteCommandAsync(); - - await _dbContext.Client.Ado.RollbackTranAsync(); } }