a
jiangping
2023-11-07 28a07b5b768096a2c75b55c440b8afd0b50b3f0b
server/services/src/main/java/com/doumee/service/business/impl/WxBillServiceImpl.java
@@ -149,6 +149,7 @@
                } else if(StringUtils.equals(detail.getBillStatus(), "REFUND")){
                    //退款数据
                    bill4.setSumRefundBill(detail.getSumBill());//退款笔数
                    bill4.setSumRefundFee(detail.getRefundFee());
                    bill4.setSumRefundCmmsAmt(Constants.formatDecimalNum(detail.getCmmsAmt()));//退款手续费
                }
            }
@@ -304,10 +305,6 @@
            bill.setSumTotalFee(formatStringToDecimal(response.getTotalAmount()));
            //应结订单总金额
            bill.setSumSuccessFee(formatStringToDecimal(response.getTotalFee()));
            //退款总金额
            bill.setSumRefundFee(formatStringToDecimal(response.getTotalFee()));
            //退款总金额
            bill.setSumApplyRefundFee(formatStringToDecimal(response.getTotalAppliedRefundFee()));
            //交易总手续费金额
            bill.setSumCmmsAmt(formatStringToDecimal(response.getTotalPoundageFee()));
            detailList.addAll(getDetialModelByInfo(bill,response.getBillInfoList()));
@@ -316,8 +313,12 @@
            //退款单总数累计进入
//                bill.setSumBill(bill.getSumBill()+(Integer.parseInt(response.getTotalRecord()));
            bill.setSumRefundBill(Integer.parseInt(responseRefund.getTotalRecord()));//退款的订单数
            //退款总金额
            bill.setSumRefundFee(formatStringToDecimal(responseRefund.getTotalRefundFee()));
            //退款总金额
            bill.setSumApplyRefundFee(formatStringToDecimal(responseRefund.getTotalAppliedRefundFee()));
            bill.setSumRefundCmmsAmt(formatStringToDecimal(responseRefund.getTotalPoundageFee()));//退款总手续费
            bill.setSumCouponRefundFee(formatStringToDecimal(responseRefund.getTotalCouponFee()));//退款总手续费
            bill.setSumCouponRefundFee(formatStringToDecimal(responseRefund.getTotalCouponFee()));//退款总金额
            detailList.addAll(getDetialModelByInfo(bill,responseRefund.getBillInfoList()));
        }
        wxBillMapper.delete(new UpdateWrapper<WxBill>().lambda().eq( WxBill::getId, bill.getId()));
@@ -348,7 +349,8 @@
            //只能同步昨天10之前的数据
            Calendar caln = Calendar.getInstance();
            caln.setTime(ydate);
            if(caln.get(Calendar.HOUR_OF_DAY) <= 9){
//            System.out.println(caln.get(Calendar.HOUR_OF_DAY) );
            if(caln.get(Calendar.HOUR_OF_DAY) >= 10){
                throw  new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"对不起,最近同步时间只能截止到昨天10点前!");
            }
        }