update 运营商手动分账接口

This commit is contained in:
2023-07-29 15:03:43 +08:00
parent 4f071a3718
commit 37612f4c37
2 changed files with 31 additions and 0 deletions

View File

@@ -180,4 +180,33 @@ public class TempController extends BaseController {
logger.info("临时接口交易确认接口 result:{}", response);
return response;
}
/**
* 运营商分账手动接口
* @return
*/
@PostMapping("/orderSplittingOperations")
public RestApiResponse<?> orderSplittingOperations(@RequestBody QueryOrderDTO dto) {
RestApiResponse<?> response = null;
try {
String startTime = dto.getStartTime();
String endTime = dto.getEndTime();
// 获取日期区间内所有日期
List<String> dateList = DateUtils.getAllDatesInTheDateRange(startTime, endTime);
for (String tradeDate : dateList) {
orderBasicInfoService.orderSplittingOperations(dto.getMerchantId(), tradeDate);
}
response = new RestApiResponse<>();
} catch (BusinessException e) {
logger.warn("运营商分账手动接口warn", e);
response = new RestApiResponse<>(e.getCode(), e.getMessage());
} catch (Exception e) {
logger.error("运营商分账手动接口error", e);
response = new RestApiResponse<>(ReturnCodeEnum.CODE_WEIXIN_REFUND_ERROR);
}
logger.info("运营商分账手动接口result:{}", JSONObject.toJSONString(response));
return response;
}
}