Просмотр исходного кода

调整泰康初始化接口警告信息判断条件

wangrq 1 месяц назад
Родитель
Сommit
1cfd157575

+ 3 - 2
tenant/insurance/quotation-taikang/src/main/java/com/jzg/quotation/taikang/crawler/build/TkCrawlerQuoteResultsBuild.java

@@ -65,10 +65,11 @@ public class TkCrawlerQuoteResultsBuild {
             errorMessage = ((List<?>) other.getMessageBZ()).get(0) + "\n" + ((List<?>) other.getMessageBZ()).get(1);
         } else
 
-        // 初始化有提示跳过,应该属于警告信息(目前只遇到选择的三者险是300万,初始化依然提示:规则管控提示$商业三者险保额请选择300万以上),后续看是否有其他情况影响报价,如果出现其他情况,对这个提示单独处理放行
+        // 报价阶段:与Python代码一致,只在quoteFlag=='quote'(保司要求继续报价/规则管控)或premium为空(未返回保费)时才判失败
+        // 其他情况下的notice(如"规则管控提示$车损不符合政策")属于警告信息,不影响报价成功
         if (!initFlag && preciseInitResult.getPremium() == null) {
             errorMessage = other.getNotice();
-        } else if (!initFlag && other.getNotice() != null && !other.getNotice().isEmpty()) {
+        } else if (!initFlag && preciseInitResult.getFlag() != null && "quote".equals(preciseInitResult.getFlag().getQuoteFlag())) {
             errorMessage = other.getNotice();
         }
 

+ 5 - 4
tenant/insurance/quotation-taikang/src/main/java/com/jzg/quotation/taikang/crawler/service/TKSimpleService.java

@@ -1046,14 +1046,15 @@ public class TKSimpleService {
                 .forEach(commonBiKindInfoVo -> {
                     TKCiKindsVo tkCiKindVo = tkCiKindsVoMap.get(commonBiKindInfoVo.getKindCode());
                     tkCiKindVo.setIsSelect("1");
-                    String quantity = commonBiKindInfoVo.getQuantity();
-                    if (StringUtils.isNotBlank(quantity)) {
-                        tkCiKindVo.setQuantity(Integer.parseInt(quantity));
-                    }
                     // 机动车损失险(101)的金额由保司系统返回,前端传的值不准确,使用保司已有的金额,无需覆盖
                     if (KIND_CODE_VEHICLE_DAMAGE.equals(commonBiKindInfoVo.getKindCode())) {
+                        tkCiKindVo.setQuoteAmountCN(ConvertUtil.simpleConvert(tkCiKindVo.getQuoteAmount().toString()));
                         return;
                     }
+                    String quantity = commonBiKindInfoVo.getQuantity();
+                    if (StringUtils.isNotBlank(quantity)) {
+                        tkCiKindVo.setQuantity(Integer.parseInt(quantity));
+                    }
                     String amount = commonBiKindInfoVo.getAmount();
                     if (StringUtils.isBlank(amount)) {
                         log.warn("商业险险种[{}]金额为空,跳过金额设置", commonBiKindInfoVo.getKindCode());