From f4b3178c19b796287e7116c628b63ae567459600 Mon Sep 17 00:00:00 2001 From: "shuo.wang" Date: Wed, 22 Jan 2025 09:51:29 +0800 Subject: [PATCH] fix initShop --- .../impl/IntentAgreementServiceImpl.java | 30 +++++++++---------- 1 file changed, 14 insertions(+), 16 deletions(-) diff --git a/coolstore-partner-service/src/main/java/com/cool/store/service/impl/IntentAgreementServiceImpl.java b/coolstore-partner-service/src/main/java/com/cool/store/service/impl/IntentAgreementServiceImpl.java index 79e9e5476..a3d6d4c30 100644 --- a/coolstore-partner-service/src/main/java/com/cool/store/service/impl/IntentAgreementServiceImpl.java +++ b/coolstore-partner-service/src/main/java/com/cool/store/service/impl/IntentAgreementServiceImpl.java @@ -142,15 +142,14 @@ public class IntentAgreementServiceImpl extends LineFlowService implements Inten @Override @Transactional(rollbackFor = Exception.class) protected Boolean auditPass(Long auditId, LineInfoDO lineInfo, String userId) { - LineInfoDO updateLine = new LineInfoDO(); - updateLine.setId(lineInfo.getId()); - updateLine.setWorkflowStage(WorkflowStageEnum.STORE.getCode()); - updateLine.setWorkflowSubStageStatus(WorkflowSubStageStatusEnum.SIGN_INTENT_AGREEMENT_125.getCode()); - updateLine.setDevelopmentManager(lineInfo.getInvestmentManager()); - updateLine.setUpdateUserId(userId); - lineInfoDAO.updateLineInfo(updateLine); + lineInfo.setId(lineInfo.getId()); + lineInfo.setWorkflowStage(WorkflowStageEnum.STORE.getCode()); + lineInfo.setWorkflowSubStageStatus(WorkflowSubStageStatusEnum.SIGN_INTENT_AGREEMENT_125.getCode()); + lineInfo.setDevelopmentManager(lineInfo.getInvestmentManager()); + lineInfo.setUpdateUserId(userId); + lineInfoDAO.updateLineInfo(lineInfo); //初始化店铺 - shopService.initShop(updateLine); + shopService.initShop(lineInfo); // 批量获取线索下门店的选址未开始的数据 List stages = shopStageInfoDAO.getByLineIdAndSubStage(lineInfo.getId()); List shopIds = stages.stream().map(ShopStageInfoDO::getShopId).collect(Collectors.toList()); @@ -211,15 +210,14 @@ public class IntentAgreementServiceImpl extends LineFlowService implements Inten if ( !WorkflowSubStageStatusEnum.SIGN_INTENT_AGREEMENT_70.getCode().equals(lineInfo.getWorkflowSubStageStatus())) { throw new ServiceException(ErrorCodeEnum.LINE_STATUS_NOT_ALLOW_OPERATE); } - LineInfoDO updateLine = new LineInfoDO(); - updateLine.setId(lineInfo.getId()); - updateLine.setWorkflowStage(WorkflowStageEnum.STORE.getCode()); - updateLine.setWorkflowSubStageStatus(WorkflowSubStageStatusEnum.SIGN_INTENT_AGREEMENT_125.getCode()); - updateLine.setDevelopmentManager(lineInfo.getInvestmentManager()); - updateLine.setUpdateUserId(user.getUserId()); - lineInfoDAO.updateLineInfo(updateLine); + + lineInfo.setWorkflowStage(WorkflowStageEnum.STORE.getCode()); + lineInfo.setWorkflowSubStageStatus(WorkflowSubStageStatusEnum.SIGN_INTENT_AGREEMENT_125.getCode()); + lineInfo.setDevelopmentManager(lineInfo.getInvestmentManager()); + lineInfo.setUpdateUserId(user.getUserId()); + lineInfoDAO.updateLineInfo(lineInfo); //初始化店铺 - shopService.initShop(updateLine); + shopService.initShop(lineInfo); // 批量获取线索下门店的选址未开始的数据 List stages = shopStageInfoDAO.getByLineIdAndSubStage(lineInfo.getId()); List shopIds = stages.stream().map(ShopStageInfoDO::getShopId).collect(Collectors.toList());