This commit is contained in:
2026-09-09 13:41:24 +08:00
parent 748855793d
commit 90a2eda86a
8 changed files with 114 additions and 5 deletions
@@ -51,6 +51,24 @@ public class DeliveryTransferController {
return ApiResponse.success(service.oneClickCandidates(requiredCustomer(user, customerId), warehouseId));
}
@GetMapping("/outbound-orders/return/candidates")
@PreAuthorize("hasAuthority('" + OverseasPermissions.OUTBOUND_CREATE + "')")
@Operation(summary = "List available return cartons for outbound")
public ApiResponse<java.util.List<DeliveryResponses.ReturnOutboundCandidate>> returnOutboundCandidates(
@AuthenticationPrincipal AuthenticatedUser user, @RequestParam String customerId,
@RequestParam String warehouseId) {
return ApiResponse.success(service.returnOutboundCandidates(requiredCustomer(user, customerId), warehouseId));
}
@PostMapping("/outbound-orders/return")
@PreAuthorize("hasAuthority('" + OverseasPermissions.OUTBOUND_CREATE + "')")
@Operation(summary = "Create return outbound by carton marks and push PDA task")
public ApiResponse<DeliveryResponses.PdaTask> createReturnOutbound(
@AuthenticationPrincipal AuthenticatedUser user, @RequestParam String customerId,
@Valid @RequestBody DeliveryRequests.ReturnOutbound request) {
return ApiResponse.success(service.createReturnOutbound(requiredCustomer(user, customerId), operator(user), request));
}
@GetMapping("/outbound-orders")
@PreAuthorize("hasAuthority('" + OverseasPermissions.OUTBOUND_LIST + "')")
public ApiResponse<PageResult<DeliveryResponses.OutboundRow>> outboundPage(