|
|
@@ -372,7 +372,6 @@ public class ReceivableServiceImpl extends ServiceImpl<ReceivableMapper, InsPlyI
|
|
|
if("为空".equals(type)|| "不为空".equals(type)){
|
|
|
return true;
|
|
|
}
|
|
|
- // 如果填写的查询条件,不完善,则该条件不进行过滤
|
|
|
if(StrUtil.isEmpty(search)){
|
|
|
return true;
|
|
|
}
|
|
|
@@ -382,15 +381,98 @@ public class ReceivableServiceImpl extends ServiceImpl<ReceivableMapper, InsPlyI
|
|
|
}
|
|
|
if("不等于".equalsIgnoreCase(type) || "不包含".equalsIgnoreCase(type)){
|
|
|
List<String> signYears = Arrays.asList(search.split(","));
|
|
|
- return !signYears.contains(insPlyIncome.getSigningTime());
|
|
|
+ return !signYears.contains(insPlyIncome.getSignYear()); // 修复这里
|
|
|
+ }
|
|
|
+ return true;
|
|
|
+ };
|
|
|
+
|
|
|
+ // 车牌号 licenseNo
|
|
|
+ Predicate<InsPlyIncome> licenseNoPredicate = insPlyIncome -> {
|
|
|
+ if(!names.contains(IncomeDataVO.SearchVO.licenseNo)){
|
|
|
+ return true;
|
|
|
+ }
|
|
|
+ IncomeDataVO.SearchVO searchVO = searchVOMap.get(IncomeDataVO.SearchVO.licenseNo);
|
|
|
+ String type = searchVO.getType();
|
|
|
+ String search = searchVO.getSearch();
|
|
|
+ if("为空".equals(type)|| "不为空".equals(type)){
|
|
|
+ return true;
|
|
|
+ }
|
|
|
+ if(StrUtil.isEmpty(search)){
|
|
|
+ return true;
|
|
|
+ }
|
|
|
+ if("等于".equalsIgnoreCase(type) || "包含".equalsIgnoreCase(type)){
|
|
|
+ List<String> licenseNos = Arrays.asList(search.split(","));
|
|
|
+ return licenseNos.contains(insPlyIncome.getLicenseNo());
|
|
|
+ }
|
|
|
+ if("不等于".equalsIgnoreCase(type) || "不包含".equalsIgnoreCase(type)){
|
|
|
+ List<String> licenseNos = Arrays.asList(search.split(","));
|
|
|
+ return !licenseNos.contains(insPlyIncome.getLicenseNo());
|
|
|
+ }
|
|
|
+ return true;
|
|
|
+ };
|
|
|
+
|
|
|
+
|
|
|
+ // 交强险保单号 jqPolicyNo
|
|
|
+ Predicate<InsPlyIncome> jqPolicyNoPredicate = insPlyIncome -> {
|
|
|
+ if(!names.contains(IncomeDataVO.SearchVO.jqPolicyNo)){
|
|
|
+ return true;
|
|
|
+ }
|
|
|
+ IncomeDataVO.SearchVO searchVO = searchVOMap.get(IncomeDataVO.SearchVO.jqPolicyNo);
|
|
|
+ String type = searchVO.getType();
|
|
|
+ String search = searchVO.getSearch();
|
|
|
+ if("为空".equals(type)|| "不为空".equals(type)){
|
|
|
+ return true;
|
|
|
+ }
|
|
|
+ if(StrUtil.isEmpty(search)){
|
|
|
+ return true;
|
|
|
+ }
|
|
|
+ if("等于".equalsIgnoreCase(type) || "包含".equalsIgnoreCase(type)){
|
|
|
+ List<String> jqPolicyNos = Arrays.asList(search.split(","));
|
|
|
+ return jqPolicyNos.contains(insPlyIncome.getJqPolicyNo());
|
|
|
+ }
|
|
|
+ if("不等于".equalsIgnoreCase(type) || "不包含".equalsIgnoreCase(type)){
|
|
|
+ List<String> jqPolicyNos = Arrays.asList(search.split(","));
|
|
|
+ return !jqPolicyNos.contains(insPlyIncome.getJqPolicyNo());
|
|
|
+ }
|
|
|
+ return true;
|
|
|
+ };
|
|
|
+
|
|
|
+
|
|
|
+ // 商业险保单号 syPolicyNo
|
|
|
+ Predicate<InsPlyIncome> syPolicyNoPredicate = insPlyIncome -> {
|
|
|
+ if(!names.contains(IncomeDataVO.SearchVO.syPolicyNo)){
|
|
|
+ return true;
|
|
|
+ }
|
|
|
+ IncomeDataVO.SearchVO searchVO = searchVOMap.get(IncomeDataVO.SearchVO.syPolicyNo);
|
|
|
+ String type = searchVO.getType();
|
|
|
+ String search = searchVO.getSearch();
|
|
|
+ if("为空".equals(type)|| "不为空".equals(type)){
|
|
|
+ return true;
|
|
|
+ }
|
|
|
+ if(StrUtil.isEmpty(search)){
|
|
|
+ return true;
|
|
|
+ }
|
|
|
+ if("等于".equalsIgnoreCase(type) || "包含".equalsIgnoreCase(type)){
|
|
|
+ List<String> syPolicyNos = Arrays.asList(search.split(","));
|
|
|
+ return syPolicyNos.contains(insPlyIncome.getSyPolicyNo());
|
|
|
+ }
|
|
|
+ if("不等于".equalsIgnoreCase(type) || "不包含".equalsIgnoreCase(type)){
|
|
|
+ List<String> syPolicyNos = Arrays.asList(search.split(","));
|
|
|
+ return !syPolicyNos.contains(insPlyIncome.getSyPolicyNo());
|
|
|
}
|
|
|
return true;
|
|
|
};
|
|
|
+
|
|
|
+
|
|
|
if("and".equalsIgnoreCase(incomeDataVO.getLogicJudge())){
|
|
|
- Predicate<InsPlyIncome> and = companyIdPredicate.and(signDatePredicate).and(ptlAgreementPredicate).and(orderTypePredicate).and(signYearPredicate);
|
|
|
+ Predicate<InsPlyIncome> and = companyIdPredicate.and(signDatePredicate).
|
|
|
+ and(ptlAgreementPredicate).and(orderTypePredicate).and(signYearPredicate).and(licenseNoPredicate)
|
|
|
+ .and(jqPolicyNoPredicate).and(syPolicyNoPredicate);
|
|
|
filterIncomes = incomes.stream().filter(and).toList();
|
|
|
}else if ("or".equalsIgnoreCase(incomeDataVO.getLogicJudge())){
|
|
|
- Predicate<InsPlyIncome> or = companyIdPredicate.or(signDatePredicate).or(ptlAgreementPredicate).or(orderTypePredicate).or(signYearPredicate);
|
|
|
+ Predicate<InsPlyIncome> or = companyIdPredicate.or(signDatePredicate).
|
|
|
+ or(ptlAgreementPredicate).or(orderTypePredicate).or(signYearPredicate).or(licenseNoPredicate)
|
|
|
+ .or(jqPolicyNoPredicate).or(syPolicyNoPredicate);
|
|
|
filterIncomes = incomes.stream().filter(or).toList();
|
|
|
}
|
|
|
}
|