修正退款问题

This commit is contained in:
wucongxing 2023-04-11 18:09:42 +08:00
parent 532c9f909f
commit 33078cf973

View File

@ -223,7 +223,7 @@ class OrderProductService extends BaseService
}
// 检测支付状态
if ($order_product['pay_status'] != 5){
if ($order_product['pay_status'] != 2){
// 支付状态1:未支付 2:已支付 3:支付中 4:支付失败 5:支付超时 6:支付关闭 7:已撤销 8:转入退款)
throw new BusinessException("订单支付状态错误,无法退款");
}
@ -235,7 +235,7 @@ class OrderProductService extends BaseService
// 检测订单金额
if ($order_product['payment_amount_total'] > 0){
// 发起退款
$WechatPay = new WechatPay(1, 1);
$WechatPay = new WechatPay(1, 2);
$options = array();
$options['transaction_id'] = $order_product['escrow_trade_no'];