From d06ef3f44d6dc19dae223ab420165369ea13cc16 Mon Sep 17 00:00:00 2001
From: huminmin <mac@MacBook-Pro.local>
Date: 星期三, 20 五月 2026 16:29:35 +0800
Subject: [PATCH] Merge branch 'dev_New_pro' of http://114.132.189.42:9002/r/product-inventory-management-after into dev_New_pro

---
 src/main/java/com/ruoyi/sales/controller/ShippingInfoController.java |   27 +++++++++++++--------------
 1 files changed, 13 insertions(+), 14 deletions(-)

diff --git a/src/main/java/com/ruoyi/sales/controller/ShippingInfoController.java b/src/main/java/com/ruoyi/sales/controller/ShippingInfoController.java
index f707b5b..9ca9b3a 100644
--- a/src/main/java/com/ruoyi/sales/controller/ShippingInfoController.java
+++ b/src/main/java/com/ruoyi/sales/controller/ShippingInfoController.java
@@ -11,7 +11,6 @@
 import com.ruoyi.framework.aspectj.lang.enums.BusinessType;
 import com.ruoyi.framework.security.LoginUser;
 import com.ruoyi.framework.web.controller.BaseController;
-import com.ruoyi.framework.web.domain.AjaxResult;
 import com.ruoyi.framework.web.domain.R;
 import com.ruoyi.sales.dto.ShippingInfoDto;
 import com.ruoyi.sales.mapper.ShippingInfoMapper;
@@ -45,16 +44,16 @@
 
     @GetMapping("/listPage")
     @Operation(summary = "鍙戣揣淇℃伅鍒楄〃")
-    public AjaxResult listPage(Page page, ShippingInfo req) {
+    public R<?> listPage(Page page, ShippingInfo req) {
         IPage<ShippingInfoDto> listPage = shippingInfoService.listPage(page,req);
-        return AjaxResult.success(listPage);
+        return R.ok(listPage);
     }
 
     @PostMapping("/add")
     @Operation(summary = "娣诲姞鍙戣揣淇℃伅")
     @Transactional(rollbackFor = Exception.class)
     @Log(title = "鍙戣揣淇℃伅绠$悊", businessType = BusinessType.INSERT)
-    public AjaxResult add(@RequestBody ShippingInfoDto req) throws Exception {
+    public R<?> add(@RequestBody ShippingInfoDto req) throws Exception {
         LoginUser loginUser = SecurityUtils.getLoginUser();
         String sh = OrderUtils.countTodayByCreateTime(shippingInfoMapper, "SH","shipping_no");
         // 鍙戣揣瀹℃壒
@@ -70,37 +69,37 @@
         req.setShippingNo(sh);
         req.setStatus("寰呭鏍�");
         boolean save = shippingInfoService.add(req);
-        return save ? AjaxResult.success() : AjaxResult.error();
+        return save ? R.ok() : R.fail();
     }
 
     @Operation(summary = "鍙戣揣鎵e簱瀛�")
     @PostMapping("/deductStock")
     @Transactional(rollbackFor = Exception.class)
     @Log(title = "鍙戣揣淇℃伅绠$悊", businessType = BusinessType.UPDATE)
-    public AjaxResult deductStock(@RequestBody ShippingInfoDto req) throws IOException {
-        return shippingInfoService.deductStock( req) ? AjaxResult.success() : AjaxResult.error();
+    public R<?> deductStock(@RequestBody ShippingInfoDto req) throws IOException {
+        return shippingInfoService.deductStock( req) ? R.ok() : R.fail();
     }
 
     @PostMapping("/update")
     @Operation(summary = "淇敼鍙戣揣淇℃伅")
     @Transactional(rollbackFor = Exception.class)
     @Log(title = "鍙戣揣淇℃伅绠$悊", businessType = BusinessType.UPDATE)
-    public AjaxResult update(@RequestBody ShippingInfo req) {
+    public R<?> update(@RequestBody ShippingInfo req) {
         ShippingInfo byId = shippingInfoService.getById(req.getId());
         if (byId == null) {
-            return AjaxResult.error("鍙戣揣淇℃伅涓嶅瓨鍦�");
+            return R.fail("鍙戣揣淇℃伅涓嶅瓨鍦�");
         }
         boolean update = shippingInfoService.updateById(req);
-        return update ? AjaxResult.success() : AjaxResult.error();
+        return update ? R.ok() : R.fail();
     }
 
     @DeleteMapping("/delete")
     @Operation(summary = "鍒犻櫎鍙戣揣淇℃伅")
     @Transactional(rollbackFor = Exception.class)
     @Log(title = "鍙戣揣淇℃伅绠$悊", businessType = BusinessType.DELETE)
-    public AjaxResult delete(@RequestBody List<Long> ids) {
+    public R<?> delete(@RequestBody List<Long> ids) {
 
-        return shippingInfoService.delete(ids) ? AjaxResult.success("鍒犻櫎鎴愬姛") : AjaxResult.error("鍒犻櫎澶辫触");
+        return shippingInfoService.delete(ids) ? R.ok("鍒犻櫎鎴愬姛") : R.fail("鍒犻櫎澶辫触");
     }
 
     /**
@@ -117,8 +116,8 @@
 
     @GetMapping("/getByCustomerName")
     @Operation(summary = "閫氳繃瀹㈡埛鍚嶇О鏌ヨ鍏宠仈鐨勫彂璐у崟鍙�")
-    public AjaxResult getByCustomerName(String customerName) {
-        return AjaxResult.success(shippingInfoService.getShippingInfoByCustomerName(customerName));
+    public R<?> getByCustomerName(String customerName) {
+        return R.ok(shippingInfoService.getShippingInfoByCustomerName(customerName));
     }
 
     @GetMapping("/getDateil/{id}")

--
Gitblit v1.9.3