From 3e5c32288447da14ad6032aeb5bf5f79fa9a0560 Mon Sep 17 00:00:00 2001
From: xin <1099200748@qq.com>
Date: Tue, 24 Jun 2025 11:40:03 +0800
Subject: [PATCH] 封装返回值

---
 oying-system/src/main/java/com/oying/modules/sh/rest/OrderProductSnapshotController.java |   19 +++++++++++--------
 1 files changed, 11 insertions(+), 8 deletions(-)

diff --git a/oying-system/src/main/java/com/oying/modules/sh/rest/OrderProductSnapshotController.java b/oying-system/src/main/java/com/oying/modules/sh/rest/OrderProductSnapshotController.java
index 07d1508..24bdc0d 100644
--- a/oying-system/src/main/java/com/oying/modules/sh/rest/OrderProductSnapshotController.java
+++ b/oying-system/src/main/java/com/oying/modules/sh/rest/OrderProductSnapshotController.java
@@ -5,22 +5,25 @@
 import com.oying.modules.sh.service.OrderProductSnapshotService;
 import com.oying.modules.sh.domain.dto.OrderProductSnapshotQueryCriteria;
 import lombok.RequiredArgsConstructor;
+
 import java.util.List;
+
 import org.springframework.http.HttpStatus;
 import org.springframework.http.ResponseEntity;
 import org.springframework.security.access.prepost.PreAuthorize;
 import org.springframework.validation.annotation.Validated;
 import org.springframework.web.bind.annotation.*;
 import io.swagger.annotations.*;
+
 import java.io.IOException;
 import javax.servlet.http.HttpServletResponse;
+
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
-import com.oying.utils.PageResult;
 
 /**
-* @author lixin
-* @date 2025-06-11
-**/
+ * @author lixin
+ * @date 2025-06-11
+ **/
 @RestController
 @RequiredArgsConstructor
 @Api(tags = "SH:订单商品快照")
@@ -39,16 +42,16 @@
     @GetMapping
     @ApiOperation("查询订单商品快照")
     @PreAuthorize("@el.check('orderProductSnapshot:list')")
-    public ResponseEntity<PageResult<OrderProductSnapshot>> queryOrderProductSnapshot(OrderProductSnapshotQueryCriteria criteria){
+    public ResponseEntity<Object> queryOrderProductSnapshot(OrderProductSnapshotQueryCriteria criteria) {
         Page<Object> page = new Page<>(criteria.getPage(), criteria.getSize());
-        return new ResponseEntity<>(orderProductSnapshotService.queryAll(criteria,page),HttpStatus.OK);
+        return new ResponseEntity<>(orderProductSnapshotService.queryAll(criteria, page), HttpStatus.OK);
     }
 
     @PostMapping
     @Log("新增订单商品快照")
     @ApiOperation("新增订单商品快照")
     @PreAuthorize("@el.check('orderProductSnapshot:add')")
-    public ResponseEntity<Object> createOrderProductSnapshot(@Validated @RequestBody OrderProductSnapshot resources){
+    public ResponseEntity<Object> createOrderProductSnapshot(@Validated @RequestBody OrderProductSnapshot resources) {
         orderProductSnapshotService.create(resources);
         return new ResponseEntity<>(HttpStatus.CREATED);
     }
@@ -57,7 +60,7 @@
     @Log("修改订单商品快照")
     @ApiOperation("修改订单商品快照")
     @PreAuthorize("@el.check('orderProductSnapshot:edit')")
-    public ResponseEntity<Object> updateOrderProductSnapshot(@Validated @RequestBody OrderProductSnapshot resources){
+    public ResponseEntity<Object> updateOrderProductSnapshot(@Validated @RequestBody OrderProductSnapshot resources) {
         orderProductSnapshotService.update(resources);
         return new ResponseEntity<>(HttpStatus.NO_CONTENT);
     }

--
Gitblit v1.9.3