Bläddra i källkod

Merge branch 'test' of http://110.188.24.182:10023/Fengwo/hotline into test

qinchaoyue 4 månader sedan
förälder
incheckning
364ffba04a
1 ändrade filer med 4 tillägg och 3 borttagningar
  1. 4 3
      src/Hotline.Application/Orders/OrderApplication.cs

+ 4 - 3
src/Hotline.Application/Orders/OrderApplication.cs

@@ -3766,7 +3766,8 @@ public class OrderApplication : IOrderApplication, IScopeDependency
                              (step.FlowAssignType == EFlowAssignType.Org && !string.IsNullOrEmpty(step.HandlerOrgId) && step.HandlerOrgId == _sessionContext.RequiredOrgId) ||
                              (step.FlowAssignType == EFlowAssignType.Role && !string.IsNullOrEmpty(step.RoleId) && _sessionContext.Roles.Contains(step.RoleId)) ||
                              (step.FlowAssignType == EFlowAssignType.OrgAndRole && !string.IsNullOrEmpty(step.RoleId) && _sessionContext.Roles.Contains(step.RoleId)
-                              && !string.IsNullOrEmpty(step.HandlerOrgId) && step.HandlerOrgId == _sessionContext.RequiredOrgId)))
+                              && !string.IsNullOrEmpty(step.HandlerOrgId) && step.HandlerOrgId == _sessionContext.RequiredOrgId))
+                            && step.Status < EWorkflowStepStatus.Handled)
                         .OrderByDescending(step => step.CreationTime)
                         .Take(1)
                         .ToList())
@@ -3778,8 +3779,8 @@ public class OrderApplication : IOrderApplication, IScopeDependency
                                          (step.FlowAssignType == EFlowAssignType.OrgAndRole && !string.IsNullOrEmpty(step.RoleId) && _sessionContext.Roles.Contains(step.RoleId)
                                           && !string.IsNullOrEmpty(step.HandlerOrgId) && step.HandlerOrgId == _sessionContext.RequiredOrgId))
                                         && step.Status < EWorkflowStepStatus.Handled)
-                                || (SqlFunc.IsNullOrEmpty(d.WorkflowId) && SqlFunc.IsNullOrEmpty(d.SignerId)
-                                    || (!SqlFunc.IsNullOrEmpty(d.SignerId) && d.SignerId == _sessionContext.UserId))
+                                || (SqlFunc.IsNullOrEmpty(d.WorkflowId) 
+                                    && (SqlFunc.IsNullOrEmpty(d.SignerId) || (!SqlFunc.IsNullOrEmpty(d.SignerId) && d.SignerId == _sessionContext.UserId)))
                     )
                     .Where(d => d.Status < EOrderStatus.Filed
                         && (d.Status <= EOrderStatus.HandOverToUnAccept