|
@@ -1027,11 +1027,20 @@ public class TKSimpleService {
|
|
|
continue;
|
|
continue;
|
|
|
}
|
|
}
|
|
|
TKCarPlanInfo tkCarPlanInfo = carPlanInfoMap.get(accidentalDriving.getProductCode());
|
|
TKCarPlanInfo tkCarPlanInfo = carPlanInfoMap.get(accidentalDriving.getProductCode());
|
|
|
- driverAccidentVo.setIsSelect("1");
|
|
|
|
|
- driverAccidentVo.setQuantity(accidentalDriving.getQuantity());
|
|
|
|
|
- driverAccidentVo.setSelectPlanCode(tkCarPlanInfo.getPlanCode());
|
|
|
|
|
- driverAccidentVo.setQuoteAmountCN(tkCarPlanInfo.getPlanName());
|
|
|
|
|
- driverAccidentVo.setPremium(new BigDecimal(tkCarPlanInfo.getSumPremium()));
|
|
|
|
|
|
|
+ if (tkCarPlanInfo != null) {
|
|
|
|
|
+ driverAccidentVo.setIsSelect("1");
|
|
|
|
|
+ driverAccidentVo.setQuantity(accidentalDriving.getQuantity());
|
|
|
|
|
+ driverAccidentVo.setSelectPlanCode(tkCarPlanInfo.getPlanCode());
|
|
|
|
|
+ driverAccidentVo.setQuoteAmountCN(tkCarPlanInfo.getPlanName());
|
|
|
|
|
+ driverAccidentVo.setPremium(new BigDecimal(tkCarPlanInfo.getSumPremium()));
|
|
|
|
|
+ } else {
|
|
|
|
|
+ driverAccidentVo.setIsSelect("0");
|
|
|
|
|
+ driverAccidentVo.setQuantity(0);
|
|
|
|
|
+ driverAccidentVo.setQuantityCname("不投保");
|
|
|
|
|
+ driverAccidentVo.setPremium(BigDecimal.ZERO);
|
|
|
|
|
+ driverAccidentVo.setNonCarStartDate(null);
|
|
|
|
|
+ driverAccidentVo.setNonCarEndDate(null);
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
} else {
|
|
} else {
|
|
|
driverAccidentVo.setIsSelect("0");
|
|
driverAccidentVo.setIsSelect("0");
|
|
@@ -1042,9 +1051,39 @@ public class TKSimpleService {
|
|
|
driverAccidentVo.setNonCarEndDate(null);
|
|
driverAccidentVo.setNonCarEndDate(null);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- // 泰乐途, 默认不投保
|
|
|
|
|
|
|
+ // 泰康系统默认的泰乐途
|
|
|
|
|
+ Map<String, PreciseInitResult.ProductInfoListDTO> productInfoListMap = new HashMap<>();
|
|
|
List<PreciseInitResult.NonCarProductListDTO> nonCarProductList = preciseInitParam.getNonCarProductList();
|
|
List<PreciseInitResult.NonCarProductListDTO> nonCarProductList = preciseInitParam.getNonCarProductList();
|
|
|
if (CollectionUtils.isNotEmpty(nonCarProductList)) {
|
|
if (CollectionUtils.isNotEmpty(nonCarProductList)) {
|
|
|
|
|
+ for (PreciseInitResult.NonCarProductListDTO nonCarProductListDTO : nonCarProductList) {
|
|
|
|
|
+ for (PreciseInitResult.ProductInfoListDTO productInfoListDTO : nonCarProductListDTO.getProductInfoList()) {
|
|
|
|
|
+ productInfoListMap.put(productInfoListDTO.getProductCode(), productInfoListDTO);
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ // 泰乐途
|
|
|
|
|
+ if (CollectionUtils.isNotEmpty(accidentalDrivings)) {
|
|
|
|
|
+ for (AccidentalDrivingVo accidentalDriving : accidentalDrivings) {
|
|
|
|
|
+ if (productInfoListMap.isEmpty() || accidentalDriving.getProductCode() == null) {
|
|
|
|
|
+ continue;
|
|
|
|
|
+ }
|
|
|
|
|
+ PreciseInitResult.ProductInfoListDTO productInfoListDTO = productInfoListMap.get(accidentalDriving.getProductCode());
|
|
|
|
|
+ PreciseInitResult.NonCarProductListDTO nonCarProductListDTO = nonCarProductList.get(0);
|
|
|
|
|
+ if (productInfoListDTO != null) {
|
|
|
|
|
+ nonCarProductListDTO.setIsSelect("1");
|
|
|
|
|
+ nonCarProductListDTO.setPremium(productInfoListDTO.getPremium());
|
|
|
|
|
+ nonCarProductListDTO.setSelectProductCode(accidentalDriving.getProductCode());
|
|
|
|
|
+ nonCarProductListDTO.setSelectProductName(productInfoListDTO.getProductName());
|
|
|
|
|
+ nonCarProductListDTO.setStartDate(commonCiRiskInfoVo != null ? commonCiRiskInfoVo.getStartDate() : null);
|
|
|
|
|
+ nonCarProductListDTO.setEndDate(commonCiRiskInfoVo != null ? commonCiRiskInfoVo.getEndDate() : null);
|
|
|
|
|
+ } else {
|
|
|
|
|
+ nonCarProductListDTO.setIsSelect("0");
|
|
|
|
|
+ nonCarProductListDTO.setPremium("0");
|
|
|
|
|
+ nonCarProductListDTO.setStartDate(null);
|
|
|
|
|
+ nonCarProductListDTO.setEndDate(null);
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ } else {
|
|
|
nonCarProductList.forEach(nonCarProductListDTO -> {
|
|
nonCarProductList.forEach(nonCarProductListDTO -> {
|
|
|
nonCarProductListDTO.setIsSelect("0");
|
|
nonCarProductListDTO.setIsSelect("0");
|
|
|
nonCarProductListDTO.setPremium("0");
|
|
nonCarProductListDTO.setPremium("0");
|