From a2b1fc3873eb093dc7cf43801baa33eac6013dd7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=8B=8F=E7=AB=B9=E7=BA=A2?= Date: Wed, 26 Jun 2024 10:42:10 +0800 Subject: [PATCH] =?UTF-8?q?=E8=AE=BE=E8=AE=A1=E9=98=B6=E6=AE=B5bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/cool/store/dao/DecorationDesignInfoDAO.java | 4 ++-- .../com/cool/store/service/impl/DecorationServiceImpl.java | 4 ++-- .../cool/store/controller/webb/PCDecorationController.java | 7 +++++++ .../store/controller/webc/MiniDecorationController.java | 4 ++-- 4 files changed, 13 insertions(+), 6 deletions(-) diff --git a/coolstore-partner-dao/src/main/java/com/cool/store/dao/DecorationDesignInfoDAO.java b/coolstore-partner-dao/src/main/java/com/cool/store/dao/DecorationDesignInfoDAO.java index 7a33d4e82..422282cd4 100644 --- a/coolstore-partner-dao/src/main/java/com/cool/store/dao/DecorationDesignInfoDAO.java +++ b/coolstore-partner-dao/src/main/java/com/cool/store/dao/DecorationDesignInfoDAO.java @@ -28,8 +28,8 @@ public class DecorationDesignInfoDAO { return decorationDesignInfoMapper.insertSelective(decorationDesignInfoDO); } - public Integer updateByPrimaryKey(DecorationDesignInfoDO decorationDesignInfoDO){ - return decorationDesignInfoMapper.updateByPrimaryKey(decorationDesignInfoDO); + public Integer updateByPrimaryKeySelective(DecorationDesignInfoDO decorationDesignInfoDO){ + return decorationDesignInfoMapper.updateByPrimaryKeySelective(decorationDesignInfoDO); } public DecorationDesignInfoDO getByShopId(Long shopId){ diff --git a/coolstore-partner-service/src/main/java/com/cool/store/service/impl/DecorationServiceImpl.java b/coolstore-partner-service/src/main/java/com/cool/store/service/impl/DecorationServiceImpl.java index dd1379695..206e8487e 100644 --- a/coolstore-partner-service/src/main/java/com/cool/store/service/impl/DecorationServiceImpl.java +++ b/coolstore-partner-service/src/main/java/com/cool/store/service/impl/DecorationServiceImpl.java @@ -540,7 +540,7 @@ public class DecorationServiceImpl implements DecorationService { DecorationDesignInfoDO decoration = decorationDesignInfoDAO.getByShopId(request.getShopId()); if (Objects.nonNull(decoration)){ decorationDesignInfoDO.setId(decoration.getId()); - decorationDesignInfoDAO.updateByPrimaryKey(decorationDesignInfoDO); + decorationDesignInfoDAO.updateByPrimaryKeySelective(decorationDesignInfoDO); }else { decorationDesignInfoDAO.insertSelective(decorationDesignInfoDO); } @@ -580,7 +580,7 @@ public class DecorationServiceImpl implements DecorationService { DecorationDesignInfoDO decoration = decorationDesignInfoDAO.getByShopId(request.getShopId()); if (Objects.nonNull(decoration)){ decorationDesignInfoDO.setId(decoration.getId()); - decorationDesignInfoDAO.updateByPrimaryKey(decorationDesignInfoDO); + decorationDesignInfoDAO.updateByPrimaryKeySelective(decorationDesignInfoDO); } //更新装修设计状态 shopStageInfoDAO.batchUpdateShopStageStatus(request.getShopId(), Arrays.asList(ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_91, ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_111)); diff --git a/coolstore-partner-web/src/main/java/com/cool/store/controller/webb/PCDecorationController.java b/coolstore-partner-web/src/main/java/com/cool/store/controller/webb/PCDecorationController.java index 0b45d967d..ef80c377a 100644 --- a/coolstore-partner-web/src/main/java/com/cool/store/controller/webb/PCDecorationController.java +++ b/coolstore-partner-web/src/main/java/com/cool/store/controller/webb/PCDecorationController.java @@ -11,6 +11,7 @@ import com.cool.store.response.ThreeSignResponse; import com.cool.store.service.DecorationService; import com.cool.store.service.PreparationService; import com.cool.store.service.SeeAcceptanceService; +import com.cool.store.vo.DecorationDesignVO; import com.cool.store.vo.Fitment.DesignInfoVo; import com.cool.store.vo.LinePayVO; @@ -130,6 +131,12 @@ public class PCDecorationController { return ResponseResult.success(decorationService.submitDecorationDesign(request,CurrentUserHolder.getUser())); } + @ApiOperation("查询设计方案") + @GetMapping("/getDecorationDesign") + public ResponseResult getDecorationDesign(@RequestParam Long shopId){ + return ResponseResult.success(decorationService.getDecorationDesign(shopId)); + } + @ApiOperation("装修阶段完成") @PostMapping("/confirmComplete") public ResponseResult confirmComplete(@RequestParam Long shopId){ diff --git a/coolstore-partner-web/src/main/java/com/cool/store/controller/webc/MiniDecorationController.java b/coolstore-partner-web/src/main/java/com/cool/store/controller/webc/MiniDecorationController.java index cb5674ce3..93223f367 100644 --- a/coolstore-partner-web/src/main/java/com/cool/store/controller/webc/MiniDecorationController.java +++ b/coolstore-partner-web/src/main/java/com/cool/store/controller/webc/MiniDecorationController.java @@ -124,8 +124,8 @@ public class MiniDecorationController { @ApiOperation("加盟商确定设计方案") @PostMapping("/confirmDesign") - public ResponseResult confirmDesign(@RequestParam DecorationDesignRequest shopId){ - return ResponseResult.success(decorationService.confirmDesign(shopId,CurrentUserHolder.getUser())); + public ResponseResult confirmDesign(@RequestBody DecorationDesignRequest request){ + return ResponseResult.success(decorationService.confirmDesign(request,CurrentUserHolder.getUser())); }