Bläddra i källkod

补全流转方向枚举判断

xf 6 månader sedan
förälder
incheckning
b7b344515f
1 ändrade filer med 9 tillägg och 1 borttagningar
  1. 9 1
      src/Hotline/FlowEngine/Workflows/WorkflowDomainService.cs

+ 9 - 1
src/Hotline/FlowEngine/Workflows/WorkflowDomainService.cs

@@ -958,7 +958,6 @@ namespace Hotline.FlowEngine.Workflows
                             directionStepBusinessType, null)
                     };
                 case EBusinessType.Department:
-                case EBusinessType.File:
                     return directionStepBusinessType switch
                     {
                         EBusinessType.Seat => EFlowDirection.OrgToCenter,
@@ -968,6 +967,15 @@ namespace Hotline.FlowEngine.Workflows
                         _ => throw new ArgumentOutOfRangeException(nameof(directionStepBusinessType),
                             directionStepBusinessType, null)
                     };
+                case EBusinessType.File:
+                    return directionStepBusinessType switch
+                    {
+                        EBusinessType.Seat => EFlowDirection.FiledToCenter,
+                        EBusinessType.Send => EFlowDirection.FiledToCenter,
+                        EBusinessType.Department => EFlowDirection.FiledToOrg,
+                        EBusinessType.DepartmentLeader => EFlowDirection.FiledToOrg,
+                        _ => throw new ArgumentOutOfRangeException(nameof(directionStepBusinessType), directionStepBusinessType, null)
+                    };
                 default:
                     throw new ArgumentOutOfRangeException(nameof(sourceStepBusinessType), sourceStepBusinessType, null);
             }