|
|
|
@ -111,7 +111,6 @@ public class CzOrderController { |
|
|
|
|
|
|
|
|
|
OutRechargeOrder order = outRechargeOrderService.findByOrderId(orderId); |
|
|
|
|
|
|
|
|
|
HighRefundAudit highRefundAudit = highRefundAuditService.findByOrderNo(order.getOrderNo()); |
|
|
|
|
|
|
|
|
|
// 订单状态 : 1.待支付 2.已支付 3.已完成 4.已取消 5.已退款 6:退款中
|
|
|
|
|
if (order.getStatus() != 2) { |
|
|
|
@ -144,8 +143,6 @@ public class CzOrderController { |
|
|
|
|
order.setRefundId(orderRefundModel.getRefund_id()); |
|
|
|
|
order.setRefundFee(new BigDecimal(orderRefundModel.getRefund_fee()).divide(new BigDecimal("100"))); |
|
|
|
|
outRechargeOrderService.updateOrder(order); |
|
|
|
|
highRefundAudit.setStatus(1); |
|
|
|
|
highRefundAuditService.updateRefundAudit(highRefundAudit); |
|
|
|
|
} else { |
|
|
|
|
log.error("orderToPay error!", "退款失败"); |
|
|
|
|
throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "退款失败!错误代码:"+orderRefundModel.getErr_code()+",错误描述"+orderRefundModel.getErr_code_des()); |
|
|
|
@ -169,9 +166,6 @@ public class CzOrderController { |
|
|
|
|
order.setOutRefundNo("HFR"+new Date().getTime() ); |
|
|
|
|
order.setRefundFee(order.getPayRealPrice()); |
|
|
|
|
order.setRefundId(dataObject.getString("orderId")); |
|
|
|
|
|
|
|
|
|
highRefundAudit.setStatus(1); |
|
|
|
|
highRefundAuditService.updateRefundAudit(highRefundAudit); |
|
|
|
|
outRechargeOrderService.updateOrder(order); |
|
|
|
|
|
|
|
|
|
} else { |
|
|
|
@ -192,8 +186,6 @@ public class CzOrderController { |
|
|
|
|
order.setRefundTime(new Date()); |
|
|
|
|
order.setOutRefundNo(refund.getString("oriwtorderid")); |
|
|
|
|
order.setRefundFee(order.getPayRealPrice()); |
|
|
|
|
highRefundAudit.setStatus(1); |
|
|
|
|
highRefundAuditService.updateRefundAudit(highRefundAudit); |
|
|
|
|
outRechargeOrderService.updateOrder(order); |
|
|
|
|
} |
|
|
|
|
return true; |
|
|
|
|