|
@@ -4395,15 +4395,13 @@ public class OrderController : BaseController
|
|
|
if (_systemSettingCacheManager.Snapshot)
|
|
|
{
|
|
|
await _orderSnapshotRepository.Queryable()
|
|
|
- .Where(m => m.Id == order.Id)
|
|
|
- .Select(m => new { m.IndustryId, m.IndustryName, m.IndustryCase })
|
|
|
+ .LeftJoin<IndustryCase>((snapshot, industryCase) => snapshot.IndustryCase == industryCase.Id)
|
|
|
+ .Where((snapshot, industryCase) => snapshot.Id == order.Id)
|
|
|
+ .Select((snapshot, industryCase) => new { snapshot.IndustryId, snapshot.IndustryName, industryCase.Name, })
|
|
|
.FirstAsync(HttpContext.RequestAborted)
|
|
|
.Then(async snapshot =>
|
|
|
{
|
|
|
- if (snapshot.IndustryCase.IsNullOrEmpty())
|
|
|
- dto.IndustryName = snapshot.IndustryName;
|
|
|
- else
|
|
|
- dto.IndustryName = snapshot.IndustryName + " " + snapshot.IndustryCase;
|
|
|
+ dto.IndustryName = snapshot.IndustryName + " " + snapshot.Name;
|
|
|
dto.IndustryId = snapshot.IndustryId;
|
|
|
});
|
|
|
}
|
|
@@ -4762,6 +4760,14 @@ public class OrderController : BaseController
|
|
|
if (dto.IsEdit != true && order.Status > EOrderStatus.HandOverToUnAccept)
|
|
|
throw UserFriendlyException.SameMessage("工单已发起流程,不可编辑");
|
|
|
}
|
|
|
+ if (_systemSettingCacheManager.Snapshot)
|
|
|
+ {
|
|
|
+ await _orderSnapshotRepository.Updateable()
|
|
|
+ .SetColumns(m => m.IndustryId, dto.IndustryId)
|
|
|
+ .SetColumns(m => m.IndustryName, dto.IndustryName)
|
|
|
+ .Where(m => m.Id == dto.Id)
|
|
|
+ .ExecuteCommandAsync();
|
|
|
+ }
|
|
|
|
|
|
// 副本工单
|
|
|
var copy = new OrderCopy();
|
|
@@ -5275,7 +5281,7 @@ public class OrderController : BaseController
|
|
|
orderHandleFlowDto.CrossSteps = orderHandleFlowDto.CrossSteps.OrderBy(d => d.Sort).ToList();
|
|
|
var stepCount = orderHandleFlowDto.CrossSteps.Count;
|
|
|
var unhandleSteps = new List<WorkflowStep> { startStep };
|
|
|
- for (int i = 0; i < stepCount; i++)
|
|
|
+ for (int i = 0;i < stepCount;i++)
|
|
|
{
|
|
|
var crossStep = orderHandleFlowDto.CrossSteps[i];
|
|
|
var tempSteps = new List<WorkflowStep>();
|