From ea26c842829ef69be20ef86d6a546f45c6c5a258 Mon Sep 17 00:00:00 2001
From: xin <1099200748@qq.com>
Date: Thu, 04 Sep 2025 15:31:57 +0800
Subject: [PATCH] Merge branch 'pxb' into xin
---
oying-system/src/main/java/com/oying/modules/rider/rest/WxRiderController.java | 21 +++++++++++++--------
1 files changed, 13 insertions(+), 8 deletions(-)
diff --git a/oying-system/src/main/java/com/oying/modules/rider/rest/WxRiderController.java b/oying-system/src/main/java/com/oying/modules/rider/rest/WxRiderController.java
index 6b046a1..9fe5d74 100644
--- a/oying-system/src/main/java/com/oying/modules/rider/rest/WxRiderController.java
+++ b/oying-system/src/main/java/com/oying/modules/rider/rest/WxRiderController.java
@@ -1,6 +1,8 @@
package com.oying.modules.rider.rest;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.oying.domain.BucketStorage;
+import com.oying.exception.BadRequestException;
import com.oying.modules.rider.domain.*;
import com.oying.modules.rider.domain.dto.RiderIncomeDetailQueryCriteria;
import com.oying.modules.rider.domain.dto.RiderOrderRecordQueryCriteria;
@@ -9,6 +11,8 @@
import com.oying.modules.rider.domain.vo.OrderRiderOperationVo;
import com.oying.modules.rider.service.*;
import com.oying.modules.rider.utils.Constants;
+import com.oying.service.BucketStorageService;
+import com.oying.utils.FileUtil;
import com.oying.utils.PageResult;
import com.oying.utils.R;
import com.oying.utils.StringUtils;
@@ -18,6 +22,7 @@
import org.springframework.http.ResponseEntity;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.*;
+import org.springframework.web.multipart.MultipartFile;
/**
@@ -101,7 +106,7 @@
public ResponseEntity<?> riderGrabOrder(@PathVariable String orderNum) {
// 订单号不能为空
if (StringUtils.isBlank(orderNum)) {
- return ResponseEntity.ok(R.fail(Constants.HTTP_CODE_FAIL, "订单号不能为空"));
+ throw new BadRequestException("订单号不能为空");
}
R result = riderOrderRecordService.riderGrabOrder(orderNum);
return ResponseEntity.ok(result);
@@ -113,7 +118,7 @@
public ResponseEntity<?> riderCancelOrder(@PathVariable String orderNum) {
// 订单号不能为空
if (StringUtils.isBlank(orderNum)) {
- return ResponseEntity.ok(R.fail(Constants.HTTP_CODE_FAIL, "订单号不能为空"));
+ throw new BadRequestException("订单号不能为空");
}
R result = riderOrderRecordService.riderCancelOrder(orderNum);
return ResponseEntity.ok(R.success(result));
@@ -125,7 +130,7 @@
public ResponseEntity<?> riderCompleteOrder(@PathVariable String orderNum) {
// 订单号不能为空
if (StringUtils.isBlank(orderNum)) {
- return ResponseEntity.ok(R.fail(Constants.HTTP_CODE_FAIL, "订单号不能为空"));
+ throw new BadRequestException("订单号不能为空");
}
R result = riderOrderRecordService.riderCompleteOrder(orderNum);
return ResponseEntity.ok(R.success(result));
@@ -137,21 +142,21 @@
public ResponseEntity<?> riderOperationOrder(@RequestBody OrderRiderOperationVo orderRiderOperationVo) {
// 订单号不能为空
if (StringUtils.isBlank(orderRiderOperationVo.getOrderNum())) {
- return ResponseEntity.ok(R.fail(Constants.HTTP_CODE_FAIL, "订单号不能为空"));
+ throw new BadRequestException("订单号不能为空");
}
R result = riderOrderRecordService.riderOperationOrder(orderRiderOperationVo);
return ResponseEntity.ok(R.success(result));
}
@PostMapping("riderDeliveryPhotos")
- @ApiOperation("骑手上传图片记录")
+ @ApiOperation("骑手上传图片")
// @PreAuthorize("@el.check('riderOrderRecord:list')")
- public ResponseEntity<?> riderDeliveryPhotos(@RequestBody OrderDeliveryPhotosVo orderDeliveryPhotosVo) {
+ public ResponseEntity<?> riderDeliveryPhotos(OrderDeliveryPhotosVo orderDeliveryPhotosVo) {
// 订单号不能为空
if (StringUtils.isBlank(orderDeliveryPhotosVo.getOrderNum())) {
- return ResponseEntity.ok(R.fail(Constants.HTTP_CODE_FAIL, "订单号不能为空"));
+ throw new BadRequestException("订单号不能为空");
}
- Boolean result = riderDeliveryPhotosService.riderDeliveryPhotos(orderDeliveryPhotosVo);
+ RiderDeliveryPhotos result = riderDeliveryPhotosService.riderDeliveryPhotos(orderDeliveryPhotosVo);
return ResponseEntity.ok(R.success(result));
}
--
Gitblit v1.9.3