소스 검색

1.错误添加比例问题

wuhp 2 년 전
부모
커밋
99ec3622d6
1개의 변경된 파일9개의 추가작업 그리고 9개의 파일을 삭제
  1. 9 9
      src/main/java/com/ydtech/modules/fnc/service/impl/InsPlyIncomeServiceImpl.java

+ 9 - 9
src/main/java/com/ydtech/modules/fnc/service/impl/InsPlyIncomeServiceImpl.java

@@ -831,15 +831,6 @@ handlingProportion,
                             reason="非车应收比例错误!";
                         }
                     }
-                    if (insPlyIncome.getAllFeeValue() != null && insPlyIncome.getAllFeeValue().compareTo(BigDecimal.ZERO) != 0) {
-                        totalAmount = totalAmount.add(insPlyIncome.getAllFeeValue());  //总金额
-                    }
-                    if (insPlyIncome.getCommissionFeevalue() != null && insPlyIncome.getCommissionFeevalue().compareTo(BigDecimal.ZERO) != 0) {
-                        totalHandingAmount = totalHandingAmount.add(insPlyIncome.getCommissionFeevalue());  //总手续费
-                    }
-                    if (insPlyIncome.getOtherFeevalue() != null && insPlyIncome.getOtherFeevalue().compareTo(BigDecimal.ZERO) != 0) {
-                        totalOtherAmount = totalOtherAmount.add(insPlyIncome.getOtherFeevalue());   //总跟单费
-                    }
                     //判断是否是相同保司机构
                     partnerCompaniesIdSet.add(insPlyIncome.getPartnerCompaniesId());
                     if(StringUtils.isNotEmpty(reason)){
@@ -847,6 +838,15 @@ handlingProportion,
                         resultNoSelect.add(objectObjectHashMap);  // 添加未匹配的车牌号
                     }else {
                         ids.add(insPlyIncome.getId());
+                        if (insPlyIncome.getAllFeeValue() != null && insPlyIncome.getAllFeeValue().compareTo(BigDecimal.ZERO) != 0) {
+                            totalAmount = totalAmount.add(insPlyIncome.getAllFeeValue());  //总金额
+                        }
+                        if (insPlyIncome.getCommissionFeevalue() != null && insPlyIncome.getCommissionFeevalue().compareTo(BigDecimal.ZERO) != 0) {
+                            totalHandingAmount = totalHandingAmount.add(insPlyIncome.getCommissionFeevalue());  //总手续费
+                        }
+                        if (insPlyIncome.getOtherFeevalue() != null && insPlyIncome.getOtherFeevalue().compareTo(BigDecimal.ZERO) != 0) {
+                            totalOtherAmount = totalOtherAmount.add(insPlyIncome.getOtherFeevalue());   //总跟单费
+                        }
                     }
                 } else {
                     objectObjectHashMap.put("reason","未查询车辆");