|
|
@@ -8,6 +8,7 @@ import org.springframework.web.bind.annotation.PostMapping;
|
|
|
import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
import org.springframework.web.bind.annotation.RestController;
|
|
|
import shop.alien.entity.result.R;
|
|
|
+import shop.alien.store.service.StoreReservationService;
|
|
|
import shop.alien.store.service.UserReservationService;
|
|
|
|
|
|
/**
|
|
|
@@ -21,6 +22,7 @@ import shop.alien.store.service.UserReservationService;
|
|
|
public class ReservationJobController {
|
|
|
|
|
|
private final UserReservationService userReservationService;
|
|
|
+ private final StoreReservationService storeReservationService;
|
|
|
|
|
|
@ApiOperation("标记「结束时间已过且订单待使用」的预订为未到店超时/已过期")
|
|
|
@PostMapping("/markTimeout")
|
|
|
@@ -39,4 +41,13 @@ public class ReservationJobController {
|
|
|
log.info("reservation job: sendArrivalReminder 结束,发送条数={}", count);
|
|
|
return R.data(count);
|
|
|
}
|
|
|
+
|
|
|
+ @ApiOperation("重试退款:查询支付状态为退款中的订单并重新发起退款(不发送短信和通知)")
|
|
|
+ @PostMapping("/retryRefundFailed")
|
|
|
+ public R<Integer> retryRefundFailed() {
|
|
|
+ log.info("reservation job: retryRefundFailed 开始");
|
|
|
+ int count = storeReservationService.retryRefundFailedOrders();
|
|
|
+ log.info("reservation job: retryRefundFailed 结束,成功退款条数={}", count);
|
|
|
+ return R.data(count);
|
|
|
+ }
|
|
|
}
|