提交 d0de1b2b authored 作者: liuhaiquan's avatar liuhaiquan

Merge remote-tracking branch 'origin/v10.7_borrowing_and_repayment_20240118'…

Merge remote-tracking branch 'origin/v10.7_borrowing_and_repayment_20240118' into v10.7_borrowing_and_repayment_20240118
......@@ -51,8 +51,8 @@ public class CarrierOwnerLoanRecordController {
@ApiOperation(value = "借款提交申请(调用宁波银行)",notes = "<br>By:胡宇帆")
@PostMapping("/ownerLoanRecordSubmitNbBank")
public Result<Object> ownerLoanRecordSubmitNbBank(@RequestBody @Validated CarrierOwnerLoanRecordApproveParam param) {
ownerLoanRecordService.ownerLoanRecordSubmitNbBank(param);
return Result.ok();
Integer id = ownerLoanRecordService.ownerLoanRecordSubmitNbBank(param);
return Result.ok(id);
}
@ApiOperation(value = "借款重新支付(只更改借款状态)",notes = "<br>By:胡宇帆")
......
......@@ -42,7 +42,6 @@ public class OwnerLoanAccountController {
return Result.ok();
}
@ApiOperation(value = "货主借款申请",notes = "<br>By:胡宇帆")
@PostMapping("/ownerLoanRecordSubmit")
@UnitCovert(result = false)
......@@ -51,8 +50,6 @@ public class OwnerLoanAccountController {
return Result.ok();
}
@ApiOperation(value = "货主借款账户信息",notes = "<br>By:刘海泉")
@GetMapping("/getOwnerLoanAccount")
@UnitCovert(param = false)
......@@ -62,7 +59,7 @@ public class OwnerLoanAccountController {
}
@ApiOperation(value = "货主还款",notes = "<br>By:胡宇帆")
@GetMapping("/ownerRepayment")
@PostMapping("/ownerRepayment")
public Result<OwnerAccountVO> ownerRepayment(@RequestBody OwnerRepaymentParam param) {
ownerLoanAccountService.ownerRepayment(param);
return Result.ok();
......@@ -70,8 +67,8 @@ public class OwnerLoanAccountController {
@ApiOperation(value = "取消支付(还款)",notes = "<br>By:胡宇帆")
@GetMapping("/ownerRepaymentCancelPay")
public Result<Object> ownerLoanRecordCancelPay(@RequestParam(value = "repaymentNo") @NotBlank String repaymentNo) {
ownerRepaymentService.ownerLoanRecordCancelPay(repaymentNo);
public Result<Object> ownerRepaymentCancelPay(@RequestParam(value = "repaymentNo") @NotBlank String repaymentNo) {
ownerRepaymentService.ownerRepaymentCancelPay(repaymentNo);
return Result.ok();
}
......
......@@ -513,7 +513,6 @@ public class OwnerLoanRecordServiceImpl implements OwnerLoanRecordService {
ownerLoanRecord.getLoanBalance().intValue(), borrower.getOpenBankId(), borrower.getBankCardNo(), borrower.getName());
ownerLoanRecord.setRunningWaterOpenNo(orderPayResultVO.getTransSeqNo());
ownerLoanRecord.setMerchantRunningWaterNo(orderPayResultVO.getMerSeqNo());
ownerLoanRecord.setRemittanceIdentificationCode(null);
ownerLoanRecord.setStatus(OwnerLoanRecordEnum.Status.PAYING.getCode());
ownerLoanRecord.setLoanResidueBalance(ownerLoanRecord.getLoanBalance());
......@@ -785,7 +784,7 @@ public class OwnerLoanRecordServiceImpl implements OwnerLoanRecordService {
}
@Override
public void ownerLoanRecordSubmitNbBank(CarrierOwnerLoanRecordApproveParam param) {
public Integer ownerLoanRecordSubmitNbBank(CarrierOwnerLoanRecordApproveParam param) {
OwnerLoanRecord ownerLoanRecord = ownerLoanRecordDao.getOneByField(OwnerLoanRecord::getLoanNo, param.getLoanNo()).get();
if (!OwnerLoanRecordEnum.Status.PAY_WAIT.getCode().equals(ownerLoanRecord.getStatus())) {
throw new ServiceSystemException(PerformanceResultEnum.OWNER_LOAN_RECORD_PAY_WAIT_ERROR);
......@@ -795,6 +794,7 @@ public class OwnerLoanRecordServiceImpl implements OwnerLoanRecordService {
Borrower borrower = borrowerDao.getEntityByKey(ownerLoanRecord.getBorrowerId())
.orElseThrow(PerformanceResultEnum.DATA_NOT_FIND);
fundPayProcess(param, ownerLoanRecord, borrower);
return ownerLoanRecord.getId();
}
}
......@@ -223,12 +223,11 @@ public class OwnerRepaymentServiceImpl implements OwnerRepaymentService {
@Override
@Transactional(rollbackFor = Exception.class)
public void ownerLoanRecordCancelPay(String repaymentNo) {
public void ownerRepaymentCancelPay(String repaymentNo) {
OwnerRepayment ownerRepayment = ownerRepaymentDao.getOneByField(OwnerRepayment::getRepaymentNo, repaymentNo)
.orElseThrow(PerformanceResultEnum.DATA_NOT_FIND);
if (ownerRepayment.getStatus().equals(OwnerRePaymentEnum.Status.PAY_SUCCESS.getCode()))
{
log.info("还款记录状态异常,不能取消");
if (!ownerRepayment.getStatus().equals(OwnerRePaymentEnum.Status.PAYING.getCode())) {
log.info("还款记录状态异常,不是付款中,不能取消");
throw new ServiceSystemException(PerformanceResultEnum.OWNER_LOAN_RECORD_CANCEL_STATUS_ERROR);
}
BankTrade bankTrade = bankTradeDao.selectByRelationNo(repaymentNo).get();
......
......@@ -54,7 +54,7 @@ public interface OwnerLoanRecordService {
String sendOrderPaySms(String mobile,String payee, String payeeAccount);
void ownerLoanRecordSubmitNbBank(CarrierOwnerLoanRecordApproveParam param);
Integer ownerLoanRecordSubmitNbBank(CarrierOwnerLoanRecordApproveParam param);
void orderChildLoanProcess(Long ownerUserNo);
}
......@@ -33,7 +33,7 @@ public interface OwnerRepaymentService {
String sendPaymentSms(String mobile,Long repaymentNo);
String sendOrderPaySms(String mobile,String payee, String payeeAccount);
void ownerLoanRecordCancelPay(String repaymentNo);
void ownerRepaymentCancelPay(String repaymentNo);
void ownerRepaymentRetryPay(String repaymentNo);
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论