增加异常处理

This commit is contained in:
FanLian
2023-08-15 17:04:01 +08:00
parent 1dcf6a1e58
commit 67c93bff19
3 changed files with 49 additions and 13 deletions

View File

@@ -261,9 +261,15 @@ namespace Tnb.WarehouseMgr
{
JNPF.Logging.Log.Error("齐套分拣执行时出现错误", ex);
await curDb.Ado.RollbackTranAsync();
TimedTaskErrorInfo ei = new()
{
RequestURL = App.HttpContext?.Request?.Path,
RequestMethod = App.HttpContext?.Request?.Method,
userIdentity = curUser,
};
var timedTaskEx = ex.ToTimedTaskException(ei);
cts?.Cancel();
throw;
throw timedTaskEx;
}
}