|
@@ -179,6 +179,8 @@ public class PayServiceImpl implements PayService {
|
|
|
BigDecimal subBalance = BigDecimal.ZERO;
|
|
|
|
|
|
BigDecimal subCashAmount = BigDecimal.ZERO;
|
|
|
+
|
|
|
+ RouteScaleDto routeScaleDtoForGoodsSell = null;
|
|
|
//忽略的分部
|
|
|
List<Integer> ignoreOrganList = Arrays.asList(4, 55, 59);
|
|
|
|
|
@@ -345,6 +347,15 @@ public class PayServiceImpl implements PayService {
|
|
|
studentPaymentRouteOrder.setCreateTime(date);
|
|
|
studentPaymentRouteOrder.setUpdateTime(date);
|
|
|
studentPaymentRouteOrderDao.insert(studentPaymentRouteOrder);
|
|
|
+
|
|
|
+
|
|
|
+ routeScaleDtoForGoodsSell = new RouteScaleDto();
|
|
|
+ routeScaleDtoForGoodsSell.setAmount(subCashAmount);
|
|
|
+ routeScaleDtoForGoodsSell.setOrganId(sysPaymentConfig.getOrganId());
|
|
|
+ routeScaleDtoForGoodsSell.setPayType(PaymentChannelEnum.ADAPAY);
|
|
|
+ routeScaleDtoForGoodsSell.setScale(100);
|
|
|
+ routeScaleDtoForGoodsSell.setMerNo(goodsSellReceiptMerNo);
|
|
|
+ routeScaleDtoForGoodsSell.setFeeFlag("Y");
|
|
|
}
|
|
|
}
|
|
|
}
|
|
@@ -381,6 +392,10 @@ public class PayServiceImpl implements PayService {
|
|
|
for (RouteScaleDto routeScaleDto : routeScaleDtos) {
|
|
|
checkMaxReceipt(routeScaleDto, routeScaleDto.getMerNo());
|
|
|
}
|
|
|
+
|
|
|
+ if(routeScaleDtoForGoodsSell != null){
|
|
|
+ routeScaleDtos.add(routeScaleDtoForGoodsSell);
|
|
|
+ }
|
|
|
|
|
|
return getPayRoute(amount, balanceAmount, orderNo, notifyUrl, returnUrl, orderSubject, orderBody, routeScaleDtos, subCashAmount);
|
|
|
}
|
|
@@ -732,8 +747,10 @@ public class PayServiceImpl implements PayService {
|
|
|
routingMerNoSet.add(routeScaleDto.getMerNo());
|
|
|
}
|
|
|
|
|
|
- if (studentPaymentRouteOrderDao.batchAdd(RouteOrders) <= 0) {
|
|
|
- throw new BizException("调用支付接口失败");
|
|
|
+ if(RouteOrders.size() > 0) {
|
|
|
+ if (studentPaymentRouteOrderDao.batchAdd(RouteOrders) <= 0) {
|
|
|
+ throw new BizException("调用支付接口失败");
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
if (payType.equals(PaymentChannelEnum.YQPAY)) {
|