Dun.Jason 1 year ago
parent
commit
6504e4fb3e
1 changed files with 10 additions and 3 deletions
  1. 10 3
      src/Hotline.Application/Handlers/FlowEngine/WorkflowEndHandler.cs

+ 10 - 3
src/Hotline.Application/Handlers/FlowEngine/WorkflowEndHandler.cs

@@ -162,13 +162,20 @@ public class WorkflowEndHandler : INotificationHandler<EndWorkflowNotify>
                 order.FileUserOrgId = notification.Trace.HandlerOrgId;
                 order.FileUserOrgName = notification.Trace.HandlerOrgName;
 
+                //记录冗余归档数据
+                if(notification.Workflow.Steps.Any(x => x.BusinessType == Share.Enums.FlowEngine.EBusinessType.Send))
+                {
+                    order.FileUserRole = EFileUserType.Dispatch;
+                }
+                else
+                {
+                    order.FileUserRole = EFileUserType.Seat;
+                }
                 if (order.ProcessType == EProcessType.Jiaoban)
                 {
                     order.FileUserRole = EFileUserType.Org;
                 }
-                //TODO
-
-               
+                               
                 await _orderRepository.UpdateAsync(order, cancellationToken);
                 var callRecord = await _trCallRecordRepository.GetAsync(p => p.CallAccept == order.CallId, cancellationToken);
                 var orderFlowDto = new OrderFlowDto