From c42c20b9c71c25ed119884ffe130ac013afb7f07 Mon Sep 17 00:00:00 2001
From: Pu Zhibing <393733352@qq.com>
Date: 星期四, 19 六月 2025 09:02:34 +0800
Subject: [PATCH] 修改bug

---
 ruoyi-modules/ruoyi-goods/src/main/java/com/ruoyi/goods/controller/management/MgtGoodsController.java |   25 ++++++++++++++++++++++++-
 1 files changed, 24 insertions(+), 1 deletions(-)

diff --git a/ruoyi-modules/ruoyi-goods/src/main/java/com/ruoyi/goods/controller/management/MgtGoodsController.java b/ruoyi-modules/ruoyi-goods/src/main/java/com/ruoyi/goods/controller/management/MgtGoodsController.java
index 731a389..eabdc44 100644
--- a/ruoyi-modules/ruoyi-goods/src/main/java/com/ruoyi/goods/controller/management/MgtGoodsController.java
+++ b/ruoyi-modules/ruoyi-goods/src/main/java/com/ruoyi/goods/controller/management/MgtGoodsController.java
@@ -10,6 +10,7 @@
 import com.ruoyi.goods.domain.vo.MgtGoodsEditInfoVo;
 import com.ruoyi.goods.domain.vo.MgtGoodsPageVo;
 import com.ruoyi.goods.domain.vo.MgtGoodsTotalVo;
+import com.ruoyi.goods.domain.vo.PageShopMgtGoodsVO;
 import com.ruoyi.goods.service.goods.GoodsService;
 import com.ruoyi.system.api.domain.dto.MgtBaseGetDto;
 import com.ruoyi.system.api.domain.vo.MgtSelectGoodsPageVo;
@@ -55,9 +56,12 @@
     @ApiOperation(value = "导出商品列表")
     public void exportPageMgtGoods( MgtGoodsPageDto mgtGoodsPageDto, HttpServletResponse response) {
         Page<MgtGoodsPageVo> page = new Page<>();
-        if(page.getSize()>5000){
+        if(mgtGoodsPageDto.getPageSize() > 5000){
             page.setSize(5000);
             page.setCurrent(1);
+        }else{
+            page.setSize(mgtGoodsPageDto.getPageSize());
+            page.setCurrent(mgtGoodsPageDto.getPageNum());
         }
         List<MgtGoodsPageVo> mgtGoodsPageVoList = goodsService.pageMgtGoods(page,mgtGoodsPageDto);
         ExcelUtil<MgtGoodsPageVo> util = new ExcelUtil<MgtGoodsPageVo>(MgtGoodsPageVo.class);
@@ -128,4 +132,23 @@
         MgtGoodsEditInfoVo mgtGoodsEditInfoVo = goodsService.getMgtGoodsEditInfo(mgtBaseGetDto);
         return R.ok(mgtGoodsEditInfoVo);
     }
+
+    @RequestMapping(value = "/pageShopMgtGoods", method = RequestMethod.POST)
+    @ApiOperation(value = "商品信息-分页获取门店内商品信息【2.0】",tags = "管理台商户相关接口")
+    public R<Page<PageShopMgtGoodsVO>> pageShopMgtGoods(@RequestBody PageShopMgtGoodsDTO pageShopMgtGoodsDTO) {
+        Page<PageShopMgtGoodsVO> page = new Page<>();
+        page.setSize(pageShopMgtGoodsDTO.getPageSize());
+        page.setCurrent(pageShopMgtGoodsDTO.getPageNum());
+        page.setOptimizeCountSql(false);
+        List<PageShopMgtGoodsVO> pageShopMgtGoods = goodsService.pageShopMgtGoods(page,pageShopMgtGoodsDTO);
+        return R.ok(page.setRecords(pageShopMgtGoods));
+    }
+
+
+    @RequestMapping(value = "/updateGoodsPrice", method = RequestMethod.POST)
+    @ApiOperation(value = "商品信息-修改价格【2.0】",tags = "管理台商户相关接口")
+    public R<Void> updateGoodsPrice(@RequestBody UpdateGoodsPriceDTO updateGoodsPriceDTO) {
+        return goodsService.updateGoodsPrice(updateGoodsPriceDTO);
+    }
+
 }

--
Gitblit v1.7.1