diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareJNAction.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareJNAction.java index 14b44cd..ffa8ae0 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareJNAction.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareJNAction.java @@ -266,4 +266,10 @@ public class ProjectDeclareJNAction { Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); } + + @OnTransition(source = "FINAL_ACCEPTANCE_REVIEW_FAILED", target = "FINAL_ACCEPTANCE_IS_UNDER_REVIEW") + public void FINAL_RE_ACCEPTANCE_APPLICATION(Message message) { + Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); + project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); + } } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareJYAction.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareJYAction.java index c441678..eb1ab5d 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareJYAction.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareJYAction.java @@ -265,4 +265,10 @@ public class ProjectDeclareJYAction { Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); } + + @OnTransition(source = "FINAL_ACCEPTANCE_REVIEW_FAILED", target = "FINAL_ACCEPTANCE_IS_UNDER_REVIEW") + public void FINAL_RE_ACCEPTANCE_APPLICATION(Message message) { + Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); + project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); + } } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareKFBAction.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareKFBAction.java index 71d2660..bff3743 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareKFBAction.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareKFBAction.java @@ -265,4 +265,10 @@ public class ProjectDeclareKFBAction { Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); } + + @OnTransition(source = "FINAL_ACCEPTANCE_REVIEW_FAILED", target = "FINAL_ACCEPTANCE_IS_UNDER_REVIEW") + public void FINAL_RE_ACCEPTANCE_APPLICATION(Message message) { + Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); + project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); + } } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareLDAction.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareLDAction.java index 66cf8e9..8fbcf3a 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareLDAction.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareLDAction.java @@ -265,4 +265,10 @@ public class ProjectDeclareLDAction { Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); } + + @OnTransition(source = "FINAL_ACCEPTANCE_REVIEW_FAILED", target = "FINAL_ACCEPTANCE_IS_UNDER_REVIEW") + public void FINAL_RE_ACCEPTANCE_APPLICATION(Message message) { + Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); + project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); + } } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareLQAction.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareLQAction.java index 30d61c1..f87fa91 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareLQAction.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareLQAction.java @@ -265,4 +265,10 @@ public class ProjectDeclareLQAction { Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); } + + @OnTransition(source = "FINAL_ACCEPTANCE_REVIEW_FAILED", target = "FINAL_ACCEPTANCE_IS_UNDER_REVIEW") + public void FINAL_RE_ACCEPTANCE_APPLICATION(Message message) { + Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); + project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); + } } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareQTAction.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareQTAction.java index b1f734a..9c4a19a 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareQTAction.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareQTAction.java @@ -265,4 +265,10 @@ public class ProjectDeclareQTAction { Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); } + + @OnTransition(source = "FINAL_ACCEPTANCE_REVIEW_FAILED", target = "FINAL_ACCEPTANCE_IS_UNDER_REVIEW") + public void FINAL_RE_ACCEPTANCE_APPLICATION(Message message) { + Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); + project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); + } } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareQYAction.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareQYAction.java index a21d88a..4117798 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareQYAction.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareQYAction.java @@ -265,4 +265,10 @@ public class ProjectDeclareQYAction { Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); } + + @OnTransition(source = "FINAL_ACCEPTANCE_REVIEW_FAILED", target = "FINAL_ACCEPTANCE_IS_UNDER_REVIEW") + public void FINAL_RE_ACCEPTANCE_APPLICATION(Message message) { + Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); + project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); + } } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareSBJAction.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareSBJAction.java index df52734..466fb16 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareSBJAction.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareSBJAction.java @@ -260,9 +260,15 @@ public class ProjectDeclareSBJAction { project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_REVIEW_FAILED.getCode()); } - @OnTransition(source = "FINAL_ACCEPTANCE_IS_UNDER_REVIEW", target = "FINAL_ACCEPTANCE_IS_UNDER_REVIEW") + @OnTransition(source = "FINAL_ACCEPTANCE_IS_UNDER_REVIEW", target = "TO_BE_FINALLY_INSPECTED") public void FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW(Message message) { Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); + project.setStatus(ProjectStatusEnum.TO_BE_FINALLY_INSPECTED.getCode()); + } + + @OnTransition(source = "FINAL_ACCEPTANCE_REVIEW_FAILED", target = "FINAL_ACCEPTANCE_IS_UNDER_REVIEW") + public void FINAL_RE_ACCEPTANCE_APPLICATION(Message message) { + Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); } } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareSCAction.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareSCAction.java index 95644cc..d1351c6 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareSCAction.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareSCAction.java @@ -273,4 +273,10 @@ public class ProjectDeclareSCAction { Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); } + + @OnTransition(source = "FINAL_ACCEPTANCE_REVIEW_FAILED", target = "FINAL_ACCEPTANCE_IS_UNDER_REVIEW") + public void FINAL_RE_ACCEPTANCE_APPLICATION(Message message) { + Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); + project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); + } } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareSYAction.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareSYAction.java index 8d3516b..0f54f1f 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareSYAction.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareSYAction.java @@ -265,4 +265,10 @@ public class ProjectDeclareSYAction { Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); } + + @OnTransition(source = "FINAL_ACCEPTANCE_REVIEW_FAILED", target = "FINAL_ACCEPTANCE_IS_UNDER_REVIEW") + public void FINAL_RE_ACCEPTANCE_APPLICATION(Message message) { + Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); + project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); + } } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareYHAction.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareYHAction.java index b97c2fa..4d78f52 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareYHAction.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/action/ProjectDeclareYHAction.java @@ -265,4 +265,10 @@ public class ProjectDeclareYHAction { Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); } + + @OnTransition(source = "FINAL_ACCEPTANCE_REVIEW_FAILED", target = "FINAL_ACCEPTANCE_IS_UNDER_REVIEW") + public void FINAL_RE_ACCEPTANCE_APPLICATION(Message message) { + Project project = (Project) message.getHeaders().get(PROJECT_DECLARE); + project.setStatus(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); + } } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineJNBuilder.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineJNBuilder.java index 850696c..0ef1da6 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineJNBuilder.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineJNBuilder.java @@ -240,7 +240,12 @@ public class ProjectDeclareStateMachineJNBuilder implements ProjectDeclareStateM .withExternal() .source(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) - .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and(); + .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and() + // 终验中 重新提交 + .withExternal() + .source(ProjectStatusEnum.FINAL_ACCEPTANCE_REVIEW_FAILED) + .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) + .event(ProjectStatusChangeEvent.FINAL_RE_ACCEPTANCE_APPLICATION).and(); return builder.build(); } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineJYBuilder.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineJYBuilder.java index 4046dca..342220b 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineJYBuilder.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineJYBuilder.java @@ -240,7 +240,12 @@ public class ProjectDeclareStateMachineJYBuilder implements ProjectDeclareStateM .withExternal() .source(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) - .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and(); + .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and() + // 终验中 重新提交 + .withExternal() + .source(ProjectStatusEnum.FINAL_ACCEPTANCE_REVIEW_FAILED) + .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) + .event(ProjectStatusChangeEvent.FINAL_RE_ACCEPTANCE_APPLICATION).and(); return builder.build(); } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineKFQBuilder.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineKFQBuilder.java index 0f77876..f25cacb 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineKFQBuilder.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineKFQBuilder.java @@ -240,7 +240,12 @@ public class ProjectDeclareStateMachineKFQBuilder implements ProjectDeclareState .withExternal() .source(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) - .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and(); + .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and() + // 终验中 重新提交 + .withExternal() + .source(ProjectStatusEnum.FINAL_ACCEPTANCE_REVIEW_FAILED) + .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) + .event(ProjectStatusChangeEvent.FINAL_RE_ACCEPTANCE_APPLICATION).and(); return builder.build(); } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineLDBuilder.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineLDBuilder.java index d45f269..1b5f4fa 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineLDBuilder.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineLDBuilder.java @@ -240,7 +240,12 @@ public class ProjectDeclareStateMachineLDBuilder implements ProjectDeclareStateM .withExternal() .source(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) - .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and(); + .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and() + // 终验中 重新提交 + .withExternal() + .source(ProjectStatusEnum.FINAL_ACCEPTANCE_REVIEW_FAILED) + .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) + .event(ProjectStatusChangeEvent.FINAL_RE_ACCEPTANCE_APPLICATION).and(); return builder.build(); } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineLQBuilder.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineLQBuilder.java index 807c427..e6dfb16 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineLQBuilder.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineLQBuilder.java @@ -241,7 +241,12 @@ public class ProjectDeclareStateMachineLQBuilder implements ProjectDeclareStateM .withExternal() .source(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) - .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and(); + .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and() + // 终验中 重新提交 + .withExternal() + .source(ProjectStatusEnum.FINAL_ACCEPTANCE_REVIEW_FAILED) + .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) + .event(ProjectStatusChangeEvent.FINAL_RE_ACCEPTANCE_APPLICATION).and(); return builder.build(); } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineQTBuilder.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineQTBuilder.java index b7daaac..2656ba4 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineQTBuilder.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineQTBuilder.java @@ -240,7 +240,12 @@ public class ProjectDeclareStateMachineQTBuilder implements ProjectDeclareStateM .withExternal() .source(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) - .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and(); + .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and() + // 终验中 重新提交 + .withExternal() + .source(ProjectStatusEnum.FINAL_ACCEPTANCE_REVIEW_FAILED) + .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) + .event(ProjectStatusChangeEvent.FINAL_RE_ACCEPTANCE_APPLICATION).and(); return builder.build(); } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineQYBuilder.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineQYBuilder.java index 4587843..e65d761 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineQYBuilder.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineQYBuilder.java @@ -240,7 +240,12 @@ public class ProjectDeclareStateMachineQYBuilder implements ProjectDeclareStateM .withExternal() .source(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) - .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and(); + .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and() + // 终验中 重新提交 + .withExternal() + .source(ProjectStatusEnum.FINAL_ACCEPTANCE_REVIEW_FAILED) + .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) + .event(ProjectStatusChangeEvent.FINAL_RE_ACCEPTANCE_APPLICATION).and(); return builder.build(); } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineSBJBuilder.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineSBJBuilder.java index d6daafc..40d38b4 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineSBJBuilder.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineSBJBuilder.java @@ -241,7 +241,12 @@ public class ProjectDeclareStateMachineSBJBuilder implements ProjectDeclareState .withExternal() .source(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) .target(ProjectStatusEnum.TO_BE_FINALLY_INSPECTED) - .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and(); + .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and() + // 终验中 重新提交 + .withExternal() + .source(ProjectStatusEnum.FINAL_ACCEPTANCE_REVIEW_FAILED) + .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) + .event(ProjectStatusChangeEvent.FINAL_RE_ACCEPTANCE_APPLICATION).and(); return builder.build(); } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineSCBuilder.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineSCBuilder.java index 027ca4a..f432e34 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineSCBuilder.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineSCBuilder.java @@ -250,7 +250,12 @@ public class ProjectDeclareStateMachineSCBuilder implements ProjectDeclareStateM .withExternal() .source(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) - .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and(); + .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and() + // 终验中 重新提交 + .withExternal() + .source(ProjectStatusEnum.FINAL_ACCEPTANCE_REVIEW_FAILED) + .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) + .event(ProjectStatusChangeEvent.FINAL_RE_ACCEPTANCE_APPLICATION).and(); return builder.build(); } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineSYBuilder.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineSYBuilder.java index a6e5d47..9a7b257 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineSYBuilder.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineSYBuilder.java @@ -240,7 +240,12 @@ public class ProjectDeclareStateMachineSYBuilder implements ProjectDeclareStateM .withExternal() .source(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) - .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and(); + .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and() + // 终验中 重新提交 + .withExternal() + .source(ProjectStatusEnum.FINAL_ACCEPTANCE_REVIEW_FAILED) + .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) + .event(ProjectStatusChangeEvent.FINAL_RE_ACCEPTANCE_APPLICATION).and(); return builder.build(); } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineYHBuilder.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineYHBuilder.java index 1a95ef7..cb7b103 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineYHBuilder.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/builder/ProjectDeclareStateMachineYHBuilder.java @@ -240,7 +240,12 @@ public class ProjectDeclareStateMachineYHBuilder implements ProjectDeclareStateM .withExternal() .source(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) - .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and(); + .event(ProjectStatusChangeEvent.FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW).and() + // 终验中 重新提交 + .withExternal() + .source(ProjectStatusEnum.FINAL_ACCEPTANCE_REVIEW_FAILED) + .target(ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW) + .event(ProjectStatusChangeEvent.FINAL_RE_ACCEPTANCE_APPLICATION).and(); return builder.build(); } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/event/ProjectStatusChangeEvent.java b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/event/ProjectStatusChangeEvent.java index 5f15fd7..8f2b79e 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/event/ProjectStatusChangeEvent.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/common/statemachine/event/ProjectStatusChangeEvent.java @@ -156,7 +156,13 @@ public enum ProjectStatusChangeEvent { /** * 终验审核中时被撤回(项目状态进入:待终验) */ - FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW(null, null, ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()); + FINAL_ACCEPTANCE_IS_UNDER_REVIEW_WITHDRAW(null, null, ProjectStatusEnum.FINAL_ACCEPTANCE_IS_UNDER_REVIEW.getCode()), + + /** + * 重新提交 终验 + */ + FINAL_RE_ACCEPTANCE_APPLICATION(ProjectStatusEnum.FINAL_ACCEPTANCE_REVIEW_FAILED.getCode(), null, null); + private Integer passProjectStatusCode; private Integer rejectProjectStatusCode; diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/ding/constants/DingOrganizationContant.java b/pmapi/src/main/java/com/ningdatech/pmapi/ding/constants/DingOrganizationContant.java index 496b75f..e8ffb0d 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/ding/constants/DingOrganizationContant.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/ding/constants/DingOrganizationContant.java @@ -9,6 +9,6 @@ package com.ningdatech.pmapi.ding.constants; public interface DingOrganizationContant { String UNIT_TYPE = "GOV_UNIT"; - + String GOV_TEMPORARY = "GOV_TEMPORARY"; String HOLLOW = "GOV_HOLLOW_DIVISION_NODE"; } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/ding/controller/DingInfoPullController.java b/pmapi/src/main/java/com/ningdatech/pmapi/ding/controller/DingInfoPullController.java index f07e985..2107e02 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/ding/controller/DingInfoPullController.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/ding/controller/DingInfoPullController.java @@ -1,36 +1,13 @@ package com.ningdatech.pmapi.ding.controller; -import cn.hutool.crypto.digest.MD5; -import com.alibaba.fastjson.JSON; -import com.ningdatech.pmapi.common.util.CryptUtils; -import com.ningdatech.pmapi.common.util.HttpUtil; -import com.ningdatech.pmapi.common.util.Md5Utils; -import com.ningdatech.pmapi.common.util.RefreshKeyUtil; import com.ningdatech.pmapi.ding.task.EmployeeBatchGetTask; import com.ningdatech.pmapi.ding.task.GovBusinessStripsTask; import com.ningdatech.pmapi.ding.task.OrganizationBatchGetTask; -import com.ningdatech.pmapi.irs.utils.RefreshTokenUtil; import com.ningdatech.pmapi.organization.manage.ProcDefManage; import io.swagger.annotations.ApiOperation; -import liquibase.util.MD5Util; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; -import org.apache.http.conn.ssl.NoopHostnameVerifier; -import org.apache.http.conn.ssl.SSLConnectionSocketFactory; -import org.apache.http.conn.ssl.TrustStrategy; -import org.apache.http.impl.client.CloseableHttpClient; -import org.apache.http.impl.client.HttpClientBuilder; -import org.apache.http.impl.client.HttpClients; -import org.apache.http.ssl.SSLContexts; -import org.springframework.http.ResponseEntity; -import org.springframework.http.client.HttpComponentsClientHttpRequestFactory; import org.springframework.web.bind.annotation.*; -import org.springframework.web.client.RestTemplate; - -import javax.net.ssl.SSLContext; -import java.io.UnsupportedEncodingException; -import java.net.URLEncoder; -import java.security.NoSuchAlgorithmException; /** *

@@ -103,4 +80,10 @@ public class DingInfoPullController { public String init() { return procDefManage.init(); } + + @ApiOperation(value = "系统流程配置初始化按区域", notes = "系统流程配置初始化按区域") + @GetMapping("/init/{areaCode}") + public String initByArea(@PathVariable String areaCode) { + return procDefManage.initByArea(areaCode); + } } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/expert/service/impl/ExpertInfoServiceImpl.java b/pmapi/src/main/java/com/ningdatech/pmapi/expert/service/impl/ExpertInfoServiceImpl.java index a45bc0a..2ec31c5 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/expert/service/impl/ExpertInfoServiceImpl.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/expert/service/impl/ExpertInfoServiceImpl.java @@ -29,6 +29,7 @@ import com.ningdatech.pmapi.meta.model.entity.ExpertDictionary; import com.ningdatech.pmapi.meta.model.entity.ExpertTag; import com.ningdatech.pmapi.meta.service.IExpertDictionaryService; import com.ningdatech.pmapi.meta.service.IExpertTagService; +import com.ningdatech.pmapi.user.util.LoginUserUtil; import com.ningdatech.yxt.utils.JSONUtils; import lombok.RequiredArgsConstructor; import org.apache.commons.collections4.CollectionUtils; @@ -264,6 +265,10 @@ public class ExpertInfoServiceImpl implements ExpertInfoService { expertRegionApply.setRegionLevel(expertUserFullInfo.getRegionLevel()); expertRegionApply.setUserId(userId); expertRegionApply.setDisplayEnable(BoolDisplayEnum.Y.name()); + if (LoginUserUtil.isLogin()) { + expertRegionApply.setCreateBy(LoginUserUtil.getUserId()); + } + expertRegionApply.setCreateOn(LocalDateTime.now()); iExpertMetaApplyService.save(expertRegionApply); return expertRegionApply.getId(); @@ -590,6 +595,8 @@ public class ExpertInfoServiceImpl implements ExpertInfoService { expertMetaApply.setRegionLevel(originalExpertUserFullInfo.getRegionLevel()); expertMetaApply.setUserId(originalExpertUserFullInfo.getUserId()); expertMetaApply.setDisplayEnable(BoolDisplayEnum.Y.name()); + expertMetaApply.setCreateOn(LocalDateTime.now()); + expertMetaApply.setCreateBy(LoginUserUtil.getUserId()); if (Objects.nonNull(modifyApplyExtraInfo)) { expertMetaApply.setExtraMaterial(JSONObject.toJSONString(modifyApplyExtraInfo)); } @@ -654,6 +661,8 @@ public class ExpertInfoServiceImpl implements ExpertInfoService { expertMetaApply.setRegionCode(apply.getRegionCode()); expertMetaApply.setRegionLevel(apply.getRegionLevel()); expertMetaApply.setUserId(originalExpertUserFullInfo.getUserId()); + expertMetaApply.setCreateOn(LocalDateTime.now()); + expertMetaApply.setCreateBy(LoginUserUtil.getUserId()); expertMetaApply.setDisplayEnable(BoolDisplayEnum.Y.name()); if (Objects.nonNull(modifyApplyExtraInfo)) { expertMetaApply.setExtraMaterial(JSONObject.toJSONString(modifyApplyExtraInfo)); diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/organization/manage/ProcDefManage.java b/pmapi/src/main/java/com/ningdatech/pmapi/organization/manage/ProcDefManage.java index 24c6ad1..60acd33 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/organization/manage/ProcDefManage.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/organization/manage/ProcDefManage.java @@ -3,6 +3,7 @@ package com.ningdatech.pmapi.organization.manage; import cn.hutool.core.util.IdUtil; import com.alibaba.fastjson.JSON; import com.baomidou.mybatisplus.core.toolkit.Wrappers; +import com.google.common.collect.Lists; import com.ningdatech.basic.util.StrPool; import com.ningdatech.pmapi.ding.constants.DingOrganizationContant; import com.ningdatech.pmapi.organization.model.entity.DingOrganization; @@ -43,7 +44,9 @@ public class ProcDefManage { */ public String init() { List orgs = organizationService.list(Wrappers.lambdaQuery(DingOrganization.class) - .eq(DingOrganization::getTypeCode, DingOrganizationContant.UNIT_TYPE)); + .in(DingOrganization::getTypeCode, Lists.newArrayList( + DingOrganizationContant.UNIT_TYPE,DingOrganizationContant.GOV_TEMPORARY + ))); log.info("需要处理初始化单位配置的企业 数量为{}",orgs.size()); @@ -101,4 +104,40 @@ public class ProcDefManage { defaultHistory.setVersion(0); orgProcdefHistoryService.save(defaultHistory); } + + public String initByArea(String areaCode) { + List orgs = organizationService.list(Wrappers.lambdaQuery(DingOrganization.class) + .in(DingOrganization::getTypeCode, Lists.newArrayList( + DingOrganizationContant.UNIT_TYPE,DingOrganizationContant.GOV_TEMPORARY + )) + .eq(DingOrganization::getDivisionCode,areaCode)); + + log.info("{}地区 需要处理初始化单位配置的企业 数量为{}",areaCode,orgs.size()); + + for(DingOrganization org : orgs){ + log.info("当前是 {}",org.getOrganizationName()); + String orgCode = org.getOrganizationCode(); + + List models = orgProcdefService.list(Wrappers.lambdaQuery(WflowOrgModels.class) + .eq(WflowOrgModels::getOrgCode, orgCode)); + + log.info("已经有的单位流程 {}", JSON.toJSONString(models)); + + List types = models.stream().map(WflowOrgModels::getType).collect(Collectors.toList()); + //默认流程 + if(!types.contains(ProcessDefTypeEnum.DEFAULT.name())){ + saveDef(org,ProcessDefTypeEnum.DEFAULT); + } + //盖章流程 + if(!types.contains(ProcessDefTypeEnum.SEAL.name())){ + saveDef(org,ProcessDefTypeEnum.SEAL); + } + //联审流程 + if(!types.contains(ProcessDefTypeEnum.JOINT_REVIEW.name())){ + saveDef(org,ProcessDefTypeEnum.JOINT_REVIEW); + } + } + + return "初始化成功"; + } } diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/scheduler/task/BatchUpdateEmployeeTask.java b/pmapi/src/main/java/com/ningdatech/pmapi/scheduler/task/BatchUpdateEmployeeTask.java index fee27da..84e5941 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/scheduler/task/BatchUpdateEmployeeTask.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/scheduler/task/BatchUpdateEmployeeTask.java @@ -2,6 +2,7 @@ package com.ningdatech.pmapi.scheduler.task; import cn.hutool.core.date.StopWatch; import com.baomidou.mybatisplus.core.toolkit.Wrappers; +import com.google.common.collect.Lists; import com.ningdatech.pmapi.ding.constants.DingOrganizationContant; import com.ningdatech.pmapi.ding.task.EmployeeBatchGetTask; import com.ningdatech.pmapi.organization.model.entity.DingOrganization; @@ -42,7 +43,9 @@ public class BatchUpdateEmployeeTask { stopWatch.start(); // 1.查出浙政钉 所有单位 List units = organizationService.list(Wrappers.lambdaQuery(DingOrganization.class) - .eq(DingOrganization::getTypeCode, DingOrganizationContant.UNIT_TYPE)); + .in(DingOrganization::getTypeCode, Lists.newArrayList( + DingOrganizationContant.UNIT_TYPE,DingOrganizationContant.GOV_TEMPORARY + ))); log.info("需要更新的 单位数量为 {}",units.size()); diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/user/manage/UserInfoManage.java b/pmapi/src/main/java/com/ningdatech/pmapi/user/manage/UserInfoManage.java index 4754331..acf6b4d 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/user/manage/UserInfoManage.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/user/manage/UserInfoManage.java @@ -451,6 +451,7 @@ public class UserInfoManage { resUserDetailVO.setOrgCode(userFullInfo.getOrganizationCode()); resUserDetailVO.setOrgName(userFullInfo.getOrganizationName()); resUserDetailVO.setRegionCode(userFullInfo.getRegionCode()); + resUserDetailVO.setRegionLevel(userFullInfo.getRegionLevel()); resUserDetailVO.setRegionName(regionCacheHelper.getRegionName(userFullInfo.getRegionCode() , RegionConst.RL_COUNTY)); resUserDetailVO.setEmpPosUnitCode(userFullInfo.getEmpPosUnitCode()); diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/user/model/vo/ResUserDetailVO.java b/pmapi/src/main/java/com/ningdatech/pmapi/user/model/vo/ResUserDetailVO.java index 4d4ed26..a4cf4b0 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/user/model/vo/ResUserDetailVO.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/user/model/vo/ResUserDetailVO.java @@ -42,6 +42,7 @@ public class ResUserDetailVO { @ApiModelProperty("所属区域") private Long regionId; private String regionCode; + private Integer regionLevel; private String regionName; @ApiModelProperty("用户任职所在单位code")