| | |
| | | order.setRealPayAmount(meditation.getGeneralPrice()); |
| | | this.updateById(order); |
| | | return clientPlaceOrderVO; |
| | | }else{ |
| | | // 余额抵扣不完 |
| | | OrderPaymentRecord one = orderPaymentRecordService.lambdaQuery().eq(OrderPaymentRecord::getPaymentType, 4) |
| | | .eq(OrderPaymentRecord::getOrderId, orderId9).one(); |
| | | if (one!=null){ |
| | | one.setPayAmount(meditation.getGeneralPrice().subtract(needPayAmount)); |
| | | orderPaymentRecordService.updateById(one); |
| | | } |
| | | } |
| | | if (payType==1){ |
| | | // 微信+余额 |
| | |
| | | order.setRealPayAmount(course.getGeneralPrice()); |
| | | this.updateById(order); |
| | | return clientPlaceOrderVO; |
| | | }else{ |
| | | // 余额抵扣不完 |
| | | OrderPaymentRecord one = orderPaymentRecordService.lambdaQuery().eq(OrderPaymentRecord::getPaymentType, 4) |
| | | .eq(OrderPaymentRecord::getOrderId, orderId8).one(); |
| | | if (one!=null){ |
| | | one.setPayAmount(course.getGeneralPrice().subtract(needPayAmount)); |
| | | orderPaymentRecordService.updateById(one); |
| | | } |
| | | } |
| | | if (payType==1){ |
| | | // 微信+余额 |
| | |
| | | // 支付宝+余额 |
| | | order.setPayType(6); |
| | | } |
| | | this.updateById(order); |
| | | // 创建支付订单 |
| | | createPayment(payType, orderNo, needPayAmount, courseTitle, description, |
| | | wxOpenId, orderId8, clientPlaceOrderVO); |
| | |
| | | // 调用第三方支付获取支付信息 |
| | | JSONObject payInfo = JuHeFuUtil.createPayment1(orderNo, payType, |
| | | needPayAmount.toString(), goodsTitle, goodsDesc, |
| | | IpUtils.getIpAddr(), wxOpenId, "https://xq.xqzhihui.com/api/order/client/order/order/base/callback"); |
| | | IpUtils.getIpAddr(), wxOpenId, "https://v7ro848ar5jx.ngrok.xiaomiqiu123.top/order/client/order/order/base/callback"); |
| | | // 第三方支付记录 |
| | | OrderPaymentRecord paymentRecord = new OrderPaymentRecord(); |
| | | paymentRecord.setOrderId(orderId); |
| | |
| | | // 调用第三方支付获取支付信息 |
| | | JSONObject payInfo = JuHeFuUtil.createPayment(orderNo, payType, |
| | | needPayAmount.toString(), goodsTitle, goodsDesc, |
| | | IpUtils.getIpAddr(), wxOpenId, "https://xq.xqzhihui.com/api/order/client/order/order/base/callback"); |
| | | IpUtils.getIpAddr(), wxOpenId, "https://v7ro848ar5jx.ngrok.xiaomiqiu123.top/order/client/order/order/base/callback"); |
| | | // 第三方支付记录 |
| | | OrderPaymentRecord paymentRecord = new OrderPaymentRecord(); |
| | | paymentRecord.setOrderId(orderId); |