diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/action/AdaptStateChangeAction.java b/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/action/AdaptStateChangeAction.java index 8f9a819..5cb5778 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/action/AdaptStateChangeAction.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/action/AdaptStateChangeAction.java @@ -6,6 +6,7 @@ import com.hz.pm.api.common.statemachine.event.AdaptStateChangeEvent; import com.hz.pm.api.common.statemachine.util.TenderStateMachineUtil; import com.hz.pm.api.projectdeclared.model.entity.Purchase; import com.hz.pm.api.projectlib.model.enumeration.status.TenderAdaptStatus; +import com.hz.pm.api.projectlib.model.enumeration.status.TenderSelfTestStatus; import lombok.extern.slf4j.Slf4j; import org.springframework.messaging.Message; import org.springframework.statemachine.annotation.OnTransition; @@ -32,24 +33,29 @@ public class AdaptStateChangeAction { @OnTransition(source = "WITHOUT_ADAPT_INFO", target = "ADAPT_INFO_AUDIT") public void SUBMIT_ADAPT_INFO(Message message) { Purchase purchase = getPurchaseInfo(message); + purchase.setStatus(TenderAdaptStatus.ADAPT_INFO_AUDIT.getCode()); purchase.setAdaptStatus(TenderAdaptStatus.ADAPT_INFO_AUDIT.getCode()); } @OnTransition(source = "ADAPT_INFO_AUDIT", target = "ADAPT_INFO_PASSED") public void ADAPT_INFO_PASSED(Message message) { Purchase purchase = getPurchaseInfo(message); + purchase.setStatus(TenderSelfTestStatus.WITHOUT_SELF_TEST_INFO.getCode()); + purchase.setSelfTestStatus(TenderSelfTestStatus.WITHOUT_SELF_TEST_INFO.getCode()); purchase.setAdaptStatus(TenderAdaptStatus.ADAPT_INFO_PASSED.getCode()); } @OnTransition(source = "ADAPT_INFO_AUDIT", target = "ADAPT_INFO_FAILED") public void ADAPT_INFO_FAILED(Message message) { Purchase purchase = getPurchaseInfo(message); + purchase.setStatus(TenderAdaptStatus.ADAPT_INFO_FAILED.getCode()); purchase.setAdaptStatus(TenderAdaptStatus.ADAPT_INFO_FAILED.getCode()); } @OnTransition(source = "ADAPT_INFO_FAILED", target = "ADAPT_INFO_AUDIT") public void RESUBMIT_ADAPT_INFO(Message message) { Purchase purchase = getPurchaseInfo(message); + purchase.setStatus(TenderAdaptStatus.ADAPT_INFO_AUDIT.getCode()); purchase.setAdaptStatus(TenderAdaptStatus.ADAPT_INFO_AUDIT.getCode()); } diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/action/ProjectStateChangeAction.java b/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/action/ProjectStateChangeAction.java index 697b512..476d58b 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/action/ProjectStateChangeAction.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/action/ProjectStateChangeAction.java @@ -131,8 +131,14 @@ public class ProjectStateChangeAction { project.setStatus(ProjectStatus.ON_PURCHASING.getCode()); } - @OnTransition(source = "ON_PURCHASING", target = "TO_BE_FIRST_INSPECTED") - public void SUBMIT_OPERATION_PLAN(Message message) { + @OnTransition(source = "ON_PURCHASING", target = "ON_ADAPTING") + public void SUBMIT_PURCHASE_CONTRACT_RECORD(Message message) { + Project project = getProject(message); + project.setStatus(ProjectStatus.ON_ADAPTING.getCode()); + } + + @OnTransition(source = "ON_ADAPTING", target = "TO_BE_FIRST_INSPECTED") + public void SUBMIT_PURCHASE_ORG_CONFIRM(Message message) { Project project = getProject(message); project.setStatus(ProjectStatus.TO_BE_FIRST_INSPECTED.getCode()); } diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/action/SelfTestStateChangeAction.java b/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/action/SelfTestStateChangeAction.java index 8efa427..43f5b28 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/action/SelfTestStateChangeAction.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/action/SelfTestStateChangeAction.java @@ -6,6 +6,7 @@ import com.hz.pm.api.common.statemachine.event.SelfTestStateChangeEvent; import com.hz.pm.api.common.statemachine.util.TenderStateMachineUtil; import com.hz.pm.api.projectdeclared.model.entity.Purchase; import com.hz.pm.api.projectlib.model.enumeration.status.TenderSelfTestStatus; +import com.hz.pm.api.projectlib.model.enumeration.status.TenderTestValidStatus; import lombok.extern.slf4j.Slf4j; import org.springframework.messaging.Message; import org.springframework.statemachine.annotation.OnTransition; @@ -32,24 +33,28 @@ public class SelfTestStateChangeAction { @OnTransition(source = "WITHOUT_SELF_TEST_INFO", target = "SELF_TEST_INFO_AUDIT") public void SUBMIT_SELF_TEST_INFO(Message message) { Purchase purchase = getPurchaseInfo(message); + purchase.setStatus(TenderSelfTestStatus.SELF_TEST_INFO_AUDIT.getCode()); purchase.setSelfTestStatus(TenderSelfTestStatus.SELF_TEST_INFO_AUDIT.getCode()); } @OnTransition(source = "SELF_TEST_INFO_AUDIT", target = "SELF_TEST_INFO_PASSED") public void SELF_TEST_INFO_PASSED(Message message) { Purchase purchase = getPurchaseInfo(message); + purchase.setStatus(TenderTestValidStatus.WITHOUT_TEST_VALID_INFO.getCode()); purchase.setSelfTestStatus(TenderSelfTestStatus.SELF_TEST_INFO_PASSED.getCode()); } @OnTransition(source = "SELF_TEST_INFO_AUDIT", target = "SELF_TEST_INFO_FAILED") public void SELF_TEST_INFO_FAILED(Message message) { Purchase purchase = getPurchaseInfo(message); + purchase.setStatus(TenderSelfTestStatus.SELF_TEST_INFO_FAILED.getCode()); purchase.setSelfTestStatus(TenderSelfTestStatus.SELF_TEST_INFO_FAILED.getCode()); } @OnTransition(source = "SELF_TEST_INFO_FAILED", target = "SELF_TEST_INFO_AUDIT") public void RESUBMIT_SELF_TEST_INFO(Message message) { Purchase purchase = getPurchaseInfo(message); + purchase.setStatus(TenderSelfTestStatus.WITHOUT_SELF_TEST_INFO.getCode()); purchase.setSelfTestStatus(TenderSelfTestStatus.SELF_TEST_INFO_AUDIT.getCode()); } diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/action/TenderStateChangeAction.java b/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/action/TenderStateChangeAction.java index d1f419d..ce4a8b4 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/action/TenderStateChangeAction.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/action/TenderStateChangeAction.java @@ -2,9 +2,10 @@ package com.hz.pm.api.common.statemachine.action; import cn.hutool.core.lang.Assert; import com.hz.pm.api.common.statemachine.builder.impl.TenderStateMachineBuilderImpl; -import com.hz.pm.api.common.statemachine.event.ProjectStateChangeEvent; +import com.hz.pm.api.common.statemachine.event.TenderStateChangeEvent; import com.hz.pm.api.common.statemachine.util.TenderStateMachineUtil; import com.hz.pm.api.projectdeclared.model.entity.Purchase; +import com.hz.pm.api.projectlib.model.enumeration.status.TenderAdaptStatus; import com.hz.pm.api.projectlib.model.enumeration.status.TenderStatus; import lombok.extern.slf4j.Slf4j; import org.springframework.messaging.Message; @@ -23,7 +24,7 @@ import org.springframework.statemachine.annotation.WithStateMachine; @WithStateMachine(id = TenderStateMachineBuilderImpl.MACHINE_ID) public class TenderStateChangeAction { - private Purchase getPurchaseInfo(Message message) { + public static Purchase getPurchaseInfo(Message message) { Purchase purchase = (Purchase) message.getHeaders().get(TenderStateMachineUtil.PURCHASE); Assert.notNull(purchase, "未获取到需要状态变更的标段信息"); return purchase; @@ -35,29 +36,42 @@ public class TenderStateChangeAction { * @param message \ */ @OnTransition(source = "TO_BE_SUBMIT_PURCHASE_CONSTRUCTION_INFO", target = "TO_BE_SUBMIT_OPERATION_PLAN") - public void SUBMIT_PURCHASE_CONSTRUCTION_INFO(Message message) { + public void SUBMIT_PURCHASE_CONSTRUCTION_INFO(Message message) { Purchase purchase = getPurchaseInfo(message); + purchase.setAdaptStatus(TenderAdaptStatus.WITHOUT_ADAPT_INFO.getCode()); purchase.setStatus(TenderStatus.TO_BE_SUBMIT_OPERATION_PLAN.getCode()); } /** - * 填写实施计划 + * 填写合同信息 * * @param message \ */ - @OnTransition(source = "TO_BE_SUBMIT_OPERATION_PLAN", target = "TO_BE_SUBMIT_FIRST_INSPECTED_INFO") - public void SUBMIT_OPERATION_PLAN(Message message) { + @OnTransition(source = "TO_BE_SUBMIT_PURCHASE_CONSTRUCTION_INFO", target = "TO_BE_SUBMIT_FIRST_INSPECTED_INFO") + public void SUBMIT_PURCHASE_CONSTRUCTION_INFO2(Message message) { Purchase purchase = getPurchaseInfo(message); purchase.setStatus(TenderStatus.TO_BE_SUBMIT_FIRST_INSPECTED_INFO.getCode()); } /** + * 填写实施计划 + * + * @param message \ + */ + @OnTransition(source = "TO_BE_SUBMIT_OPERATION_PLAN", target = "WITHOUT_ADAPT_INFO") + public void SUBMIT_OPERATION_PLAN(Message message) { + Purchase purchase = getPurchaseInfo(message); + purchase.setAdaptStatus(TenderAdaptStatus.WITHOUT_ADAPT_INFO.getCode()); + purchase.setStatus(TenderAdaptStatus.WITHOUT_ADAPT_INFO.getCode()); + } + + /** * 上传初验材料 * * @param message \ */ @OnTransition(source = "TO_BE_SUBMIT_FIRST_INSPECTED_INFO", target = "TO_BE_SUBMIT_FINALLY_INSPECTED_APPLY") - public void SUBMIT_FIRST_INSPECTED_FILES(Message message) { + public void SUBMIT_FIRST_INSPECTED_FILES(Message message) { Purchase purchase = getPurchaseInfo(message); purchase.setStatus(TenderStatus.TO_BE_SUBMIT_FINALLY_INSPECTED_APPLY.getCode()); } @@ -68,7 +82,7 @@ public class TenderStateChangeAction { * @param message \ */ @OnTransition(source = "TO_BE_SUBMIT_FINALLY_INSPECTED_APPLY", target = "ON_FINALLY_INSPECTED_APPLY") - public void SUBMIT_FINALLY_INSPECTED(Message message) { + public void SUBMIT_FINALLY_INSPECTED(Message message) { Purchase purchase = getPurchaseInfo(message); purchase.setStatus(TenderStatus.ON_FINALLY_INSPECTED_APPLY.getCode()); } @@ -79,7 +93,7 @@ public class TenderStateChangeAction { * @param message \ */ @OnTransition(source = "FINALLY_INSPECTED_FAILED", target = "ON_FINALLY_INSPECTED_APPLY") - public void RESUBMIT_FINALLY_INSPECTED(Message message) { + public void RESUBMIT_FINALLY_INSPECTED(Message message) { Purchase purchase = getPurchaseInfo(message); purchase.setStatus(TenderStatus.ON_FINALLY_INSPECTED_APPLY.getCode()); } @@ -90,7 +104,7 @@ public class TenderStateChangeAction { * @param message \ */ @OnTransition(source = "ON_FINALLY_INSPECTED_APPLY", target = "FINALLY_INSPECTED_PASSED") - public void FINALLY_INSPECTED_PASSED(Message message) { + public void FINALLY_INSPECTED_PASSED(Message message) { Purchase purchase = getPurchaseInfo(message); purchase.setStatus(TenderStatus.FINALLY_INSPECTED_PASSED.getCode()); } @@ -101,7 +115,7 @@ public class TenderStateChangeAction { * @param message \ */ @OnTransition(source = "ON_FINALLY_INSPECTED_APPLY", target = "FINALLY_INSPECTED_FAILED") - public void FINALLY_INSPECTED_FAILED(Message message) { + public void FINALLY_INSPECTED_FAILED(Message message) { Purchase purchase = getPurchaseInfo(message); purchase.setStatus(TenderStatus.FINALLY_INSPECTED_FAILED.getCode()); } diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/action/TestValidStateChangeAction.java b/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/action/TestValidStateChangeAction.java index 017c0d1..0f6c73a 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/action/TestValidStateChangeAction.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/action/TestValidStateChangeAction.java @@ -5,6 +5,7 @@ import com.hz.pm.api.common.statemachine.builder.impl.TestValidStateMachineBuild import com.hz.pm.api.common.statemachine.event.TestValidStateChangeEvent; import com.hz.pm.api.common.statemachine.util.TenderStateMachineUtil; import com.hz.pm.api.projectdeclared.model.entity.Purchase; +import com.hz.pm.api.projectlib.model.enumeration.status.TenderStatus; import com.hz.pm.api.projectlib.model.enumeration.status.TenderTestValidStatus; import lombok.extern.slf4j.Slf4j; import org.springframework.messaging.Message; @@ -32,24 +33,28 @@ public class TestValidStateChangeAction { @OnTransition(source = "WITHOUT_TEST_VALID_INFO", target = "TEST_VALID_INFO_AUDIT") public void SUBMIT_TEST_VALID_INFO(Message message) { Purchase purchase = getPurchaseInfo(message); + purchase.setStatus(TenderTestValidStatus.TEST_VALID_INFO_AUDIT.getCode()); purchase.setTestValidStatus(TenderTestValidStatus.TEST_VALID_INFO_AUDIT.getCode()); } @OnTransition(source = "TEST_VALID_INFO_AUDIT", target = "TEST_VALID_INFO_PASSED") public void TEST_VALID_INFO_PASSED(Message message) { Purchase purchase = getPurchaseInfo(message); + purchase.setStatus(TenderStatus.WAIT_ORG_CONFIRM.getCode()); purchase.setTestValidStatus(TenderTestValidStatus.TEST_VALID_INFO_PASSED.getCode()); } @OnTransition(source = "TEST_VALID_INFO_AUDIT", target = "TEST_VALID_INFO_FAILED") public void TEST_VALID_INFO_FAILED(Message message) { Purchase purchase = getPurchaseInfo(message); + purchase.setStatus(TenderTestValidStatus.TEST_VALID_INFO_FAILED.getCode()); purchase.setTestValidStatus(TenderTestValidStatus.TEST_VALID_INFO_FAILED.getCode()); } @OnTransition(source = "TEST_VALID_INFO_FAILED", target = "TEST_VALID_INFO_AUDIT") public void RESUBMIT_TEST_VALID_INFO(Message message) { Purchase purchase = getPurchaseInfo(message); + purchase.setStatus(TenderTestValidStatus.TEST_VALID_INFO_AUDIT.getCode()); purchase.setTestValidStatus(TenderTestValidStatus.TEST_VALID_INFO_AUDIT.getCode()); } diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/builder/impl/ProjectStateMachineBuilderImpl.java b/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/builder/impl/ProjectStateMachineBuilderImpl.java index 837c668..6b9a246 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/builder/impl/ProjectStateMachineBuilderImpl.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/builder/impl/ProjectStateMachineBuilderImpl.java @@ -146,8 +146,13 @@ public class ProjectStateMachineBuilderImpl implements BaseStateMachineBuilder

待初验 .withExternal() .source(ProjectStatus.ON_PURCHASING) + .target(ProjectStatus.ON_ADAPTING) + .event(ProjectStateChangeEvent.SUBMIT_PURCHASE_CONTRACT_RECORD).and() + // 填写试试计划 -> 待初验 + .withExternal() + .source(ProjectStatus.ON_ADAPTING) .target(ProjectStatus.TO_BE_FIRST_INSPECTED) - .event(ProjectStateChangeEvent.SUBMIT_OPERATION_PLAN).and() + .event(ProjectStateChangeEvent.SUBMIT_PURCHASE_ORG_CONFIRM).and() // 上传初验材料 .withExternal() .source(ProjectStatus.TO_BE_FIRST_INSPECTED) diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/builder/impl/TenderStateMachineBuilderImpl.java b/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/builder/impl/TenderStateMachineBuilderImpl.java index a2aba72..a5073f9 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/builder/impl/TenderStateMachineBuilderImpl.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/builder/impl/TenderStateMachineBuilderImpl.java @@ -1,8 +1,10 @@ package com.hz.pm.api.common.statemachine.builder.impl; +import com.hz.pm.api.common.statemachine.action.TenderStateChangeAction; import com.hz.pm.api.common.statemachine.builder.BaseStateMachineBuilder; import com.hz.pm.api.common.statemachine.event.TenderStateChangeEvent; import com.hz.pm.api.projectdeclared.model.entity.Purchase; +import com.hz.pm.api.projectdeclared.model.enumerization.BidTypeEnum; import com.hz.pm.api.projectlib.model.enumeration.status.TenderStatus; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; @@ -75,12 +77,26 @@ public class TenderStateMachineBuilderImpl implements BaseStateMachineBuilder { + Purchase purchase = TenderStateChangeAction.getPurchaseInfo(ctx.getMessage()); + return !BidTypeEnum.BUILD_APP.eq(purchase.getBidType()); + }) + .and() // 填写实施计划 .withExternal() .source(TenderStatus.TO_BE_SUBMIT_OPERATION_PLAN) - .target(TenderStatus.TO_BE_SUBMIT_FIRST_INSPECTED_INFO) + .target(TenderStatus.WITHOUT_ADAPT_INFO) .event(TenderStateChangeEvent.SUBMIT_OPERATION_PLAN) .and() + .withExternal() + .source(TenderStatus.WAIT_ORG_CONFIRM) + .target(TenderStatus.TO_BE_SUBMIT_FIRST_INSPECTED_INFO) + .event(TenderStateChangeEvent.SUBMIT_PURCHASE_ORG_CONFIRM) + .and() // 上传初验材料 .withExternal() .source(TenderStatus.TO_BE_SUBMIT_FIRST_INSPECTED_INFO) diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/event/ProjectStateChangeEvent.java b/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/event/ProjectStateChangeEvent.java index 6c309c2..6f88fc8 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/event/ProjectStateChangeEvent.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/event/ProjectStateChangeEvent.java @@ -101,11 +101,18 @@ public enum ProjectStateChangeEvent implements AbstractStateChangeEvent { SUBMIT_PURCHASE_NOTICE(ProjectStatus.TO_BE_PURCHASED.getCode(), null, null), /** + * 填写采购合同备案 + * + * @see ProjectStateChangeAction#SUBMIT_PURCHASE_CONTRACT_RECORD(Message) + */ + SUBMIT_PURCHASE_CONTRACT_RECORD(ProjectStatus.ON_PURCHASING.getCode(), null, null), + + /** * 填写实施计划 * - * @see ProjectStateChangeAction#SUBMIT_OPERATION_PLAN(Message) + * @see ProjectStateChangeAction#SUBMIT_PURCHASE_ORG_CONFIRM(Message) */ - SUBMIT_OPERATION_PLAN(ProjectStatus.ON_PURCHASING.getCode(), null, null), + SUBMIT_PURCHASE_ORG_CONFIRM(ProjectStatus.ON_ADAPTING.getCode(), null, null), /** * 上传初验材料 diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/event/TenderStateChangeEvent.java b/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/event/TenderStateChangeEvent.java index d6ca956..dd3892d 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/event/TenderStateChangeEvent.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/common/statemachine/event/TenderStateChangeEvent.java @@ -23,6 +23,12 @@ public enum TenderStateChangeEvent implements AbstractStateChangeEvent { * 填写实施计划 */ SUBMIT_OPERATION_PLAN(103, null, null), + + /** + * 单位确认 + */ + SUBMIT_PURCHASE_ORG_CONFIRM(104, null, null), + /** * 上传初验材料 */ diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/controller/PurchaseController.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/controller/PurchaseController.java index 37dbfc9..302e358 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/controller/PurchaseController.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/controller/PurchaseController.java @@ -8,7 +8,7 @@ import com.hz.pm.api.projectdeclared.model.dto.XcfhxApplySaveDTO; import com.hz.pm.api.projectdeclared.model.req.*; import com.hz.pm.api.projectdeclared.model.req.SubmitPurchaseNoticeReq.PurchaseNoticeTenderDTO; import com.hz.pm.api.projectdeclared.model.vo.PurchaseVO; -import com.hz.pm.api.projectdeclared.model.vo.TestValidListVO; +import com.hz.pm.api.projectdeclared.model.vo.PurchaseAdaptionListVO; import com.hz.pm.api.projectdeclared.model.vo.XcfhxApplyListVO; import com.hz.pm.api.projectdeclared.model.vo.XinchuangVO; import com.hz.pm.api.projectlib.model.req.ProjectListReq; @@ -23,6 +23,7 @@ import org.springframework.validation.annotation.Validated; import org.springframework.web.bind.annotation.*; import javax.servlet.http.HttpServletResponse; +import javax.validation.Valid; import java.io.UnsupportedEncodingException; import java.util.List; @@ -81,21 +82,9 @@ public class PurchaseController { purchaseManage.submitPurchaseRecord(req); } - @GetMapping("/pageTestValid") - @ApiOperation("获取测试验证列表") - public PageVo pageTestValid(TestValidListReq req) { - return purchaseManage.testValidList(req); - } - - @GetMapping("/pageSelfTest") - @ApiOperation("获取系统自测列表") - public PageVo pageSelfTest(TestValidListReq req) { - return purchaseManage.selfTestList(req); - } - @GetMapping("/pageAdaption") @ApiOperation("获取适配改造列表") - public PageVo pageAdaption(TestValidListReq req) { + public PageVo pageAdaption(PurchaseAdaptionListReq req) { return purchaseManage.adaptList(req); } @@ -164,4 +153,11 @@ public class PurchaseController { return purchaseManage.listPurchaseIntention(unitId); } + @PostMapping("/orgConfirm") + @ApiOperation("单位确认") + @WebLog("单位确认") + public void orgConfirm(@RequestBody @Valid PurchaseOrgConfirmReq req){ + purchaseManage.purchaseOrgConfirm(req); + } + } diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/manage/OperationManage.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/manage/OperationManage.java index 1d42594..37978bc 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/manage/OperationManage.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/manage/OperationManage.java @@ -91,14 +91,6 @@ public class OperationManage { operation.setUpdateOn(now); operation.setUpdateBy(user.getUsername()); operationService.saveOrUpdate(operation); - Wrapper oQuery = Wrappers.lambdaQuery(Operation.class) - .eq(Operation::getProjectId, project.getId()) - .isNotNull(Operation::getProjectStartDate); - if (operationService.count(oQuery) == purchaseMap.size()) { - // 修改项目状态 - projectStateMachineUtil.pass(project); - projectService.updateById(project); - } // 修改标段状态 tenderStateMachineUtil.pass(purchase); purchaseService.updateById(purchase); diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/manage/PurchaseManage.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/manage/PurchaseManage.java index 1913048..4bf1206 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/manage/PurchaseManage.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/manage/PurchaseManage.java @@ -1,6 +1,7 @@ package com.hz.pm.api.projectdeclared.manage; import cn.hutool.core.bean.BeanUtil; +import cn.hutool.core.collection.CollUtil; import cn.hutool.core.date.DateUtil; import cn.hutool.core.date.LocalDateTimeUtil; import cn.hutool.core.io.FileUtil; @@ -28,6 +29,7 @@ import com.hz.pm.api.external.MhApiClient; import com.hz.pm.api.external.MhFileClient; import com.hz.pm.api.external.model.dto.MhPurchaseIntentionDTO; import com.hz.pm.api.external.model.dto.MhPurchaseNoticeDTO; +import com.hz.pm.api.external.model.enumeration.MhUnitStripEnum; import com.hz.pm.api.projectdeclared.helper.MhXchxFileHelper; import com.hz.pm.api.projectdeclared.model.dto.DeclaredProjectExportDTO; import com.hz.pm.api.projectdeclared.model.dto.PurchaseSaveDTO; @@ -40,7 +42,7 @@ import com.hz.pm.api.projectdeclared.model.enumerization.PurchaseSourceTypeEnum; import com.hz.pm.api.projectdeclared.model.req.*; import com.hz.pm.api.projectdeclared.model.req.SubmitPurchaseNoticeReq.PurchaseNoticeTenderDTO; import com.hz.pm.api.projectdeclared.model.vo.PurchaseVO; -import com.hz.pm.api.projectdeclared.model.vo.TestValidListVO; +import com.hz.pm.api.projectdeclared.model.vo.PurchaseAdaptionListVO; import com.hz.pm.api.projectdeclared.model.vo.XcfhxApplyListVO; import com.hz.pm.api.projectdeclared.model.vo.XinchuangVO; import com.hz.pm.api.projectdeclared.service.*; @@ -361,9 +363,6 @@ public class PurchaseManage { if (purchase.getId() == null) { purchase.setCreateBy(user.getUserIdStr()); } - purchase.setSelfTestStatus(TenderSelfTestStatus.WITHOUT_SELF_TEST_INFO.getCode()); - purchase.setTestValidStatus(TenderTestValidStatus.WITHOUT_TEST_VALID_INFO.getCode()); - purchase.setAdaptStatus(TenderAdaptStatus.WITHOUT_ADAPT_INFO.getCode()); purchase.setStatus(TenderStatus.TO_BE_SUBMIT_PURCHASE_CONSTRUCTION_INFO.getCode()); purchase.setXcfhxApplyStatus(TenderXcfhxApplyStatus.TO_BE_SUBMIT_XCFHX_APPLY.getCode()); if (Boolean.TRUE.equals(mhPurchaseNoticeOpen) && Boolean.TRUE.equals(w.getPublishMhNotice())) { @@ -477,26 +476,16 @@ public class PurchaseManage { projectService.updateById(project); } - private PageVo queryData(TestValidListReq req, - SFunction function, - String actualTimeColumn) { + private PageVo queryData(PurchaseAdaptionListReq req) { LambdaQueryWrapper query = Wrappers.lambdaQuery(Purchase.class) .like(StrUtil.isNotBlank(req.getBidName()), Purchase::getBidName, req.getBidName()) .le(req.getCreateOnMax() != null, Purchase::getCreateOn, req.getCreateOnMax()) .ge(req.getCreateOnMin() != null, Purchase::getCreateOn, req.getCreateOnMin()) - .eq(req.getStatus() != null, function, req.getStatus()) + .eq(req.getStatus() != null, Purchase::getStatus, req.getStatus()) + .eq(Purchase::getBidType, BidTypeEnum.BUILD_APP.getCode()) .notExists(ExistsSqlConst.PURCHASE_EXISTS_PROJECT + "and np.stage = {0}", ProjectStatus.STOPPED.getCode()) - .isNotNull(function) .orderByDesc(Purchase::getCreateOn); - boolean display = !Boolean.FALSE.equals(req.getDisplay()); - String existsSql = String.format(ExistsSqlConst.PURCHASE_EXISTS_OPERATION + " and npo.%s is not null", actualTimeColumn); - if (display) { - query.and(q1 -> q1.eq(Purchase::getBidType, BidTypeEnum.BUILD_APP.getCode()) - .or(q2 -> q2.exists(existsSql))); - } else { - query.ne(Purchase::getBidType, BidTypeEnum.BUILD_APP.getCode()).notExists(existsSql); - } UserFullInfoDTO user = userInfoHelper.getUserFullInfo(LoginUserUtil.getUserId()); if (!purchaseService.buildPurchaseQueryPermission(query, user)) { return PageVo.empty(); @@ -506,74 +495,34 @@ public class PurchaseManage { return PageVo.empty(); } List records = page.getRecords(); - Map createOnMap = new HashMap<>(); - if (display) { - List bidIds = CollUtils.fieldList(records, Purchase::getId); - AbstractStateChangeEvent event; - if ("actual_test_valid_time".equals(actualTimeColumn)) { - event = TestValidStateChangeEvent.SUBMIT_TEST_VALID_INFO; - } else if ("actual_adaption_time".equals(actualTimeColumn)) { - event = AdaptStateChangeEvent.SUBMIT_ADAPT_INFO; - } else { - event = SelfTestStateChangeEvent.SUBMIT_SELF_TEST_INFO; - } - Wrapper pscQuery = Wrappers.lambdaQuery(PurchaseStatusChange.class) - .in(PurchaseStatusChange::getEvent, event.name()) - .in(PurchaseStatusChange::getBidId, bidIds) - .orderByAsc(PurchaseStatusChange::getCreateOn); - List changes = purchaseStatusChangeService.list(pscQuery); - Map mapByBidId = BizUtils.groupFirstMap(changes, - PurchaseStatusChange::getBidId, Comparator.comparing(PurchaseStatusChange::getCreateOn)); - records.forEach(w -> { - if (BidTypeEnum.BUILD_APP.getCode().equals(w.getBidType())) { - createOnMap.put(w.getId(), w.getCreateOn()); - } else { - PurchaseStatusChange change = mapByBidId.get(w.getId()); - if (change != null) { - createOnMap.put(w.getId(), change.getCreateOn()); - } - } - }); - } List projectIds = CollUtils.fieldList(records, Purchase::getProjectId); List projects = projectService.listByIds(projectIds); Map projectMap = CollUtils.listToMap(projects, Project::getId); Map contractMap = contractService.listByProjectIds(projectIds); - List data = records.stream().map(w -> { - TestValidListVO item = new TestValidListVO(); - item.setBidId(w.getId()); + List data = records.stream().map(w -> { + PurchaseAdaptionListVO adaption = new PurchaseAdaptionListVO(); + adaption.setBidId(w.getId()); Project project = projectMap.get(w.getProjectId()); - if (project != null) { - item.setProjectName(project.getProjectName()); - item.setBuildOrg(project.getBuildOrgName()); - } - item.setBizName(w.getBidName()); - item.setProjectId(w.getProjectId()); + adaption.setProjectName(project.getProjectName()); + adaption.setBuildOrg(project.getBuildOrgName()); + adaption.setProjectStatus(project.getStatus()); + adaption.setBizName(w.getBidName()); + adaption.setProjectId(w.getProjectId()); String projectCode = ProjectIdCodeCacheUtil.get(w.getProjectId()); - item.setProjectCode(projectCode); + adaption.setProjectCode(projectCode); + adaption.setUnitStripName(MhUnitStripEnum.getVal(project.getUnitStrip())); Contract contract = contractMap.get(w.getId()); if (contract != null) { - item.setContractAmount(contract.getTotalAmount()); - } - item.setStatus(function.apply(w)); - if (display) { - item.setCreateOn(createOnMap.get(w.getId())); + adaption.setContractAmount(contract.getTotalAmount()); } - return item; + return adaption; }).collect(Collectors.toList()); return PageVo.of(data, page.getTotal()); } - public PageVo testValidList(TestValidListReq req) { - return queryData(req, Purchase::getTestValidStatus, "actual_test_valid_time"); - } - - public PageVo adaptList(TestValidListReq req) { - return queryData(req, Purchase::getAdaptStatus, "actual_adaption_time"); - } - public PageVo selfTestList(TestValidListReq req) { - return queryData(req, Purchase::getSelfTestStatus, "actual_self_test_time"); + public PageVo adaptList(PurchaseAdaptionListReq req) { + return queryData(req); } @Transactional(rollbackFor = Exception.class) @@ -832,4 +781,30 @@ public class PurchaseManage { public void exportXcfhFile(String code, HttpServletResponse response) throws UnsupportedEncodingException { mhXchxFileHelper.exportReport(code, response); } + + @Transactional(rollbackFor = Exception.class) + public synchronized void purchaseOrgConfirm(PurchaseOrgConfirmReq req) { + Purchase purchase = purchaseService.getById(req.getBidId()); + if (!TenderStatus.WAIT_ORG_CONFIRM.eq(purchase.getStatus())) { + throw BizException.wrap("该标段不支持单位确认"); + } + tenderStateMachineUtil.pass(purchase); + purchaseService.updateById(purchase); + LambdaQueryWrapper purchaseQuery = Wrappers.lambdaQuery(Purchase.class) + .select(Purchase::getStatus, Purchase::getBidType) + .eq(Purchase::getProjectId, purchase.getProjectId()); + List purchases = purchaseService.list(purchaseQuery); + boolean changeProjectStatus = CollUtil.allMatch(purchases, w -> { + if (!BidTypeEnum.BUILD_APP.eq(w.getBidType())) { + return true; + } + return TenderStatus.TO_BE_SUBMIT_FIRST_INSPECTED_INFO.eq(w.getStatus()); + }); + if (changeProjectStatus) { + Project project = projectService.getNewestNoNull(purchase.getProjectId()); + projectStateMachineUtil.pass(project); + projectService.updateById(project); + } + } + } diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/mapper/ProjectChangeHistoryMapper.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/mapper/ProjectChangeHistoryMapper.java index 17a062b..6c5347d 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/mapper/ProjectChangeHistoryMapper.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/mapper/ProjectChangeHistoryMapper.java @@ -1,6 +1,6 @@ package com.hz.pm.api.projectdeclared.mapper; -import com.hz.pm.api.projectdeclared.entity.ProjectChangeHistory; +import com.hz.pm.api.projectdeclared.model.entity.ProjectChangeHistory; import com.baomidou.mybatisplus.core.mapper.BaseMapper; /** diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/entity/ProjectChangeHistory.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/entity/ProjectChangeHistory.java similarity index 94% rename from hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/entity/ProjectChangeHistory.java rename to hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/entity/ProjectChangeHistory.java index 59a39f2..10f663d 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/entity/ProjectChangeHistory.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/entity/ProjectChangeHistory.java @@ -1,4 +1,4 @@ -package com.hz.pm.api.projectdeclared.entity; +package com.hz.pm.api.projectdeclared.model.entity; import com.baomidou.mybatisplus.annotation.*; import io.swagger.annotations.ApiModel; diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/req/TestValidListReq.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/req/PurchaseAdaptionListReq.java similarity index 79% rename from hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/req/TestValidListReq.java rename to hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/req/PurchaseAdaptionListReq.java index dee20d3..f2b21d3 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/req/TestValidListReq.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/req/PurchaseAdaptionListReq.java @@ -1,6 +1,7 @@ package com.hz.pm.api.projectdeclared.model.req; import com.ningdatech.basic.model.PagePo; +import io.swagger.annotations.ApiModelProperty; import lombok.Data; import lombok.EqualsAndHashCode; import org.springframework.format.annotation.DateTimeFormat; @@ -9,7 +10,7 @@ import java.time.LocalDateTime; /** *

- * TestValidListReq + * PurchaseAdaptionListReq *

* * @author WendyYang @@ -17,10 +18,11 @@ import java.time.LocalDateTime; */ @Data @EqualsAndHashCode(callSuper = true) -public class TestValidListReq extends PagePo { +public class PurchaseAdaptionListReq extends PagePo { private String bidName; + @ApiModelProperty("标段状态") private Integer status; @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/req/PurchaseOrgConfirmReq.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/req/PurchaseOrgConfirmReq.java new file mode 100644 index 0000000..9281e29 --- /dev/null +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/req/PurchaseOrgConfirmReq.java @@ -0,0 +1,23 @@ +package com.hz.pm.api.projectdeclared.model.req; + +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import javax.validation.constraints.NotNull; + +/** + *

+ * OrgConfirmReq + *

+ * + * @author WendyYang + * @since 00:44 2024/8/17 + */ +@Data +public class PurchaseOrgConfirmReq { + + @ApiModelProperty("标段ID") + @NotNull(message = "标段ID不能为空") + private Long bidId; + +} diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/vo/TestValidListVO.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/vo/PurchaseAdaptionListVO.java similarity index 68% rename from hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/vo/TestValidListVO.java rename to hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/vo/PurchaseAdaptionListVO.java index 38a81e1..5cfeb33 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/vo/TestValidListVO.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/model/vo/PurchaseAdaptionListVO.java @@ -1,21 +1,29 @@ package com.hz.pm.api.projectdeclared.model.vo; import io.swagger.annotations.ApiModelProperty; +import lombok.Builder; import lombok.Data; +import lombok.experimental.Tolerate; import java.math.BigDecimal; import java.time.LocalDateTime; /** *

- * TestValidListVO + * PurchaseAdaptionListVO *

* * @author WendyYang * @since 14:43 2024/3/27 */ @Data -public class TestValidListVO { +@Builder +public class PurchaseAdaptionListVO { + + @Tolerate + public PurchaseAdaptionListVO() { + // 默认构造方法 + } @ApiModelProperty("标段ID") private Long bidId; @@ -35,6 +43,12 @@ public class TestValidListVO { @ApiModelProperty("创建时间") private LocalDateTime createOn; + @ApiModelProperty("所属领域") + private String unitStripName; + + @ApiModelProperty("项目状态") + private Integer projectStatus; + private Long projectId; private String projectCode; diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/service/IProjectChangeHistoryService.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/service/IProjectChangeHistoryService.java index 22c8ea8..fb4a4df 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/service/IProjectChangeHistoryService.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/service/IProjectChangeHistoryService.java @@ -1,6 +1,6 @@ package com.hz.pm.api.projectdeclared.service; -import com.hz.pm.api.projectdeclared.entity.ProjectChangeHistory; +import com.hz.pm.api.projectdeclared.model.entity.ProjectChangeHistory; import com.baomidou.mybatisplus.extension.service.IService; /** diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/service/impl/ProjectChangeHistoryServiceImpl.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/service/impl/ProjectChangeHistoryServiceImpl.java index 81e9ff9..1cd2647 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/service/impl/ProjectChangeHistoryServiceImpl.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectdeclared/service/impl/ProjectChangeHistoryServiceImpl.java @@ -1,6 +1,6 @@ package com.hz.pm.api.projectdeclared.service.impl; -import com.hz.pm.api.projectdeclared.entity.ProjectChangeHistory; +import com.hz.pm.api.projectdeclared.model.entity.ProjectChangeHistory; import com.hz.pm.api.projectdeclared.mapper.ProjectChangeHistoryMapper; import com.hz.pm.api.projectdeclared.service.IProjectChangeHistoryService; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/handle/stage/ProjectPurchaseHandle.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/handle/stage/ProjectPurchaseHandle.java index 2253b27..65c2124 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/handle/stage/ProjectPurchaseHandle.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/handle/stage/ProjectPurchaseHandle.java @@ -17,7 +17,6 @@ import org.springframework.stereotype.Component; import java.util.List; -import static com.hz.pm.api.common.statemachine.event.ProjectStateChangeEvent.SUBMIT_OPERATION_PLAN; import static com.hz.pm.api.projectlib.model.enumeration.status.ProjectStatus.ON_PURCHASING; import static com.hz.pm.api.projectlib.model.enumeration.status.ProjectStatus.TO_BE_PURCHASED; @@ -61,7 +60,7 @@ public class ProjectPurchaseHandle extends AbstractProcessHandle { detail.setStepStatus(StepStatusEnum.ON_GOING); } else { // 根据采购备案的时间获取 - ProjectStatusChange change = ctx.getProjectStateChange(SUBMIT_OPERATION_PLAN); + ProjectStatusChange change = ctx.getProjectStateChange(ProjectStateChangeEvent.SUBMIT_PURCHASE_CONTRACT_RECORD); if (change == null) { detail.setStepStatus(StepStatusEnum.NOT_START); } else { diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/helper/ProjectChangeStopHelper.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/helper/ProjectChangeStopHelper.java index f00ad5b..93687c3 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/helper/ProjectChangeStopHelper.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/helper/ProjectChangeStopHelper.java @@ -12,7 +12,7 @@ import com.hz.pm.api.common.model.constant.BizConst; import com.hz.pm.api.common.statemachine.event.ProjectStateChangeEvent; import com.hz.pm.api.common.statemachine.event.TenderStateChangeEvent; import com.hz.pm.api.common.util.BizUtils; -import com.hz.pm.api.projectdeclared.entity.ProjectChangeHistory; +import com.hz.pm.api.projectdeclared.model.entity.ProjectChangeHistory; import com.hz.pm.api.projectdeclared.model.dto.*; import com.hz.pm.api.projectdeclared.model.entity.Contract; import com.hz.pm.api.projectdeclared.model.entity.Operation; diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/manage/ProjectChangeManage.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/manage/ProjectChangeManage.java index 5542db4..3c17b6e 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/manage/ProjectChangeManage.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/manage/ProjectChangeManage.java @@ -10,7 +10,7 @@ import com.baomidou.mybatisplus.core.toolkit.Wrappers; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.hz.pm.api.common.enumeration.ProjectProcessType; import com.hz.pm.api.external.model.enumeration.MhUnitStripEnum; -import com.hz.pm.api.projectdeclared.entity.ProjectChangeHistory; +import com.hz.pm.api.projectdeclared.model.entity.ProjectChangeHistory; import com.hz.pm.api.projectdeclared.manage.DeclaredProjectHelper; import com.hz.pm.api.projectdeclared.model.dto.*; import com.hz.pm.api.projectdeclared.model.vo.*; diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/enumeration/status/ProjectStatus.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/enumeration/status/ProjectStatus.java index 97df4f6..9f4381d 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/enumeration/status/ProjectStatus.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/enumeration/status/ProjectStatus.java @@ -55,6 +55,8 @@ public enum ProjectStatus implements IStatus { TO_BE_PURCHASED(20001, "待采购"), ON_PURCHASING(20007, "采购中"), + ON_ADAPTING(20010, "适配改造中"), + TO_BE_FIRST_INSPECTED(20008, "待上传初验材料"), ON_PILOT_RUNNING(20009, "试运行中"), diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/enumeration/status/TenderAdaptStatus.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/enumeration/status/TenderAdaptStatus.java index 56b4cca..8906c9e 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/enumeration/status/TenderAdaptStatus.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/enumeration/status/TenderAdaptStatus.java @@ -20,10 +20,10 @@ import java.util.Optional; @AllArgsConstructor public enum TenderAdaptStatus implements IStatus { - WITHOUT_ADAPT_INFO(2100, "待填写适配改造信息"), - ADAPT_INFO_AUDIT(2101, "适配改造信息审核中"), - ADAPT_INFO_FAILED(2102, "适配改造信息审核失败"), - ADAPT_INFO_PASSED(2103, "适配改造信息审核通过"); + WITHOUT_ADAPT_INFO(2100, "待上传开工文件"), + ADAPT_INFO_AUDIT(2101, "开工文件审核中"), + ADAPT_INFO_FAILED(2102, "开工文件审核失败"), + ADAPT_INFO_PASSED(2103, "开工文件审核通过"); private final Integer code; private final String desc; diff --git a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/enumeration/status/TenderStatus.java b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/enumeration/status/TenderStatus.java index 3d8d8d9..63d3a93 100644 --- a/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/enumeration/status/TenderStatus.java +++ b/hz-pm-api/src/main/java/com/hz/pm/api/projectlib/model/enumeration/status/TenderStatus.java @@ -21,7 +21,10 @@ import java.util.Optional; public enum TenderStatus implements IStatus { TO_BE_SUBMIT_PURCHASE_CONSTRUCTION_INFO(ProjectStatus.ON_PURCHASING, 101, "待填写采购&合同信息"), - TO_BE_SUBMIT_OPERATION_PLAN(ProjectStatus.ON_PURCHASING, 103, "待填写实施计划"), + TO_BE_SUBMIT_OPERATION_PLAN(ProjectStatus.ON_ADAPTING, 103, "待填写实施计划"), + // 衔接状态 + WITHOUT_ADAPT_INFO(ProjectStatus.ON_ADAPTING, TenderAdaptStatus.WITHOUT_ADAPT_INFO.getCode(), "待填写适配改造信息"), + WAIT_ORG_CONFIRM(ProjectStatus.ON_ADAPTING, 104, "待单位确认"), TO_BE_SUBMIT_FIRST_INSPECTED_INFO(ProjectStatus.TO_BE_FIRST_INSPECTED, 201, "待上传初验材料"), TO_BE_SUBMIT_FINALLY_INSPECTED_APPLY(ProjectStatus.ON_PILOT_RUNNING, 401, "待终验申报"), ON_FINALLY_INSPECTED_APPLY(ProjectStatus.ON_FINALLY_INSPECTED, 501, "终验申报中"),