jinshihui 5 месяцев назад
Родитель
Сommit
0985dec435
38 измененных файлов с 3124 добавлено и 570 удалено
  1. 0 1
      commons/src/main/java/com/jzg/commons/core/base/StateResult.java
  2. 0 5
      commons/src/main/java/com/jzg/commons/entity/agreement/po/PtlAgreementAttribution.java
  3. 0 5
      commons/src/main/java/com/jzg/commons/entity/po/EsmInsCompany.java
  4. 18 1
      commons/src/main/java/com/jzg/commons/entity/quote/vo/CarInfoVo.java
  5. 35 0
      commons/src/main/java/com/jzg/commons/entity/quote/vo/CustomerInfoVo.java
  6. 21 0
      commons/src/main/java/com/jzg/commons/entity/quote/vo/KindInfoVo.java
  7. 7 1
      commons/src/main/java/com/jzg/commons/entity/quote/vo/image/InsuranceImageVo.java
  8. 5 1
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/api/constant/enums/ResponseCode.java
  9. 35 30
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/build/BoHaiCrawlerQuoteResultsVoBuild.java
  10. 35 41
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/component/BoHaiCrawlerRequestComponent.java
  11. 5 5
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/BoHaiCrawlerConfigureParameters.java
  12. 3 2
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/po/BoHaiCrawlerOrder.java
  13. 15 1
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/request/BoHaiCrawlerBaseRequest.java
  14. 1 1
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/request/BoHaiCrawlerCarRequest.java
  15. 0 6
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/request/BoHaiCrawlerImageUploadRequestDto.java
  16. 26 0
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/request/BoHaiCrawlerImageUploadSubmitRequest.java
  17. 47 0
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/request/BoHaiCrawlerPaymentCertiNoQueryRequest.java
  18. 406 24
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/request/BoHaiCrawlerQuotationRequest2.java
  19. 297 53
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/request/BoHaiCrawlerUnderwritingRequest2.java
  20. 4 0
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/response/BoHaiCrawlerCarApiResponse.java
  21. 4 0
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/response/BoHaiCrawlerCarResponse.java
  22. 1088 0
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/response/BoHaiCrawlerQuotationResponse2.java
  23. 8 0
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/response/BoHaiCrawlerVehicleConfirmationResponse2.java
  24. 2 3
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/service/BoHaiCrawlerOrderService.java
  25. 37 19
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/service/impl/BoHaiCrawlerOrderServiceImpl.java
  26. 23 2
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/service/impl/BoHaiCrawlerQuoteProcessServiceImpl.java
  27. 862 346
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/service/impl/BoHaiCrawlerRequestImpl.java
  28. 1 1
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/util/BatchNumberGenerator.java
  29. 25 0
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/util/DateTimeUtils.java
  30. 24 0
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/util/OrderNoGenerator.java
  31. 3 9
      tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/util/PythonExecutor.java
  32. 41 4
      tenant/insurance/quotation-commons/src/main/java/com/jzg/quotation/commons/component/RequestComponent.java
  33. 33 0
      tenant/insurance/quotation-commons/src/main/java/com/jzg/quotation/commons/config/MongoConfig.java
  34. 0 2
      tenant/insurance/quotation-summary/src/main/java/com/jzg/quotation/summary/SummaryQuotationApplication.java
  35. 6 3
      tenant/insurance/quotation-summary/src/main/java/com/jzg/quotation/summary/controller/UnifyOrderManager.java
  36. 3 0
      tenant/insurance/quotation-summary/src/main/java/com/jzg/quotation/summary/factory/CompanyFactory.java
  37. 3 1
      tenant/insurance/quotation-summary/src/main/java/com/jzg/quotation/summary/state/OrderState.java
  38. 1 3
      tenant/insurance/quotation-summary/src/main/java/com/jzg/quotation/summary/state/listener/OrderStateListener.java

+ 0 - 1
commons/src/main/java/com/jzg/commons/core/base/StateResult.java

@@ -1,5 +1,4 @@
 package com.jzg.commons.core.base;
-
 import io.swagger.v3.oas.annotations.media.Schema;
 import lombok.Data;
 

+ 0 - 5
commons/src/main/java/com/jzg/commons/entity/agreement/po/PtlAgreementAttribution.java

@@ -1,6 +1,4 @@
 package com.jzg.commons.entity.agreement.po;
-
-
 import com.alibaba.fastjson.JSONArray;
 import com.baomidou.mybatisplus.annotation.TableField;
 import com.baomidou.mybatisplus.annotation.TableId;
@@ -14,13 +12,10 @@ import lombok.AllArgsConstructor;
 import lombok.Data;
 import lombok.EqualsAndHashCode;
 import lombok.NoArgsConstructor;
-
-
 /**
  * @author quchen
  * @date 2025/2/18 11:09
  */
-
 @Data
 @Schema(description = "保险公司归属信息账号")
 @NoArgsConstructor

+ 0 - 5
commons/src/main/java/com/jzg/commons/entity/po/EsmInsCompany.java

@@ -1,16 +1,11 @@
 package com.jzg.commons.entity.po;
-
-
 import com.baomidou.mybatisplus.annotation.IdType;
 import com.baomidou.mybatisplus.annotation.TableField;
 import com.baomidou.mybatisplus.annotation.TableId;
 import com.baomidou.mybatisplus.annotation.TableName;
 import com.jzg.commons.core.base.BaseModel;
 import lombok.Data;
-
 import java.util.List;
-
-
 @TableName(value = "esm_ins_company")
 @Data
 public class EsmInsCompany extends BaseModel {

+ 18 - 1
commons/src/main/java/com/jzg/commons/entity/quote/vo/CarInfoVo.java

@@ -113,6 +113,9 @@ public class CarInfoVo implements Serializable {
     @Schema(description = "车辆用途代码")
     private String vehicleUseCode;
 
+    /**
+     * 车辆用途名称
+     */
     @Schema(description = "车辆用途名称")
     private String vehicleUseName;
 
@@ -129,8 +132,12 @@ public class CarInfoVo implements Serializable {
      */
     private String origModelCde;
 
+    /**
+     * 车辆类型名称
+     */
     @Schema(description = "车辆类型名称")
     private String carTypeName;
+
     /**
      * @see CarKindCode
      * 车辆种类代码
@@ -138,6 +145,9 @@ public class CarInfoVo implements Serializable {
     @Schema(description = "车辆种类代码")
     private String carKindCode;
 
+    /**
+     * 车辆种类名称
+     */
     @Schema(description = "车辆种类名称")
     private String carKindName;
     /**
@@ -201,10 +211,12 @@ public class CarInfoVo implements Serializable {
      */
     @Schema(description = "发证日期")
     private String issueDate;
+
     /**
      * 过户车(如果存在交强险商业险分开的情况是转为交强险过户)
      */
     private boolean transfer;
+
     /**
      * 商业险过户
      */
@@ -222,6 +234,7 @@ public class CarInfoVo implements Serializable {
      */
     @Schema(description = "所属性质")
     private String property;
+
     /**
      * 新能源标志 true 新能源
      */
@@ -244,6 +257,11 @@ public class CarInfoVo implements Serializable {
      */
     private String isAccurate;
 
+    /**
+    * 过户标志
+     */
+    private String chgOwnerFlag;
+
     /**
      * 获取 吨位数/核定载质量
      *
@@ -316,6 +334,5 @@ public class CarInfoVo implements Serializable {
         this.issueDate = carInfo.getIssueDate().format(DateTimeFormatter.ofPattern("yyyy-MM-dd"));
         this.transfer = carInfo.getTransfer() == 1;
         this.biTransfer = carInfo.getTransferBi() == 1;
-
     }
 }

+ 35 - 0
commons/src/main/java/com/jzg/commons/entity/quote/vo/CustomerInfoVo.java

@@ -27,6 +27,9 @@ public class CustomerInfoVo implements Serializable {
     @Serial
     private static final long serialVersionUID = -6294245892491122989L;
 
+    /**
+     * 人员类型 1 个人 2 法人
+     */
     @Schema(description = "人员类型 1 个人 2 法人")
     private String personType;
 
@@ -35,36 +38,43 @@ public class CustomerInfoVo implements Serializable {
      */
     @Schema(description = "姓名")
     private String name;
+
     /**
      * 身份证号
      */
     @Schema(description = "身份证号")
     private String identifyNumber;
+
     /**
      * 生日
      */
     @Schema(description = "生日")
     private String birthday;
+
     /**
      * 年龄
      */
     @Schema(description = "年龄")
     private Integer age;
+
     /**
      * 性别
      */
     @Schema(description = "性别")
     private String gender;
+
     /**
      * 身份证有效起期
      */
     @Schema(description = "身份证有效起期")
     private String identifyValidDate;
+
     /**
      * 身份证有效止期
      */
     @Schema(description = "身份证有效止期")
     private String identifyValidEndDate;
+
     /**
      * 证件类型代码
      */
@@ -82,46 +92,68 @@ public class CustomerInfoVo implements Serializable {
      */
     @Schema(description = "组织机构代码")
     private String organizationCode;
+
     /**
      * 地址
      */
     @Schema(description = "地址")
     private String addr;
+
+    /**
+    * 邮政编码
+     */
+    @Schema(description = "邮政编码")
+    private String postCode;
+
+    /**
+     * 邮寄地址
+     */
+    @Schema(description = "邮寄地址")
+    private String postAddress;
+
+
     /**
      * 省 区划编码
      */
     @Schema(description = "省 区划编码")
     private String provinceCode;
+
     /**
      * 省
      */
     @Schema(description = "省")
     private String province;
+
     /**
      * 市 区划编码
      */
     @Schema(description = "市 区划编码")
     private String cityCode;
+
     /**
      * 市
      */
     @Schema(description = "市")
     private String city;
+
     /**
      * 县 区划编码
      */
     @Schema(description = "县 区划编码")
     private String countyCode;
+
     /**
      * 县
      */
     @Schema(description = "县")
     private String county;
+
     /**
      * 邮箱
      */
     @Schema(description = "邮箱")
     private String email;
+
     /**
      * 手机号
      */
@@ -139,16 +171,19 @@ public class CustomerInfoVo implements Serializable {
      */
     @Schema(description = "客户类型")
     private String property;
+
     /**
      * 法人
      */
     @Schema(description = "法人")
     private String legalPerson;
+
     /**
      * 法人身份证号
      */
     @Schema(description = "法人身份证")
     private String leaderIdentifyNumber;
+
     /**
      * 法人身份证止期
      */

+ 21 - 0
commons/src/main/java/com/jzg/commons/entity/quote/vo/KindInfoVo.java

@@ -33,47 +33,68 @@ public class KindInfoVo implements Serializable {
      */
     @Schema(description = "险种名称")
     private String kindName;
+
     /**
      * 平台险种编码
      */
     @Schema(description = "平台险种编码")
     private String platformKindCode;
+
     /**
      * 平台险种名称
      */
     @Schema(description = "平台险种名称")
     private String platformKindName;
+
+    /**
+     * 保险起期
+     */
+    private String startDate;
+
+    /**
+     * 保险止期
+     */
+    private String endDate;
+
     /**
      * 保额
      */
     @Schema(description = "保额")
     private String amount;
+
     /**
      * 每座保额
      */
     @Schema(description = "每座保额")
     private String unitAmount;
+
     /**
      * 座位数
      */
     @Schema(description = "座位数")
     private String quantity;
+
     /**
      * 保费
      */
     @Schema(description = "保费")
     private String premium;
+
     /**
      * 附加绝对免赔率
      */
     @Schema(description = "附加绝对免赔率")
     private String deductibleRate;
+
     /**
      * 服务次数
      */
     @Schema(description = "服务次数")
     private String serviceTimes;
 
+    public KindInfoVo(String number, String number1, String number2, String number3, String number4, String number5, String number6, String number7, String number8, String number9,String number10) {
+    }
+
     public KindInfoVo(String number, String number1, String number2, String number3, String number4, String number5, String number6, String number7, String number8, String number9) {
     }
 }

+ 7 - 1
commons/src/main/java/com/jzg/commons/entity/quote/vo/image/InsuranceImageVo.java

@@ -24,14 +24,17 @@ public class InsuranceImageVo {
      * 影像编码
      */
     private String imageCode;
+
     /**
      * 影像类型名称
      */
     private String imageType;
+
     /**
      * 保司影像编码
      */
     private String insuranceImageCode;
+
     /**
      * 保司影像类型
      */
@@ -58,21 +61,24 @@ public class InsuranceImageVo {
          * 影像唯一id
          */
         private String imageId;
+
         /**
          * 影像名称
          */
         private String imageName;
+
         /**
          * 影像base64字符串
          */
         private String imageBase64Str;
+
         /**
          * 影像大小
          */
         private String imageSize;
 
         /**
-         * 影像大小
+         * 影像字节数组
          */
         private byte[] imageByte;
     }

+ 5 - 1
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/api/constant/enums/ResponseCode.java

@@ -14,7 +14,11 @@ public enum ResponseCode {
 
     R_Z00001("Z00001", "处理成功"),
     R_Z00002("Z00002", "再次调用此接口确认"),
-    R_Z00004("Z00004", "处理失败");
+    R_Z00004("Z00004", "处理失败"),
+
+    Quotation_Failed("-1", "报价失败"),
+
+    Quotation_Success("0", "报价成功");
 
     private final String code;
 

+ 35 - 30
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/build/BoHaiCrawlerQuoteResultsVoBuild.java

@@ -7,6 +7,7 @@ import com.jzg.commons.entity.quote.vo.RiskInfoVo;
 import com.jzg.commons.entity.quote.vo.aggregated.QuoteResultsVo;
 import com.jzg.quotation.bohai.api.entity.response.QuotationResponse;
 import com.jzg.quotation.bohai.crawler.entity.response.BoHaiCrawlerQuotationResponse;
+import com.jzg.quotation.bohai.crawler.entity.response.BoHaiCrawlerQuotationResponse2;
 
 import java.util.List;
 import java.util.Map;
@@ -20,21 +21,25 @@ import java.util.stream.Collectors;
  **/
 public class BoHaiCrawlerQuoteResultsVoBuild {
 
-    public static QuoteResultsVo buildQuoteResultsVo(String ordersNo, QuoteVo quoteVo, BoHaiCrawlerQuotationResponse boHaiCrawlerQuotationResponse) {
+    /**
+     * 构建报价结果
+     * @param ordersNo
+     * @param quoteVo
+     * @param boHaiCrawlerQuotationResponse
+     * @return QuoteResultsVo
+     */
+    public static QuoteResultsVo buildQuoteResultsVo(String ordersNo, QuoteVo quoteVo, BoHaiCrawlerQuotationResponse2 boHaiCrawlerQuotationResponse) {
         QuoteResultsVo quoteResultsVo = new QuoteResultsVo();
         quoteResultsVo.setOrdersNo(ordersNo);
 
         // 设置交强险信息
-        if (boHaiCrawlerQuotationResponse.getData().getTrafficPolicy() != null) {
+        if (boHaiCrawlerQuotationResponse.getBusinessData().getFeeControlInfoList().get(0)!=null) {
             quoteResultsVo.setCiRiskInfoVo(buildCiRiskInfoVo(boHaiCrawlerQuotationResponse));
         }
 
         // 设置商业险信息
-        if (boHaiCrawlerQuotationResponse.getData().getBusinessPolicy() != null) {
+        if (boHaiCrawlerQuotationResponse.getBusinessData().getFeeControlInfoList().get(1)!=null) {
             quoteResultsVo.setBiRiskInfoVo(buildBiRiskInfoVo(boHaiCrawlerQuotationResponse));
-            // 商业险险种信息
-            List<KindInfoVo> kindInfoVo = buildKindInfoVo(quoteVo.getKindInfoVo(), boHaiCrawlerQuotationResponse.getData().getBusinessPolicy().getCoverages());
-            quoteResultsVo.setKindInfoVo(kindInfoVo);
         }
 
         // 交强保费 车船税 商业保费
@@ -49,25 +54,23 @@ public class BoHaiCrawlerQuoteResultsVoBuild {
      * @param quotationResponse
      * @return RiskInfoVo
      */
-    public static RiskInfoVo buildCiRiskInfoVo(BoHaiCrawlerQuotationResponse quotationResponse) {
-        BoHaiCrawlerQuotationResponse.DataDTO.TrafficPolicyDTO trafficPolicy = quotationResponse.getData().getTrafficPolicy();
+    public static RiskInfoVo buildCiRiskInfoVo(BoHaiCrawlerQuotationResponse2 quotationResponse) {
         RiskInfoVo riskInfoVo = new RiskInfoVo();
-        riskInfoVo.setStartDate(trafficPolicy.getStartDate());
-        riskInfoVo.setEndDate(trafficPolicy.getEndDate());
+        riskInfoVo.setStartDate("");
+        riskInfoVo.setEndDate("");
         return riskInfoVo;
     }
 
     /**
      * 处理商业险数据
      * @param quotationResponse
-     * @return
+     * @return RiskInfoVo
      */
-    public static RiskInfoVo buildBiRiskInfoVo(BoHaiCrawlerQuotationResponse quotationResponse) {
+    public static RiskInfoVo buildBiRiskInfoVo(BoHaiCrawlerQuotationResponse2 quotationResponse) {
         // 获取商业险数据
-        BoHaiCrawlerQuotationResponse.DataDTO.BusinessPolicyDTO businessPolicy = quotationResponse.getData().getBusinessPolicy();
         RiskInfoVo riskInfoVo = new RiskInfoVo();
-        riskInfoVo.setStartDate(businessPolicy.getStartDate());
-        riskInfoVo.setEndDate(businessPolicy.getEndDate());
+        riskInfoVo.setStartDate("");
+        riskInfoVo.setEndDate("");
         return riskInfoVo;
     }
 
@@ -75,10 +78,10 @@ public class BoHaiCrawlerQuoteResultsVoBuild {
      * 处理商业险信息
      * @param kindInfoVo
      * @param coverageListDTOS
-     * @return
+     * @return List<KindInfoVo>
      */
     private static List<KindInfoVo> buildKindInfoVo(List<KindInfoVo> kindInfoVo, List<BoHaiCrawlerQuotationResponse.DataDTO.BusinessPolicyDTO.CoveragesDTO> coverageListDTOS) {
-        Map<String, BoHaiCrawlerQuotationResponse.DataDTO.BusinessPolicyDTO.CoveragesDTO> collect = coverageListDTOS.stream()
+        /*Map<String, BoHaiCrawlerQuotationResponse.DataDTO.BusinessPolicyDTO.CoveragesDTO> collect = coverageListDTOS.stream()
                 .collect(Collectors.toMap(BoHaiCrawlerQuotationResponse.DataDTO.BusinessPolicyDTO.CoveragesDTO::getCoverageCode, x -> x));
         kindInfoVo.forEach(kind -> {
             BoHaiCrawlerQuotationResponse.DataDTO.BusinessPolicyDTO.CoveragesDTO coverageListDTO = collect.get(kind.getKindCode());
@@ -86,31 +89,33 @@ public class BoHaiCrawlerQuoteResultsVoBuild {
                 kind.setAmount(String.valueOf(coverageListDTO.getSumInsurd()));//设置保额
                 kind.setPremium(String.valueOf(coverageListDTO.getPremium()));//设置保费
             }
-        });
+        });*/
+
         return kindInfoVo;
     }
 
     /**
-     * 设置商业险,交强险保费
+     * 构建保费
+     *
      * @param quoteResultsVo
      * @param quotationResponse
      */
-    private static void buildPremium(QuoteResultsVo quoteResultsVo, BoHaiCrawlerQuotationResponse quotationResponse) {
-        // 设置商业险保费
-        if (Objects.nonNull(quotationResponse.getData().getBusinessPolicy())){
-            quoteResultsVo.getCosts().setBiPremium(String.valueOf(quotationResponse.getData().getBusinessPolicy().getPremium()));
-        }
+    private static void buildPremium(QuoteResultsVo quoteResultsVo, BoHaiCrawlerQuotationResponse2 quotationResponse) {
         // 设置交强险保费
-        if (Objects.nonNull(quotationResponse.getData().getTrafficPolicy())) {
-            quoteResultsVo.getCosts().setCiPremium(String.valueOf(quotationResponse.getData().getTrafficPolicy().getPremium()));
+        if (Objects.nonNull(quotationResponse.getBusinessData().getFeeControlInfoList().get(0))) {
+            quoteResultsVo.getCosts().setCiPremium(quotationResponse.getBusinessData().getFeeControlInfoList().get(0).getSumPremium());
+        }
+        // 设置商业险保费
+        if (Objects.nonNull(quotationResponse.getBusinessData().getFeeControlInfoList().get(1))) {
+            quoteResultsVo.getCosts().setBiPremium(quotationResponse.getBusinessData().getFeeControlInfoList().get(1).getSumPremium());
         }
         // 设置车船税
-        quoteResultsVo.getCosts().setVvTax(String.valueOf(quotationResponse.getData().getTrafficPolicy().getVehicleTax().getTotalAmount()));
+        quoteResultsVo.getCosts().setVvTax(quotationResponse.getBusinessData().getRiskList().get(0).getCarShipTaxInfo().getSumPayTax());
         // 设置非车险(驾意险)保费
-        BoHaiCrawlerQuotationResponse.DataDTO.UnAutoPremiumDTO unAutoPremium = quotationResponse.getData().getUnAutoPremium();
+        /*BoHaiCrawlerQuotationResponse.DataDTO.UnAutoPremiumDTO unAutoPremium = quotationResponse.getData().getUnAutoPremium();
         if (unAutoPremium != null) {
             quoteResultsVo.getCosts().setNiPremium(unAutoPremium.getPremium());
-        }
+        }*/
     }
 
     /**
@@ -118,7 +123,7 @@ public class BoHaiCrawlerQuoteResultsVoBuild {
      * @param boHaiQuoteResponse
      * @return QuoteResultsVo
      */
-    public static QuoteResultsVo buildQuoteFailResultsVo(BoHaiCrawlerQuotationResponse boHaiQuoteResponse) {
+    public static QuoteResultsVo buildQuoteFailResultsVo(BoHaiCrawlerQuotationResponse2 boHaiQuoteResponse) {
         QuoteResultsVo quoteResultsVo = new QuoteResultsVo();
         // 交易流水号
         quoteResultsVo.setCompanyOrderNo("");

+ 35 - 41
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/component/BoHaiCrawlerRequestComponent.java

@@ -1,5 +1,6 @@
 package com.jzg.quotation.bohai.crawler.component;
 
+import cn.hutool.core.collection.CollUtil;
 import com.alibaba.fastjson.JSONObject;
 import com.alibaba.fastjson2.JSON;
 import com.fasterxml.jackson.databind.ObjectMapper;
@@ -40,7 +41,11 @@ import java.util.*;
 @RequiredArgsConstructor
 public class BoHaiCrawlerRequestComponent {
 
-    private static final String TOKEN = "114050281-9605ec6831302f4d5e37ea64b3c15370";
+    //private static final String TOKEN = "114050281-9605ec6831302f4d5e37ea64b3c15370";
+
+    private static final String TOKEN = PythonExecutor.executeAndGetToken(
+            "E:/project/jzg/tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/util/novel.py",
+            "E:\\project\\memorize_backend\\venv\\Scripts\\python.exe", 120);
 
     // 循环次数
     public static final int CIRCULATE_NUMBER = 3;
@@ -176,10 +181,9 @@ public class BoHaiCrawlerRequestComponent {
                 // 请求参数加密
                 case ENCRYPTED:
                     String jsonString = JSON.toJSONString(request);
-                    log.info("请求参数:{}", jsonString);
                     // 请求参数加密
                     String encrypt = DESUtil.des_encrypt(jsonString);
-                    log.info("请求参数加密:{}", encrypt);
+                    log.info("请求参数加密之后的值:{}", encrypt);
                     //生成md5值
                     String md5Value = DESUtil.md5(encrypt + "c2lub3NvZnQuY2hhbm5lbC55ZHBpYw==");
                     log.info("请求参数md5的值:{}", md5Value);
@@ -207,7 +211,7 @@ public class BoHaiCrawlerRequestComponent {
                 // 请求参数不加密
                 case UNENCRYPTED:
                     String jsonString2 = JSON.toJSONString(request);
-                    log.info("请求参数:{}", jsonString2);
+                    log.info("[请求参数不加密]请求参数:{}", jsonString2);
                     CrawlerRequestUrlStandard unencryptedStandard = (CrawlerRequestUrlStandard) urlOrStandard;
                     ResponseEntity<BoHaiResponse> unencryptedResponse = requestComponent.objectPost(
                             unencryptedStandard.getRequestUrl(boHaiCrawlerProperties.getBaseUrl2()),
@@ -378,8 +382,8 @@ public class BoHaiCrawlerRequestComponent {
      * @param headers
      * @return BoHaiCrawlerQuotationResponse
      */
-    public BoHaiCrawlerQuotationResponse quotation(BoHaiCrawlerQuotationRequest2 boHaiCrawlerQuotationRequest2, HttpHeaders headers) {
-        return executeRequest(RequestType.ENCRYPTED, RequestUrl.PRICE, boHaiCrawlerQuotationRequest2, BoHaiCrawlerQuotationResponse.class, headers);
+    public BoHaiCrawlerQuotationResponse2 quotation(BoHaiCrawlerQuotationRequest2 boHaiCrawlerQuotationRequest2, HttpHeaders headers) {
+        return executeRequest(RequestType.ENCRYPTED, RequestUrl.PRICE, boHaiCrawlerQuotationRequest2, BoHaiCrawlerQuotationResponse2.class, headers);
     }
 
     /**
@@ -397,7 +401,8 @@ public class BoHaiCrawlerRequestComponent {
     /**
      * 上传影像件
      *
-     * @param imageUploadRequest
+     * @param boHaiCrawlerImageUploadRequest
+     * @param headers
      * @return BoHaiCrawlerImageUploadSubmitResponse
      */
     public BoHaiCrawlerImageUploadSubmitResponse uploadImage(BoHaiCrawlerImageUploadRequestDto boHaiCrawlerImageUploadRequest, HttpHeaders headers) throws Exception {
@@ -412,6 +417,8 @@ public class BoHaiCrawlerRequestComponent {
                 for (InsuranceImageVo.ImageDTO imageDTO : imageBase64List) {
                     imageDTO.setBatchNum(batchNumber);
                     BoHaiCrawlerImageUploadResponse boHaiCrawlerImageUploadResponse = uploadImage(imageDTO, headers);
+                    log.info("[调用第一个接口]返回的响应对象的值:{}",JSON.toJSONString(boHaiCrawlerImageUploadResponse));
+
                     Map<String, BoHaiCrawlerImageUploadResponse.ImageInfo> data = boHaiCrawlerImageUploadResponse.getData();
                     data.keySet().forEach(key -> imageNameList.add(key));
                 }
@@ -422,22 +429,11 @@ public class BoHaiCrawlerRequestComponent {
         //2、调用第二个接口:上传图片提交
         BoHaiCrawlerImageUploadSubmitRequest boHaiCrawlerImageUploadSubmitRequest = buildImageUploadSubmitRequest(
                 boHaiCrawlerImageUploadRequest, imageNameList, batchNumber);
-        //String jsonString = JSON.toJSONString(request);
-        ObjectMapper objectMapper = new ObjectMapper();
-        String jsonString = objectMapper.writeValueAsString(boHaiCrawlerImageUploadSubmitRequest);
-        log.info("请求参数:{}", jsonString);
-        // 参数加密
-        String encrypt = DESUtil.des_encrypt(jsonString);
-        log.info("请求参数加密:{}", encrypt);
-        //生成md5值
-        String md5Value = DESUtil.md5(encrypt + "c2lub3NvZnQuY2hhbm5lbC55ZHBpYw==");
-        log.info("请求参数md5的值:{}", md5Value);
-
-        BoHaiCrawlerImageUploadSubmitEncryptionRequest boHaiCrawlerImageUploadSubmitEncryptionRequest = new BoHaiCrawlerImageUploadSubmitEncryptionRequest();
-        boHaiCrawlerImageUploadSubmitEncryptionRequest.setEncryptionData(encrypt);
-        boHaiCrawlerImageUploadSubmitEncryptionRequest.setMd5(md5Value);
-
-        BoHaiCrawlerImageUploadSubmitResponse boHaiCrawlerImageUploadSubmitResponse = executeRequest(RequestType.ENCRYPTED, RequestUrl.UPLOAD_SUBMIT, boHaiCrawlerImageUploadSubmitEncryptionRequest, BoHaiCrawlerImageUploadSubmitResponse.class, headers);
+        log.info("[渤海上传影像件第二个接口]请求参数的值:{}", JSON.toJSONString(boHaiCrawlerImageUploadSubmitRequest));
+
+        BoHaiCrawlerImageUploadSubmitResponse boHaiCrawlerImageUploadSubmitResponse = executeRequest(RequestType.ENCRYPTED, RequestUrl.UPLOAD_SUBMIT, boHaiCrawlerImageUploadSubmitRequest, BoHaiCrawlerImageUploadSubmitResponse.class, headers);
+        log.info("[渤海上传影像件第二个接口]返回参数的值:{}",JSON.toJSONString(boHaiCrawlerImageUploadSubmitResponse));
+
         String returnCode = boHaiCrawlerImageUploadSubmitResponse.getHead().getReturnCode();
         if (!"0".equals(returnCode)) {
             log.error("上传影像提交失败,返回码:{},返回消息:{}", returnCode, boHaiCrawlerImageUploadSubmitResponse.getHead().getReturnMessage());
@@ -452,8 +448,8 @@ public class BoHaiCrawlerRequestComponent {
      * 构建图片上传提交请求对象
      *
      * @param boHaiCrawlerImageUploadRequest 请求DTO
-     * @param files                          文件数组
-     * @param batchNumber                    批次号
+     * @param imageNameList
+     * @param batchNumber
      * @return BoHaiCrawlerImageUploadSubmitRequest
      */
     private BoHaiCrawlerImageUploadSubmitRequest buildImageUploadSubmitRequest(
@@ -468,10 +464,10 @@ public class BoHaiCrawlerRequestComponent {
         submitRequest.setHead(head);
 
         // 设置用户和机构信息
-        submitRequest.setUserCode("114050281");
-        submitRequest.setUserName("郝壮明");
-        submitRequest.setOrgCode("14070201");
-        submitRequest.setOrgName("山西分公司介休支公司业务一部");
+        submitRequest.setUserCode(boHaiCrawlerImageUploadRequest.getBaseParam().getUserCode());
+        submitRequest.setUserName(boHaiCrawlerImageUploadRequest.getBaseParam().getUserName());
+        submitRequest.setOrgCode(boHaiCrawlerImageUploadRequest.getBaseParam().getOrgCode());
+        submitRequest.setOrgName(boHaiCrawlerImageUploadRequest.getBaseParam().getOrgName());
 
         // 设置业务代码
         submitRequest.setCode("ECM10002");
@@ -485,7 +481,7 @@ public class BoHaiCrawlerRequestComponent {
         //分类代码(重要)
         batchInfo.setAppCode("CXCB_TB");
         batchInfo.setAppName("车险投保资料");
-        batchInfo.setBusiNo(boHaiCrawlerImageUploadRequest.getOrderNo());
+        batchInfo.setBusiNo(boHaiCrawlerImageUploadRequest.getBaseParam().getOrderNo());
 
         // 构建页面列表
         List<BoHaiCrawlerImageUploadSubmitRequest.PageInfo> pagelist = new ArrayList<>();
@@ -510,10 +506,10 @@ public class BoHaiCrawlerRequestComponent {
         pagelist.add(pageInfo);
         batchInfo.setPagelist(pagelist);
 
-        batchInfo.setComCode("14070201");
-        batchInfo.setComName("山西分公司介休支公司业务一部");
-        batchInfo.setUserCode("114050281");
-        batchInfo.setUserName("郝壮明");
+        batchInfo.setComCode(boHaiCrawlerImageUploadRequest.getBaseParam().getOrgCode());
+        batchInfo.setComName(boHaiCrawlerImageUploadRequest.getBaseParam().getOrgName());
+        batchInfo.setUserCode(boHaiCrawlerImageUploadRequest.getBaseParam().getUserCode());
+        batchInfo.setUserName(boHaiCrawlerImageUploadRequest.getBaseParam().getUserName());
 
         bathList.add(batchInfo);
         submitRequest.setBathList(bathList);
@@ -547,7 +543,7 @@ public class BoHaiCrawlerRequestComponent {
             }
 
             // 构建完整请求URL - batchNum作为查询参数
-            String fullUrl = RequestUrl.UPLOAD_IMAGE.getRequestUrl(boHaiCrawlerProperties.getBaseUrl2()) + "?batchNum=" + imageDTO.getBatchNum();
+            String fullUrl = RequestUrl.UPLOAD_IMAGE.getRequestUrl(boHaiCrawlerProperties.getBaseUrl()) + "?batchNum=" + imageDTO.getBatchNum();
             log.info("影像上传接口一地址:{}", fullUrl);
             //创建请求体
             MultiValueMap<String, Object> requestBody = new LinkedMultiValueMap<>();
@@ -559,7 +555,6 @@ public class BoHaiCrawlerRequestComponent {
             };
             requestBody.add("file[]", resource);
             BoHaiCrawlerImageUploadResponse boHaiCrawlerImageUploadResponse = executeRequest(RequestType.FILE_UPLOAD, fullUrl, requestBody, BoHaiCrawlerImageUploadResponse.class, headers);
-            log.info("boHaiCrawlerImageUploadResponse对象的值:{}", JSON.toJSONString(boHaiCrawlerImageUploadResponse));
             Map<String, BoHaiCrawlerImageUploadResponse.ImageInfo> data = boHaiCrawlerImageUploadResponse.getData();
             if (CollectionUtils.isEmpty(data)) {
                 log.error("上传影像失败,返回数据为空");
@@ -583,13 +578,12 @@ public class BoHaiCrawlerRequestComponent {
         //1、调用支付凭证号查询(交强险、商业险保单号查询)接口
         BoHaiCrawlerPaymentCertiNoQueryResponse boHaiCrawlerPaymentCertiNoQueryResponse = executeRequest(RequestType.ENCRYPTED, RequestUrl.PAYMENTCERTINOQUERY, boHaiCrawlerPaymentCertiNoQueryRequest, BoHaiCrawlerPaymentCertiNoQueryResponse.class, headers);
         log.info("支付凭证号查询响应对象的值:{}", JSON.toJSONString(boHaiCrawlerPaymentCertiNoQueryResponse));
-        if("0".equals(boHaiCrawlerPaymentCertiNoQueryResponse.getHead().getReturnCode())){
-            /*if(CollectionUtils.isEmpty(boHaiCrawlerPaymentCertiNoQueryResponse.getBusinessInfoList())){
-                log.error("支付凭证号查询失败,返回数据为空");
-                throw new SystemException("支付凭证号查询失败,返回数据为空");
-            }*/
+
+        if("0".equals(boHaiCrawlerPaymentCertiNoQueryResponse.getHead().getReturnCode()) && CollUtil.isNotEmpty(boHaiCrawlerPaymentCertiNoQueryResponse.getBusinessInfoList())){
             //2、调用支付通知单号生成接口
             BoHaiCrawlerPaymentNoticeNoGenerationRequest boHaiCrawlerPaymentNoticeNoGenerationRequest = buildPaymentNoticeNoGenerationRequest(boHaiCrawlerPaymentCertiNoQueryResponse);
+            log.info("[支付通知单号生成]请求参数的值:{}",JSON.toJSONString(boHaiCrawlerPaymentNoticeNoGenerationRequest));
+
             BoHaiCrawlerPaymentNoticeNoGenerationResponse boHaiCrawlerPaymentNoticeNoGenerationResponse = executeRequest(RequestType.ENCRYPTED, RequestUrl.PAYMENTNOTICENO_GENERATION, boHaiCrawlerPaymentNoticeNoGenerationRequest, BoHaiCrawlerPaymentNoticeNoGenerationResponse.class, headers);
             log.info("支付通知单号生成响应对象的值:{}", JSON.toJSONString(boHaiCrawlerPaymentNoticeNoGenerationResponse));
             if(!"0".equals(boHaiCrawlerPaymentNoticeNoGenerationResponse.getHead().getReturnCode())){

+ 5 - 5
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/BoHaiCrawlerConfigureParameters.java

@@ -34,14 +34,14 @@ public class BoHaiCrawlerConfigureParameters implements ConfigureParameters {
     private String channelPackages;
 
     /**
-     * 用户编
+     * 用户编
      */
     private String userCode;
 
     /**
-     * 用户名
+     * 业务员
      */
-    private String userName;
+    private String salesMan;
 
     /**
      * 机构编码
@@ -49,8 +49,8 @@ public class BoHaiCrawlerConfigureParameters implements ConfigureParameters {
     private String orgCode;
 
     /**
-     * 机构名称
+     * 归属部门
      */
-    private String orgName;
+    private String department;
 
 }

+ 3 - 2
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/po/BoHaiCrawlerOrder.java

@@ -8,6 +8,7 @@ import org.springframework.data.annotation.Id;
 import org.springframework.data.mongodb.core.mapping.Document;
 
 import java.time.LocalDateTime;
+import java.time.ZonedDateTime;
 
 /**
  * @description: 渤海财险爬虫订单实体
@@ -100,12 +101,12 @@ public class BoHaiCrawlerOrder {
      * 创建时间
      */
     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
-    private LocalDateTime createTime;
+    private LocalDateTime  createTime;
 
     /**
      * 更新时间
      */
     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
-    private LocalDateTime updateTime;
+    private LocalDateTime   updateTime;
 
 }

+ 15 - 1
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/request/BoHaiCrawlerBaseRequest.java

@@ -38,7 +38,9 @@ public class BoHaiCrawlerBaseRequest implements Serializable {
         baseParam.requestNo = UUID.randomUUID().toString().replace("-", "");
         baseParam.requestTime = LocalDateTime.now().format(DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss.SSS"));
         baseParam.orgCode = parameters.getOrgCode();
-        baseParam.orgName = parameters.getOrgName();
+        baseParam.orgName = parameters.getDepartment();
+        baseParam.userCode = parameters.getUserCode();
+        baseParam.userName = parameters.getSalesMan();
     }
 
     public void setBaseParamRequestType(String requestType) {
@@ -95,6 +97,18 @@ public class BoHaiCrawlerBaseRequest implements Serializable {
          */
         @JsonProperty("comName")
         private String orgName;
+
+        /**
+         * 操作人工号
+         */
+        @JsonProperty("userCode")
+        private String userCode;
+
+        /**
+         *操作人姓名
+         */
+        @JsonProperty("userName")
+        private String userName;
     }
 
 }

+ 1 - 1
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/request/BoHaiCrawlerCarRequest.java

@@ -137,7 +137,7 @@ public class BoHaiCrawlerCarRequest implements Serializable {
         private String plateNoType;
 
         /**
-         * 号牌颜色
+         * 号牌颜色(01:蓝色)
          */
         @JsonProperty("plateNoColor")
         @JSONField(ordinal = 7)

+ 0 - 6
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/request/BoHaiCrawlerImageUploadRequestDto.java

@@ -20,12 +20,6 @@ import java.util.List;
 @AllArgsConstructor
 @NoArgsConstructor
 public class BoHaiCrawlerImageUploadRequestDto extends BoHaiCrawlerBaseRequest {
-
-    /**
-     * 订单号
-     */
-    private String orderNo;
-
     /**
      * 影像文件
      */

+ 26 - 0
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/request/BoHaiCrawlerImageUploadSubmitRequest.java

@@ -1,5 +1,6 @@
 package com.jzg.quotation.bohai.crawler.entity.request;
 
+import com.alibaba.fastjson.annotation.JSONField;
 import com.fasterxml.jackson.annotation.JsonProperty;
 import lombok.AllArgsConstructor;
 import lombok.Data;
@@ -31,54 +32,63 @@ public class BoHaiCrawlerImageUploadSubmitRequest implements Serializable {
     /**
      * 用户代码
      */
+    @JSONField(ordinal = 1)
     @JsonProperty("userCode")
     private String userCode;
 
     /**
      * 用户名称
      */
+    @JSONField(ordinal = 2)
     @JsonProperty("userName")
     private String userName;
 
     /**
      * 机构代码
      */
+    @JSONField(ordinal = 3)
     @JsonProperty("orgCode")
     private String orgCode;
 
     /**
      * 机构名称
      */
+    @JSONField(ordinal = 4)
     @JsonProperty("orgName")
     private String orgName;
 
     /**
      * 业务代码/系统代码
      */
+    @JSONField(ordinal = 5)
     @JsonProperty("code")
     private String code;
 
     /**
      * 角色代码:车险承保
      */
+    @JSONField(ordinal = 6)
     @JsonProperty("roleCode")
     private String roleCode;
 
     /**
      * 批次号/批量上传编号
      */
+    @JSONField(ordinal = 7)
     @JsonProperty("batchNum")
     private String batchNum;
 
     /**
      * 批次列表
      */
+    @JSONField(ordinal = 8)
     @JsonProperty("bathList")
     private List<BatchInfo> bathList;
 
     /**
      * 角色代码JS
      */
+    @JSONField(ordinal = 9)
     @JsonProperty("roleCodeJS")
     private String roleCodeJS;
 
@@ -91,18 +101,21 @@ public class BoHaiCrawlerImageUploadSubmitRequest implements Serializable {
          * 令牌
          */
         @JsonProperty("token")
+        @JSONField(ordinal = 1)
         private String token;
 
         /**
          * 交易类型
          */
         @JsonProperty("transType")
+        @JSONField(ordinal = 2)
         private String transType;
 
         /**
          * 交易代码
          */
         @JsonProperty("transCode")
+        @JSONField(ordinal = 3)
         private String transCode;
     }
 
@@ -114,48 +127,56 @@ public class BoHaiCrawlerImageUploadSubmitRequest implements Serializable {
         /**
          * 分类代码 车险承保-投保
          */
+        @JSONField(ordinal = 1)
         @JsonProperty("appCode")
         private String appCode;
 
         /**
          * 应用名称
          */
+        @JSONField(ordinal = 2)
         @JsonProperty("appName")
         private String appName;
 
         /**
          * 订单号
          */
+        @JSONField(ordinal = 3)
         @JsonProperty("busiNo")
         private String busiNo;
 
         /**
          * 页面/文件列表
          */
+        @JSONField(ordinal = 4)
         @JsonProperty("pagelist")
         private List<PageInfo> pagelist;
 
         /**
          * 公司代码
          */
+        @JSONField(ordinal = 5)
         @JsonProperty("comCode")
         private String comCode;
 
         /**
          * 公司名称
          */
+        @JSONField(ordinal = 6)
         @JsonProperty("comName")
         private String comName;
 
         /**
          * 用户代码
          */
+        @JSONField(ordinal = 7)
         @JsonProperty("userCode")
         private String userCode;
 
         /**
          * 用户名称
          */
+        @JSONField(ordinal = 8)
         @JsonProperty("userName")
         private String userName;
     }
@@ -168,12 +189,14 @@ public class BoHaiCrawlerImageUploadSubmitRequest implements Serializable {
         /**
          * 一级分类ID:车险投保
          */
+        @JSONField(ordinal = 1)
         @JsonProperty("id")
         private String id;
 
         /**
          * 子分类列表
          */
+        @JSONField(ordinal = 2)
         @JsonProperty("children")
         private List<ChildInfo> children;
     }
@@ -186,12 +209,14 @@ public class BoHaiCrawlerImageUploadSubmitRequest implements Serializable {
         /**
          * 二级分类ID:具体证件类型
          */
+        @JSONField(ordinal = 1)
         @JsonProperty("id")
         private String id;
 
         /**
          * 页面/图片列表
          */
+        @JSONField(ordinal = 2)
         @JsonProperty("pages")
         private List<PageDetail> pages;
     }
@@ -204,6 +229,7 @@ public class BoHaiCrawlerImageUploadSubmitRequest implements Serializable {
         /**
          * 文件名称
          */
+        @JSONField(ordinal = 1)
         @JsonProperty("fileName")
         private String fileName;
     }

+ 47 - 0
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/request/BoHaiCrawlerPaymentCertiNoQueryRequest.java

@@ -1,5 +1,6 @@
 package com.jzg.quotation.bohai.crawler.entity.request;
 
+import com.alibaba.fastjson.annotation.JSONField;
 import com.fasterxml.jackson.annotation.JsonProperty;
 import lombok.Data;
 import lombok.NoArgsConstructor;
@@ -20,258 +21,301 @@ public class BoHaiCrawlerPaymentCertiNoQueryRequest implements Serializable {
     /**
      * 请求头信息
      */
+    @JSONField(ordinal = 1)
     @JsonProperty("head")
     private Head head;
 
     /**
      * 凭证类型:T=临时凭证,P=正式凭证
      */
+    @JSONField(ordinal = 2)
     @JsonProperty("certiType")
     private String certiType;
 
     /**
      * 登录机构
      */
+    @JSONField(ordinal = 3)
     @JsonProperty("loginCom")
     private String loginCom;
 
     /**
      * 每页行数
      */
+    @JSONField(ordinal = 4)
     @JsonProperty("rows")
     private Integer rows;
 
     /**
      * 页码
      */
+    @JSONField(ordinal = 5)
     @JsonProperty("pageNo")
     private Integer pageNo;
 
     /**
      * 业务类型:O=订单,P=保单,Q=报价单
      */
+    @JSONField(ordinal = 6)
     @JsonProperty("businessType")
     private String businessType;
 
     /**
      * 用户代码
      */
+    @JSONField(ordinal = 7)
     @JsonProperty("userCode")
     private String userCode;
 
     /**
      * 车牌号
      */
+    @JSONField(ordinal = 8)
     @JsonProperty("licenseNo")
     private String licenseNo;
 
     /**
      * 车牌号比较符号
      */
+    @JSONField(ordinal = 9)
     @JsonProperty("licenseNoSign")
     private String licenseNoSign;
 
     /**
      * VIN码
      */
+    @JSONField(ordinal = 10)
     @JsonProperty("vinNo")
     private String vinNo;
 
     /**
      * VIN码比较符号
      */
+    @JSONField(ordinal = 11)
     @JsonProperty("vinNoSign")
     private String vinNoSign;
 
     /**
      * 车架号
      */
+    @JSONField(ordinal = 12)
     @JsonProperty("frameNo")
     private String frameNo;
 
     /**
      * 车架号比较符号
      */
+    @JSONField(ordinal = 13)
     @JsonProperty("frameNoSign")
     private String frameNoSign;
 
     /**
      * 发动机号
      */
+    @JSONField(ordinal = 14)
     @JsonProperty("engineNo")
     private String engineNo;
 
     /**
      * 发动机号比较符号
      */
+    @JSONField(ordinal = 15)
     @JsonProperty("engineNoSign")
     private String engineNoSign;
 
     /**
      * 订单号
      */
+    @JSONField(ordinal = 16)
     @JsonProperty("orderNo")
     private String orderNo;
 
     /**
      * 订单号比较符号
      */
+    @JSONField(ordinal = 17)
     @JsonProperty("orderNoFlag")
     private String orderNoFlag;
 
     /**
      * 投保单号
      */
+    @JSONField(ordinal = 18)
     @JsonProperty("proposalNo")
     private String proposalNo;
 
     /**
      * 投保单号比较符号
      */
+    @JSONField(ordinal = 19)
     @JsonProperty("proposalNoFlag")
     private String proposalNoFlag;
 
     /**
      * 报价单号
      */
+    @JSONField(ordinal = 20)
     @JsonProperty("quotationNo")
     private String quotationNo;
 
     /**
      * 报价单号比较符号
      */
+    @JSONField(ordinal = 21)
     @JsonProperty("quotationNoFlag")
     private String quotationNoFlag;
 
     /**
      * 保单号
      */
+    @JSONField(ordinal = 22)
     @JsonProperty("policyNo")
     private String policyNo;
 
     /**
      * 保单号比较符号
      */
+    @JSONField(ordinal = 23)
     @JsonProperty("policyNoFlag")
     private String policyNoFlag;
 
     /**
      * 批单号
      */
+    @JSONField(ordinal = 24)
     @JsonProperty("endorseNo")
     private String endorseNo;
 
     /**
      * 批单号比较符号
      */
+    @JSONField(ordinal = 25)
     @JsonProperty("endorseNoFlag")
     private String endorseNoFlag;
 
     /**
      * 被保险人姓名
      */
+    @JSONField(ordinal = 26)
     @JsonProperty("insuredName")
     private String insuredName;
 
     /**
      * 被保险人姓名比较符号
      */
+    @JSONField(ordinal = 27)
     @JsonProperty("insuredNameSign")
     private String insuredNameSign;
 
     /**
      * 投保人姓名
      */
+    @JSONField(ordinal = 28)
     @JsonProperty("appliName")
     private String appliName;
 
     /**
      * 投保人姓名比较符号
      */
+    @JSONField(ordinal = 29)
     @JsonProperty("appliNameSign")
     private String appliNameSign;
 
     /**
      * 投保人身份证号
      */
+    @JSONField(ordinal = 30)
     @JsonProperty("appliIdentifyNumber")
     private String appliIdentifyNumber;
 
     /**
      * 投保人身份证号比较符号
      */
+    @JSONField(ordinal = 31)
     @JsonProperty("appliIdentifyNumberFlag")
     private String appliIdentifyNumberFlag;
 
     /**
      * 被保险人身份证号
      */
+    @JSONField(ordinal = 32)
     @JsonProperty("insuredIdentifyNumber")
     private String insuredIdentifyNumber;
 
     /**
      * 被保险人身份证号比较符号
      */
+    @JSONField(ordinal = 33)
     @JsonProperty("insuredIdentifyNumberFlag")
     private String insuredIdentifyNumberFlag;
 
     /**
      * 保险起期开始
      */
+    @JSONField(ordinal = 34)
     @JsonProperty("startDateBegin")
     private String startDateBegin;
 
     /**
      * 保险起期结束
      */
+    @JSONField(ordinal = 35)
     @JsonProperty("startDateEnd")
     private String startDateEnd;
 
     /**
      * 保险止期开始
      */
+    @JSONField(ordinal = 36)
     @JsonProperty("endDateBegin")
     private String endDateBegin;
 
     /**
      * 保险止期结束
      */
+    @JSONField(ordinal = 37)
     @JsonProperty("endDateEnd")
     private String endDateEnd;
 
     /**
      * 操作日期开始(最近一个月)
      */
+    @JSONField(ordinal = 38)
     @JsonProperty("operateDateBegin")
     private String operateDateBegin;
 
     /**
      * 操作日期结束(今天)
      */
+    @JSONField(ordinal = 39)
     @JsonProperty("operateDateEnd")
     private String operateDateEnd;
 
     /**
      * 核保日期开始
      */
+    @JSONField(ordinal = 40)
     @JsonProperty("underWriteDateStart")
     private String underWriteDateStart;
 
     /**
      * 核保日期结束
      */
+    @JSONField(ordinal = 41)
     @JsonProperty("underWriteDateEnd")
     private String underWriteDateEnd;
 
     /**
      * 资源类型代码:001=车险,002=非车险,004=支付凭证
      */
+    @JSONField(ordinal = 42)
     @JsonProperty("resourceTypeCode")
     private String resourceTypeCode;
 
     /**
      * 是否签发用户代码
      */
+    @JSONField(ordinal = 43)
     @JsonProperty("isIssueUserCode")
     private String isIssueUserCode;
 
@@ -285,18 +329,21 @@ public class BoHaiCrawlerPaymentCertiNoQueryRequest implements Serializable {
         /**
          * 访问令牌
          */
+        @JSONField(ordinal = 1)
         @JsonProperty("token")
         private String token;
 
         /**
          * 交易类型
          */
+        @JSONField(ordinal = 2)
         @JsonProperty("transType")
         private String transType;
 
         /**
          * 交易代码
          */
+        @JSONField(ordinal = 3)
         @JsonProperty("transCode")
         private String transCode;
     }

Разница между файлами не показана из-за своего большого размера
+ 406 - 24
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/request/BoHaiCrawlerQuotationRequest2.java


Разница между файлами не показана из-за своего большого размера
+ 297 - 53
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/request/BoHaiCrawlerUnderwritingRequest2.java


+ 4 - 0
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/response/BoHaiCrawlerCarApiResponse.java

@@ -3,6 +3,10 @@ import com.fasterxml.jackson.annotation.JsonProperty;
 import lombok.Data;
 import java.io.Serial;
 import java.io.Serializable;
+
+/**
+ * 渤海财险车辆查询响应实体类
+ */
 @Data
 public class BoHaiCrawlerCarApiResponse implements Serializable {
 

+ 4 - 0
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/response/BoHaiCrawlerCarResponse.java

@@ -647,6 +647,10 @@ public class BoHaiCrawlerCarResponse implements Serializable {
         private String carBrand;
         private String carYear;
         private String carSeriesCode;
+
+        /**
+         * 整备质量(kg)
+         */
         private String completeKerbMass;
         private String riskType;
         private String factoryCode;

+ 1088 - 0
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/response/BoHaiCrawlerQuotationResponse2.java

@@ -0,0 +1,1088 @@
+package com.jzg.quotation.bohai.crawler.entity.response;
+
+import com.alibaba.fastjson.annotation.JSONField;
+import com.alibaba.fastjson.serializer.SerializerFeature;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+import java.io.Serial;
+import java.io.Serializable;
+import java.util.List;
+import java.util.Map;
+
+/**
+ * 渤海财险爬虫报价响应实体类
+ *
+ * @author
+ * @since
+ */
+@Data
+@NoArgsConstructor
+public class BoHaiCrawlerQuotationResponse2 implements Serializable {
+
+    @Serial
+    private static final long serialVersionUID = 1L;
+
+    @JSONField(name = "businessData", ordinal = 1, serialzeFeatures = SerializerFeature.WriteMapNullValue)
+    private BusinessData businessData;
+
+    @JSONField(name = "head", ordinal = 2)
+    private Head head;
+
+
+    /**
+     * 响应头
+     */
+    @Data
+    @NoArgsConstructor
+    public static class Head implements Serializable {
+
+        @Serial
+        private static final long serialVersionUID = 1L;
+
+        @JSONField(name = "returnCode", ordinal = 1)
+        private String returnCode;
+
+        @JSONField(name = "returnMessage", ordinal = 2)
+        private String returnMessage;
+
+        @JSONField(name = "sessionId", ordinal = 3)
+        private String sessionId;
+
+        @JSONField(name = "token", ordinal = 4)
+        private String token;
+
+        @JSONField(name = "transCode", ordinal = 5)
+        private String transCode;
+
+        @JSONField(name = "transType", ordinal = 6)
+        private String transType;
+    }
+
+    /**
+     * 业务数据
+     */
+    @Data
+    @NoArgsConstructor
+    public static class BusinessData implements Serializable {
+
+        @Serial
+        private static final long serialVersionUID = 1L;
+
+        @JSONField(name = "businessMainInfo", ordinal = 1)
+        private BusinessMainInfo businessMainInfo;
+
+        @JSONField(name = "carInfo", ordinal = 2)
+        private CarInfo carInfo;
+
+        @JSONField(name = "errorMessageBI", ordinal = 3)
+        private String errorMessageBI;
+
+        @JSONField(name = "errorMessageCI", ordinal = 4)
+        private String errorMessageCI;
+
+        @JSONField(name = "errorMessageDI", ordinal = 5)
+        private String errorMessageDI;
+
+        @JSONField(name = "feeControlInfoList", ordinal = 6)
+        private List<FeeControlInfo> feeControlInfoList;
+
+        @JSONField(name = "payPlanVoList", ordinal = 7)
+        private List<PayPlanVo> payPlanVoList;
+
+        @JSONField(name = "riskList", ordinal = 8)
+        private List<RiskInfo> riskList;
+    }
+
+    /**
+     * 业务主要信息
+     */
+    @Data
+    @NoArgsConstructor
+    public static class BusinessMainInfo implements Serializable {
+
+        @Serial
+        private static final long serialVersionUID = 1L;
+
+        @JSONField(name = "TAprermium", ordinal = 1)
+        private String tAprermium;
+
+        @JSONField(name = "bussUnitCode", ordinal = 2)
+        private String bussUnitCode;
+
+        @JSONField(name = "bussUnitCodeCI", ordinal = 3)
+        private String bussUnitCodeCI;
+
+        @JSONField(name = "chdId", ordinal = 4)
+        private String chdId;
+
+        @JSONField(name = "commissionFlag", ordinal = 5)
+        private String commissionFlag;
+
+        @JSONField(name = "driModelScoreReqNo", ordinal = 6)
+        private String driModelScoreReqNo;
+
+        @JSONField(name = "entireFloatDiscount", ordinal = 7)
+        private String entireFloatDiscount;
+
+        @JSONField(name = "entireInitialDiscount", ordinal = 8)
+        private String entireInitialDiscount;
+
+        @JSONField(name = "entireRecommenDiscount", ordinal = 9)
+        private String entireRecommenDiscount;
+
+        @JSONField(name = "expectDiscount", ordinal = 10)
+        private String expectDiscount;
+
+        @JSONField(name = "feeType", ordinal = 11)
+        private String feeType;
+
+        @JSONField(name = "fixPriceNo", ordinal = 12)
+        private String fixPriceNo;
+
+        @JSONField(name = "fixPriceRuleId", ordinal = 13)
+        private String fixPriceRuleId;
+
+        @JSONField(name = "fixPriceStatus", ordinal = 14)
+        private String fixPriceStatus;
+
+        @JSONField(name = "followID", ordinal = 15)
+        private String followID;
+
+        @JSONField(name = "highRiskAssessId", ordinal = 16)
+        private String highRiskAssessId;
+
+        @JSONField(name = "isAffiliTransaction", ordinal = 17)
+        private String isAffiliTransaction;
+
+        @JSONField(name = "lastYearAdjustValue", ordinal = 18)
+        private String lastYearAdjustValue;
+
+        @JSONField(name = "noTaxAmount", ordinal = 19)
+        private String noTaxAmount;
+
+        @JSONField(name = "pcIds", ordinal = 20)
+        private String pcIds;
+
+        @JSONField(name = "praID", ordinal = 21)
+        private String praID;
+
+        @JSONField(name = "priceMode", ordinal = 22)
+        private String priceMode;
+
+        @JSONField(name = "quotationTime", ordinal = 23)
+        private String quotationTime;
+
+        @JSONField(name = "reCustomerType", ordinal = 24)
+        private String reCustomerType;
+
+        @JSONField(name = "reStatus", ordinal = 25)
+        private String reStatus;
+
+        @JSONField(name = "reTaskUserCode", ordinal = 26)
+        private String reTaskUserCode;
+
+        @JSONField(name = "reTaskUserName", ordinal = 27)
+        private String reTaskUserName;
+
+        @JSONField(name = "reneClientType", ordinal = 28)
+        private String reneClientType;
+
+        @JSONField(name = "sumDiscount", ordinal = 29)
+        private String sumDiscount;
+
+        @JSONField(name = "sumPremium", ordinal = 30)
+        private String sumPremium;
+
+        @JSONField(name = "taxAmount", ordinal = 31)
+        private String taxAmount;
+
+        @JSONField(name = "tbMode", ordinal = 32)
+        private String tbMode;
+
+        @JSONField(name = "thirdRecordCode", ordinal = 33)
+        private String thirdRecordCode;
+
+        @JSONField(name = "tipsMsg", ordinal = 34)
+        private String tipsMsg;
+    }
+
+    /**
+     * 车辆信息
+     */
+    @Data
+    @NoArgsConstructor
+    public static class CarInfo implements Serializable {
+
+        @Serial
+        private static final long serialVersionUID = 1L;
+
+        @JSONField(name = "itemCarInfo", ordinal = 1)
+        private ItemCarInfo itemCarInfo;
+    }
+
+    /**
+     * 车辆详细信息
+     */
+    @Data
+    @NoArgsConstructor
+    public static class ItemCarInfo implements Serializable {
+
+        @Serial
+        private static final long serialVersionUID = 1L;
+
+        @JSONField(name = "chargingInfoList", ordinal = 1)
+        private List<Object> chargingInfoList;
+
+        @JSONField(name = "checkSCCode", ordinal = 2)
+        private String checkSCCode;
+
+        @JSONField(name = "countryNature", ordinal = 3)
+        private String countryNature;
+
+        @JSONField(name = "damagedFactorGrade", ordinal = 4)
+        private String damagedFactorGrade;
+
+        @JSONField(name = "deviceList", ordinal = 5)
+        private List<Object> deviceList;
+
+        @JSONField(name = "exhaustScale", ordinal = 6)
+        private String exhaustScale;
+
+        @JSONField(name = "lastBusinessChannel", ordinal = 7)
+        private String lastBusinessChannel;
+
+        @JSONField(name = "madeFactory", ordinal = 8)
+        private String madeFactory;
+
+        @JSONField(name = "motorTypeCode", ordinal = 9)
+        private String motorTypeCode;
+
+        @JSONField(name = "newVehicleFlag", ordinal = 10)
+        private String newVehicleFlag;
+
+        @JSONField(name = "noClaimAdjustReasonBI", ordinal = 11)
+        private String noClaimAdjustReasonBI;
+
+        @JSONField(name = "noClaimAdjustReasonCI", ordinal = 12)
+        private String noClaimAdjustReasonCI;
+
+        @JSONField(name = "noticeType", ordinal = 13)
+        private String noticeType;
+
+        @JSONField(name = "proportion", ordinal = 14)
+        private String proportion;
+
+        @JSONField(name = "renewalTime", ordinal = 15)
+        private String renewalTime;
+
+        @JSONField(name = "vehicleBrand", ordinal = 16)
+        private String vehicleBrand;
+    }
+
+    /**
+     * 费用控制信息
+     */
+    @Data
+    @NoArgsConstructor
+    public static class FeeControlInfo implements Serializable {
+
+        @Serial
+        private static final long serialVersionUID = 1L;
+
+        @JSONField(name = "allRiskLevel", ordinal = 1)
+        private String allRiskLevel;
+
+        @JSONField(name = "amountA10", ordinal = 2)
+        private String amountA10;
+
+        @JSONField(name = "amountA11", ordinal = 3)
+        private String amountA11;
+
+        @JSONField(name = "amountA12", ordinal = 4)
+        private String amountA12;
+
+        @JSONField(name = "amountA13", ordinal = 5)
+        private String amountA13;
+
+        @JSONField(name = "amountA14", ordinal = 6)
+        private String amountA14;
+
+        @JSONField(name = "amountA15", ordinal = 7)
+        private String amountA15;
+
+        @JSONField(name = "amountA4", ordinal = 8)
+        private String amountA4;
+
+        @JSONField(name = "amountA5", ordinal = 9)
+        private String amountA5;
+
+        @JSONField(name = "amountA7", ordinal = 10)
+        private String amountA7;
+
+        @JSONField(name = "amountA8", ordinal = 11)
+        private String amountA8;
+
+        @JSONField(name = "basicAmount", ordinal = 12)
+        private String basicAmount;
+
+        @JSONField(name = "basicDisrate", ordinal = 13)
+        private String basicDisrate;
+
+        @JSONField(name = "basicDisrateOrigin", ordinal = 14)
+        private String basicDisrateOrigin;
+
+        @JSONField(name = "comCodeFlg", ordinal = 15)
+        private String comCodeFlg;
+
+        @JSONField(name = "currency", ordinal = 16)
+        private String currency;
+
+        @JSONField(name = "dimensionCode", ordinal = 17)
+        private String dimensionCode;
+
+        @JSONField(name = "disFee", ordinal = 18)
+        private String disFee;
+
+        @JSONField(name = "disRate", ordinal = 19)
+        private String disRate;
+
+        @JSONField(name = "disRate1", ordinal = 20)
+        private String disRate1;
+
+        @JSONField(name = "disRate2", ordinal = 21)
+        private String disRate2;
+
+        @JSONField(name = "disRateOrigin", ordinal = 22)
+        private String disRateOrigin;
+
+        @JSONField(name = "effRateOrigin", ordinal = 23)
+        private String effRateOrigin;
+
+        @JSONField(name = "efftAmount", ordinal = 24)
+        private String efftAmount;
+
+        @JSONField(name = "efftAmount1", ordinal = 25)
+        private String efftAmount1;
+
+        @JSONField(name = "efftRate", ordinal = 26)
+        private String efftRate;
+
+        @JSONField(name = "efftRate1", ordinal = 27)
+        private String efftRate1;
+
+        @JSONField(name = "flag", ordinal = 28)
+        private String flag;
+
+        @JSONField(name = "ilogNo", ordinal = 29)
+        private String ilogNo;
+
+        @JSONField(name = "inSpaceAmount", ordinal = 30)
+        private String inSpaceAmount;
+
+        @JSONField(name = "inSpaceRate", ordinal = 31)
+        private String inSpaceRate;
+
+        @JSONField(name = "inSpaceRateOrigin", ordinal = 32)
+        private String inSpaceRateOrigin;
+
+        @JSONField(name = "incAmount1", ordinal = 33)
+        private String incAmount1;
+
+        @JSONField(name = "incAount", ordinal = 34)
+        private String incAount;
+
+        @JSONField(name = "incRate", ordinal = 35)
+        private String incRate;
+
+        @JSONField(name = "incRate1", ordinal = 36)
+        private String incRate1;
+
+        @JSONField(name = "incRateOrigin", ordinal = 37)
+        private String incRateOrigin;
+
+        @JSONField(name = "managementAmount", ordinal = 38)
+        private String managementAmount;
+
+        @JSONField(name = "managementDisrate", ordinal = 39)
+        private String managementDisrate;
+
+        @JSONField(name = "managementDisrateOrigin", ordinal = 40)
+        private String managementDisrateOrigin;
+
+        @JSONField(name = "noTaxAmount", ordinal = 41)
+        private String noTaxAmount;
+
+        @JSONField(name = "otherAmount", ordinal = 42)
+        private String otherAmount;
+
+        @JSONField(name = "otherRate", ordinal = 43)
+        private String otherRate;
+
+        @JSONField(name = "otherRateOrigin", ordinal = 44)
+        private String otherRateOrigin;
+
+        @JSONField(name = "outSpaceAmount", ordinal = 45)
+        private String outSpaceAmount;
+
+        @JSONField(name = "outSpaceRate", ordinal = 46)
+        private String outSpaceRate;
+
+        @JSONField(name = "outSpaceRateOrigin", ordinal = 47)
+        private String outSpaceRateOrigin;
+
+        @JSONField(name = "rateA10", ordinal = 48)
+        private String rateA10;
+
+        @JSONField(name = "rateA11", ordinal = 49)
+        private String rateA11;
+
+        @JSONField(name = "rateA12", ordinal = 50)
+        private String rateA12;
+
+        @JSONField(name = "rateA13", ordinal = 51)
+        private String rateA13;
+
+        @JSONField(name = "rateA14", ordinal = 52)
+        private String rateA14;
+
+        @JSONField(name = "rateA15", ordinal = 53)
+        private String rateA15;
+
+        @JSONField(name = "rateA4", ordinal = 54)
+        private String rateA4;
+
+        @JSONField(name = "rateA5", ordinal = 55)
+        private String rateA5;
+
+        @JSONField(name = "rateA7", ordinal = 56)
+        private String rateA7;
+
+        @JSONField(name = "rateA8", ordinal = 57)
+        private String rateA8;
+
+        @JSONField(name = "regulatoryTaxAmount", ordinal = 58)
+        private String regulatoryTaxAmount;
+
+        @JSONField(name = "regulatoryTaxDisrate", ordinal = 59)
+        private String regulatoryTaxDisrate;
+
+        @JSONField(name = "regulatoryTaxDisrateOrigin", ordinal = 60)
+        private String regulatoryTaxDisrateOrigin;
+
+        @JSONField(name = "remark", ordinal = 61)
+        private String remark;
+
+        @JSONField(name = "riskCode", ordinal = 62)
+        private String riskCode;
+
+        @JSONField(name = "saleAmount", ordinal = 63)
+        private String saleAmount;
+
+        @JSONField(name = "saleBaseAmount", ordinal = 64)
+        private String saleBaseAmount;
+
+        @JSONField(name = "saleBaseDisrate", ordinal = 65)
+        private String saleBaseDisrate;
+
+        @JSONField(name = "saleBaseDisrateOrigin", ordinal = 66)
+        private String saleBaseDisrateOrigin;
+
+        @JSONField(name = "saleDisrate", ordinal = 67)
+        private String saleDisrate;
+
+        @JSONField(name = "saleDisrateOrigin", ordinal = 68)
+        private String saleDisrateOrigin;
+
+        @JSONField(name = "salesBusinessPerAmount", ordinal = 69)
+        private String salesBusinessPerAmount;
+
+        @JSONField(name = "salesBusinessPerRate", ordinal = 70)
+        private String salesBusinessPerRate;
+
+        @JSONField(name = "salesManCostAmount", ordinal = 71)
+        private String salesManCostAmount;
+
+        @JSONField(name = "salesManCostRate", ordinal = 72)
+        private String salesManCostRate;
+
+        @JSONField(name = "salesManagementFeeAmount", ordinal = 73)
+        private String salesManagementFeeAmount;
+
+        @JSONField(name = "salesManagementFeeRate", ordinal = 74)
+        private String salesManagementFeeRate;
+
+        @JSONField(name = "salesStatus", ordinal = 75)
+        private String salesStatus;
+
+        @JSONField(name = "spaceAmount", ordinal = 76)
+        private String spaceAmount;
+
+        @JSONField(name = "spaceAmount1", ordinal = 77)
+        private String spaceAmount1;
+
+        @JSONField(name = "spaceRate", ordinal = 78)
+        private String spaceRate;
+
+        @JSONField(name = "spaceRate1", ordinal = 79)
+        private String spaceRate1;
+
+        @JSONField(name = "spaceRateOrigin", ordinal = 80)
+        private String spaceRateOrigin;
+
+        @JSONField(name = "sumPremium", ordinal = 81)
+        private String sumPremium;
+
+        @JSONField(name = "taxRate", ordinal = 82)
+        private String taxRate;
+
+        @JSONField(name = "totalFeeAmount", ordinal = 83)
+        private String totalFeeAmount;
+
+        @JSONField(name = "totalFeeDisrate", ordinal = 84)
+        private String totalFeeDisrate;
+
+        @JSONField(name = "totalFeeDisrateOrigin", ordinal = 85)
+        private String totalFeeDisrateOrigin;
+
+        @JSONField(name = "zsState", ordinal = 86)
+        private String zsState;
+    }
+
+    /**
+     * 支付计划
+     */
+    @Data
+    @NoArgsConstructor
+    public static class PayPlanVo implements Serializable {
+
+        @Serial
+        private static final long serialVersionUID = 1L;
+
+        @JSONField(name = "currency", ordinal = 1)
+        private String currency;
+
+        @JSONField(name = "noTaxAmount", ordinal = 2)
+        private String noTaxAmount;
+
+        @JSONField(name = "payEndDate", ordinal = 3)
+        private String payEndDate;
+
+        @JSONField(name = "payStartDate", ordinal = 4)
+        private String payStartDate;
+
+        @JSONField(name = "planFee", ordinal = 5)
+        private String planFee;
+
+        @JSONField(name = "riskCode", ordinal = 6)
+        private String riskCode;
+
+        @JSONField(name = "taxRateAmount", ordinal = 7)
+        private String taxRateAmount;
+    }
+
+    /**
+     * 风险信息
+     */
+    @Data
+    @NoArgsConstructor
+    public static class RiskInfo implements Serializable {
+
+        @Serial
+        private static final long serialVersionUID = 1L;
+
+        @JSONField(name = "carShipTaxInfo", ordinal = 1)
+        private CarShipTaxInfo carShipTaxInfo;
+
+        @JSONField(name = "commission", ordinal = 2)
+        private Commission commission;
+
+        @JSONField(name = "itemKindDetailList", ordinal = 3)
+        private List<Object> itemKindDetailList;
+
+        @JSONField(name = "itemKindList", ordinal = 4)
+        private List<ItemKind> itemKindList;
+
+        @JSONField(name = "platFormMessage", ordinal = 5)
+        private Map<String, Object> platFormMessage;
+
+        @JSONField(name = "riskMainInfo", ordinal = 6)
+        private RiskMainInfo riskMainInfo;
+    }
+
+    /**
+     * 车船税信息
+     */
+    @Data
+    @NoArgsConstructor
+    public static class CarShipTaxInfo implements Serializable {
+
+        @Serial
+        private static final long serialVersionUID = 1L;
+
+        @JSONField(name = "areacode", ordinal = 1)
+        private String areacode;
+
+        @JSONField(name = "baseTaxation", ordinal = 2)
+        private String baseTaxation;
+
+        @JSONField(name = "calPaybalanceFeeFlag", ordinal = 3)
+        private String calPaybalanceFeeFlag;
+
+        @JSONField(name = "calcTaxFlag", ordinal = 4)
+        private String calcTaxFlag;
+
+        @JSONField(name = "calculateFlag", ordinal = 5)
+        private String calculateFlag;
+
+        @JSONField(name = "calculateMode", ordinal = 6)
+        private String calculateMode;
+
+        @JSONField(name = "calfeeFlag", ordinal = 7)
+        private String calfeeFlag;
+
+        @JSONField(name = "callateFeeFlag", ordinal = 8)
+        private String callateFeeFlag;
+
+        @JSONField(name = "carKindCode", ordinal = 9)
+        private String carKindCode;
+
+        @JSONField(name = "carOwnerCertiCode", ordinal = 10)
+        private String carOwnerCertiCode;
+
+        @JSONField(name = "carOwnerCertiType", ordinal = 11)
+        private String carOwnerCertiType;
+
+        @JSONField(name = "certificateDate", ordinal = 12)
+        private String certificateDate;
+
+        @JSONField(name = "completeKerbmass", ordinal = 13)
+        private String completeKerbmass;
+
+        @JSONField(name = "documentNumber", ordinal = 14)
+        private String documentNumber;
+
+        @JSONField(name = "exemptionReason", ordinal = 15)
+        private String exemptionReason;
+
+        @JSONField(name = "extendChar1", ordinal = 16)
+        private String extendChar1;
+
+        @JSONField(name = "extendChar2", ordinal = 17)
+        private String extendChar2;
+
+        @JSONField(name = "extendDate1", ordinal = 18)
+        private String extendDate1;
+
+        @JSONField(name = "extendDate2", ordinal = 19)
+        private String extendDate2;
+
+        @JSONField(name = "extendNum1", ordinal = 20)
+        private String extendNum1;
+
+        @JSONField(name = "extendNum2", ordinal = 21)
+        private String extendNum2;
+
+        @JSONField(name = "finalFlag", ordinal = 22)
+        private String finalFlag;
+
+        @JSONField(name = "freeRate", ordinal = 23)
+        private String freeRate;
+
+        @JSONField(name = "freeRateText", ordinal = 24)
+        private String freeRateText;
+
+        @JSONField(name = "fuelType", ordinal = 25)
+        private String fuelType;
+
+        @JSONField(name = "hisPolicyEndDate", ordinal = 26)
+        private String hisPolicyEndDate;
+
+        @JSONField(name = "identifyNumber", ordinal = 27)
+        private String identifyNumber;
+
+        @JSONField(name = "lateFee", ordinal = 28)
+        private String lateFee;
+
+        @JSONField(name = "lateFeeEndDate", ordinal = 29)
+        private String lateFeeEndDate;
+
+        @JSONField(name = "lateFeeStartDate", ordinal = 30)
+        private String lateFeeStartDate;
+
+        @JSONField(name = "leviedDate", ordinal = 31)
+        private String leviedDate;
+
+        @JSONField(name = "licenseno", ordinal = 32)
+        private String licenseno;
+
+        @JSONField(name = "licensetype", ordinal = 33)
+        private String licensetype;
+
+        @JSONField(name = "paidFreeCertificate", ordinal = 34)
+        private String paidFreeCertificate;
+
+        @JSONField(name = "payEndDate", ordinal = 35)
+        private String payEndDate;
+
+        @JSONField(name = "payLastYear", ordinal = 36)
+        private String payLastYear;
+
+        @JSONField(name = "payLastYearEnd", ordinal = 37)
+        private String payLastYearEnd;
+
+        @JSONField(name = "payStartDate", ordinal = 38)
+        private String payStartDate;
+
+        @JSONField(name = "payTaxTimes", ordinal = 39)
+        private String payTaxTimes;
+
+        @JSONField(name = "previousPay", ordinal = 40)
+        private String previousPay;
+
+        @JSONField(name = "relifReason", ordinal = 41)
+        private String relifReason;
+
+        @JSONField(name = "riskCode", ordinal = 42)
+        private String riskCode;
+
+        @JSONField(name = "sumPayTax", ordinal = 43)
+        private String sumPayTax;
+
+        @JSONField(name = "taxActual", ordinal = 44)
+        private String taxActual;
+
+        @JSONField(name = "taxAmendDeclare", ordinal = 45)
+        private String taxAmendDeclare;
+
+        @JSONField(name = "taxAmountFlag", ordinal = 46)
+        private String taxAmountFlag;
+
+        @JSONField(name = "taxComCode", ordinal = 47)
+        private String taxComCode;
+
+        @JSONField(name = "taxComName", ordinal = 48)
+        private String taxComName;
+
+        @JSONField(name = "taxDocumentDate", ordinal = 49)
+        private String taxDocumentDate;
+
+        @JSONField(name = "taxDue", ordinal = 50)
+        private String taxDue;
+
+        @JSONField(name = "taxFlag", ordinal = 51)
+        private String taxFlag;
+
+        @JSONField(name = "taxItemCode", ordinal = 52)
+        private String taxItemCode;
+
+        @JSONField(name = "taxItemDetailCode", ordinal = 53)
+        private String taxItemDetailCode;
+
+        @JSONField(name = "taxItemDetailName", ordinal = 54)
+        private String taxItemDetailName;
+
+        @JSONField(name = "taxItemName", ordinal = 55)
+        private String taxItemName;
+
+        @JSONField(name = "taxPaidAreaCode", ordinal = 56)
+        private String taxPaidAreaCode;
+
+        @JSONField(name = "taxPayerCode", ordinal = 57)
+        private String taxPayerCode;
+
+        @JSONField(name = "taxPayerIdentifier", ordinal = 58)
+        private String taxPayerIdentifier;
+
+        @JSONField(name = "taxPayerName", ordinal = 59)
+        private String taxPayerName;
+
+        @JSONField(name = "taxPrintNo", ordinal = 60)
+        private String taxPrintNo;
+
+        @JSONField(name = "taxRelief", ordinal = 61)
+        private String taxRelief;
+
+        @JSONField(name = "taxRelifFlag", ordinal = 62)
+        private String taxRelifFlag;
+
+        @JSONField(name = "taxUnit", ordinal = 63)
+        private String taxUnit;
+
+        @JSONField(name = "taxUnitText", ordinal = 64)
+        private String taxUnitText;
+
+        @JSONField(name = "transactionNo", ordinal = 65)
+        private String transactionNo;
+
+        @JSONField(name = "vehicleStyle", ordinal = 66)
+        private String vehicleStyle;
+    }
+
+    /**
+     * 佣金信息
+     */
+    @Data
+    @NoArgsConstructor
+    public static class Commission implements Serializable {
+
+        @Serial
+        private static final long serialVersionUID = 1L;
+
+        @JSONField(name = "comCodeFlg", ordinal = 1)
+        private String comCodeFlg;
+
+        @JSONField(name = "currency", ordinal = 2)
+        private String currency;
+
+        @JSONField(name = "dimensionCode", ordinal = 3)
+        private String dimensionCode;
+
+        @JSONField(name = "disAmount", ordinal = 4)
+        private String disAmount;
+
+        @JSONField(name = "disFee", ordinal = 5)
+        private String disFee;
+
+        @JSONField(name = "disRate", ordinal = 6)
+        private String disRate;
+
+        @JSONField(name = "efftAmount", ordinal = 7)
+        private String efftAmount;
+
+        @JSONField(name = "efftRate", ordinal = 8)
+        private String efftRate;
+
+        @JSONField(name = "flag", ordinal = 9)
+        private String flag;
+
+        @JSONField(name = "generateDate", ordinal = 10)
+        private String generateDate;
+
+        @JSONField(name = "inSpaceAmount", ordinal = 11)
+        private String inSpaceAmount;
+
+        @JSONField(name = "inSpaceRate", ordinal = 12)
+        private String inSpaceRate;
+
+        @JSONField(name = "incAount", ordinal = 13)
+        private String incAount;
+
+        @JSONField(name = "incRate", ordinal = 14)
+        private String incRate;
+
+        @JSONField(name = "otherAmount", ordinal = 15)
+        private String otherAmount;
+
+        @JSONField(name = "otherRate", ordinal = 16)
+        private String otherRate;
+
+        @JSONField(name = "outSpaceAmount", ordinal = 17)
+        private String outSpaceAmount;
+
+        @JSONField(name = "outSpaceRate", ordinal = 18)
+        private String outSpaceRate;
+
+        @JSONField(name = "remark", ordinal = 19)
+        private String remark;
+
+        @JSONField(name = "riskCode", ordinal = 20)
+        private String riskCode;
+
+        @JSONField(name = "selfRate", ordinal = 21)
+        private String selfRate;
+
+        @JSONField(name = "spaceAmount", ordinal = 22)
+        private String spaceAmount;
+
+        @JSONField(name = "spaceRate", ordinal = 23)
+        private String spaceRate;
+
+        @JSONField(name = "sumPremium", ordinal = 24)
+        private String sumPremium;
+    }
+
+    /**
+     * 险种信息
+     */
+    @Data
+    @NoArgsConstructor
+    public static class ItemKind implements Serializable {
+
+        @Serial
+        private static final long serialVersionUID = 1L;
+
+        @JSONField(name = "adjustRate", ordinal = 1)
+        private String adjustRate;
+
+        @JSONField(name = "amount", ordinal = 2)
+        private String amount;
+
+        @JSONField(name = "basePremium", ordinal = 3)
+        private String basePremium;
+
+        @JSONField(name = "baseRiskPremium", ordinal = 4)
+        private String baseRiskPremium;
+
+        @JSONField(name = "benchMarkPremium", ordinal = 5)
+        private String benchMarkPremium;
+
+        @JSONField(name = "deductibleRatio", ordinal = 6)
+        private String deductibleRatio;
+
+        @JSONField(name = "discount", ordinal = 7)
+        private String discount;
+
+        @JSONField(name = "itemKindNo", ordinal = 8)
+        private String itemKindNo;
+
+        @JSONField(name = "kindCode", ordinal = 9)
+        private String kindCode;
+
+        @JSONField(name = "kindName", ordinal = 10)
+        private String kindName;
+
+        @JSONField(name = "noTaxAmount", ordinal = 11)
+        private String noTaxAmount;
+
+        @JSONField(name = "premium", ordinal = 12)
+        private String premium;
+
+        @JSONField(name = "proposedPremium", ordinal = 13)
+        private String proposedPremium;
+
+        @JSONField(name = "rate", ordinal = 14)
+        private String rate;
+
+        @JSONField(name = "riskCode", ordinal = 15)
+        private String riskCode;
+
+        @JSONField(name = "shortRate", ordinal = 16)
+        private String shortRate;
+
+        @JSONField(name = "taxAmount", ordinal = 17)
+        private String taxAmount;
+    }
+
+    /**
+     * 风险主要信息
+     */
+    @Data
+    @NoArgsConstructor
+    public static class RiskMainInfo implements Serializable {
+
+        @Serial
+        private static final long serialVersionUID = 1L;
+
+        @JSONField(name = "adjustCoefficient", ordinal = 1)
+        private String adjustCoefficient;
+
+        @JSONField(name = "adjustDiscount", ordinal = 2)
+        private String adjustDiscount;
+
+        @JSONField(name = "calculateType", ordinal = 3)
+        private String calculateType;
+
+        @JSONField(name = "channelCoefficient", ordinal = 4)
+        private String channelCoefficient;
+
+        @JSONField(name = "channelCoefficientVariation", ordinal = 5)
+        private String channelCoefficientVariation;
+
+        @JSONField(name = "ciBiInputDate", ordinal = 6)
+        private String ciBiInputDate;
+
+        @JSONField(name = "ciBiOperateDate", ordinal = 7)
+        private String ciBiOperateDate;
+
+        @JSONField(name = "ciBiSignDate", ordinal = 8)
+        private String ciBiSignDate;
+
+        @JSONField(name = "coefficientFlucValue", ordinal = 9)
+        private String coefficientFlucValue;
+
+        @JSONField(name = "contractNo", ordinal = 10)
+        private String contractNo;
+
+        @JSONField(name = "discount", ordinal = 11)
+        private String discount;
+
+        @JSONField(name = "expectLossRate", ordinal = 12)
+        private String expectLossRate;
+
+        @JSONField(name = "fixPriceStatus", ordinal = 13)
+        private String fixPriceStatus;
+
+        @JSONField(name = "lastYearAdjustValue", ordinal = 14)
+        private String lastYearAdjustValue;
+
+        @JSONField(name = "ncdCoefficient", ordinal = 15)
+        private String ncdCoefficient;
+
+        @JSONField(name = "noTaxAmount", ordinal = 16)
+        private String noTaxAmount;
+
+        @JSONField(name = "pictureVerificationBaseCode", ordinal = 17)
+        private String pictureVerificationBaseCode;
+
+        @JSONField(name = "priceId", ordinal = 18)
+        private String priceId;
+
+        @JSONField(name = "pricingAdjustValue", ordinal = 19)
+        private String pricingAdjustValue;
+
+        @JSONField(name = "querySequenceNo", ordinal = 20)
+        private String querySequenceNo;
+
+        @JSONField(name = "reCusAdjustValue", ordinal = 21)
+        private String reCusAdjustValue;
+
+        @JSONField(name = "reCustomerType", ordinal = 22)
+        private String reCustomerType;
+
+        @JSONField(name = "reInsuranceFlag", ordinal = 23)
+        private String reInsuranceFlag;
+
+        @JSONField(name = "riskCode", ordinal = 24)
+        private String riskCode;
+
+        @JSONField(name = "ruleDescription", ordinal = 25)
+        private String ruleDescription;
+
+        @JSONField(name = "successFlag", ordinal = 26)
+        private String successFlag;
+
+        @JSONField(name = "suggestedPricingAdjustValue", ordinal = 27)
+        private String suggestedPricingAdjustValue;
+
+        @JSONField(name = "sumAmount", ordinal = 28)
+        private String sumAmount;
+
+        @JSONField(name = "sumDiscount", ordinal = 29)
+        private String sumDiscount;
+
+        @JSONField(name = "sumPremium", ordinal = 30)
+        private String sumPremium;
+
+        @JSONField(name = "sumSubPrem", ordinal = 31)
+        private String sumSubPrem;
+
+        @JSONField(name = "taxAmount", ordinal = 32)
+        private String taxAmount;
+
+        @JSONField(name = "totalRiskPremium", ordinal = 33)
+        private String totalRiskPremium;
+
+        @JSONField(name = "tradeID", ordinal = 34)
+        private String tradeID;
+
+        @JSONField(name = "trafficViolationCoefficient", ordinal = 35)
+        private String trafficViolationCoefficient;
+
+        @JSONField(name = "underwritingCoefficient", ordinal = 36)
+        private String underwritingCoefficient;
+
+        @JSONField(name = "underwritingCoefficientVariation", ordinal = 37)
+        private String underwritingCoefficientVariation;
+    }
+}

+ 8 - 0
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/entity/response/BoHaiCrawlerVehicleConfirmationResponse2.java

@@ -9,8 +9,12 @@ import java.util.List;
 @Data
 public class BoHaiCrawlerVehicleConfirmationResponse2 {
 
+    /**
+     * 车型信息对象
+     */
     private Object carModelVo;
 
+
     private List<Object> carQueryBackBJList;
 
     private CiInsuredemandVo ciInsuredemandVo;
@@ -261,6 +265,10 @@ public class BoHaiCrawlerVehicleConfirmationResponse2 {
         private String manufactureCompanyCode;
         private String marketDate;
         private String modeCode;
+
+        /**
+        * 车型代码
+         */
         private String modelCode;
         private String modelDesc;
         private String modelEnergyType;

+ 2 - 3
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/service/BoHaiCrawlerOrderService.java

@@ -1,8 +1,7 @@
 package com.jzg.quotation.bohai.crawler.service;
-
 import com.jzg.commons.entity.quote.vo.QuoteVo;
 import com.jzg.quotation.bohai.crawler.entity.po.BoHaiCrawlerOrder;
-import com.jzg.quotation.bohai.crawler.entity.response.BoHaiCrawlerQuotationResponse;
+import com.jzg.quotation.bohai.crawler.entity.response.BoHaiCrawlerQuotationResponse2;
 
 /**
  * @description: 渤海财险爬虫订单服务
@@ -17,7 +16,7 @@ public interface BoHaiCrawlerOrderService {
      * @param boHaiCrawlerQuotationResponse
      * @param success
      */
-    void save(QuoteVo quoteVo, BoHaiCrawlerQuotationResponse boHaiCrawlerQuotationResponse, boolean success);
+    void save(QuoteVo quoteVo, BoHaiCrawlerQuotationResponse2 boHaiCrawlerQuotationResponse, boolean success);
 
     BoHaiCrawlerOrder getById(String ordersNo);
 

+ 37 - 19
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/service/impl/BoHaiCrawlerOrderServiceImpl.java

@@ -1,14 +1,19 @@
 package com.jzg.quotation.bohai.crawler.service.impl;
 
+import com.alibaba.fastjson.JSON;
 import com.jzg.commons.entity.quote.vo.QuoteVo;
 import com.jzg.quotation.bohai.crawler.entity.po.BoHaiCrawlerOrder;
 import com.jzg.quotation.bohai.crawler.entity.response.BoHaiCrawlerQuotationResponse;
+import com.jzg.quotation.bohai.crawler.entity.response.BoHaiCrawlerQuotationResponse2;
 import com.jzg.quotation.bohai.crawler.repository.BoHaiCrawlerOrderRepository;
 import com.jzg.quotation.bohai.crawler.service.BoHaiCrawlerOrderService;
 import lombok.RequiredArgsConstructor;
+import lombok.extern.slf4j.Slf4j;
 import org.springframework.stereotype.Service;
 
 import java.time.LocalDateTime;
+import java.time.ZoneId;
+import java.time.ZonedDateTime;
 
 /**
  * @description: 渤海财险爬虫订单服务实现
@@ -17,35 +22,48 @@ import java.time.LocalDateTime;
  **/
 @Service
 @RequiredArgsConstructor
+@Slf4j
 public class BoHaiCrawlerOrderServiceImpl implements BoHaiCrawlerOrderService {
 
     private final BoHaiCrawlerOrderRepository boHaiCrawlerOrderRepository;
 
     @Override
-    public void save(QuoteVo quoteVo, BoHaiCrawlerQuotationResponse boHaiCrawlerQuotationResponse, boolean success) {
+    public void save(QuoteVo quoteVo, BoHaiCrawlerQuotationResponse2 boHaiCrawlerQuotationResponse, boolean success) {
         BoHaiCrawlerOrder order = new BoHaiCrawlerOrder();
         order.setOrdersNo(quoteVo.getOrder().getOrdersNo());
-        order.setOrderNo(boHaiCrawlerQuotationResponse.getData().getBusUniqueId());
-        order.setBusUniqueId(boHaiCrawlerQuotationResponse.getData().getBusUniqueId());
+        order.setOrderNo("");
+        order.setBusUniqueId("");
         order.setQuoteSuccess(success);
+        // 报价失败
+        if(!success){
+            // 交强险
+            order.setCiApplyNo("");
+            order.setCiPremium("");
+            // 商业险
+            order.setSyApplyNo("");
+            order.setBiPremium("");
 
-        if (boHaiCrawlerQuotationResponse.getData().getTrafficPolicy() != null) {
-            order.setCiApplyNo(boHaiCrawlerQuotationResponse.getData().getTrafficPolicy().getApplicationNo());
-            order.setCiPremium(boHaiCrawlerQuotationResponse.getData().getTrafficPolicy().getPremium());
-        }
-
-        if (boHaiCrawlerQuotationResponse.getData().getBusinessPolicy() != null) {
-            order.setSyApplyNo(boHaiCrawlerQuotationResponse.getData().getBusinessPolicy().getApplicationNo());
-            order.setBiPremium(boHaiCrawlerQuotationResponse.getData().getBusinessPolicy().getPremium());
-        }
-
-        order.setTotalPremium(boHaiCrawlerQuotationResponse.getData().getPremium());
-        order.setCreateTime(LocalDateTime.now());
-        order.setUpdateTime(LocalDateTime.now());
-
-        if (!success) {
-            order.setErrorMsg(boHaiCrawlerQuotationResponse.getResponseMsg());
+            order.setTotalPremium("");
+            order.setCreateTime(LocalDateTime.now());
+            order.setUpdateTime(LocalDateTime.now());
+            order.setErrorMsg(boHaiCrawlerQuotationResponse.getHead().getReturnMessage());
+        }else{
+            // 交强险
+            if (boHaiCrawlerQuotationResponse.getBusinessData().getFeeControlInfoList().get(0) != null) {
+                order.setCiApplyNo("");
+                order.setCiPremium(boHaiCrawlerQuotationResponse.getBusinessData().getFeeControlInfoList().get(0).getSumPremium());
+            }
+            // 商业险
+            if (boHaiCrawlerQuotationResponse.getBusinessData().getFeeControlInfoList().get(1) != null) {
+                order.setSyApplyNo("");
+                order.setBiPremium(boHaiCrawlerQuotationResponse.getBusinessData().getFeeControlInfoList().get(1).getSumPremium());
+            }
+            order.setTotalPremium(boHaiCrawlerQuotationResponse.getBusinessData().getBusinessMainInfo().getSumPremium());
+            order.setCreateTime(LocalDateTime.now());
+            order.setUpdateTime(LocalDateTime.now());
+            order.setErrorMsg(boHaiCrawlerQuotationResponse.getHead().getReturnMessage());
         }
+        log.info("order对象的值:{}", JSON.toJSONString(order));
         boHaiCrawlerOrderRepository.save(order);
     }
 

+ 23 - 2
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/service/impl/BoHaiCrawlerQuoteProcessServiceImpl.java

@@ -37,9 +37,9 @@ public class BoHaiCrawlerQuoteProcessServiceImpl implements BoHaiCrawlerQuotePro
     private static final String BOHAI_SESSION_ID_KEY = "bohai:crawler:sessionId";
 
     /**
-     * sessionId缓存过期时间(秒)- 设置为2小时
+     * sessionId缓存过期时间(秒)- 设置为2分钟
      */
-    private static final long SESSION_ID_EXPIRE_SECONDS = 2 * 60 * 60;
+    private static final long SESSION_ID_EXPIRE_SECONDS = 2 * 60;
 
     /**
      * Python脚本路径
@@ -183,4 +183,25 @@ public class BoHaiCrawlerQuoteProcessServiceImpl implements BoHaiCrawlerQuotePro
         log.info("sessionId已存入Redis缓存,过期时间: {}秒", SESSION_ID_EXPIRE_SECONDS);
         return sessionId;
     }
+
+
+    /**
+     * 获取sessionId
+     * 调用Python脚本获取sessionId
+     *
+     * @return sessionId字符串
+     */
+    private String getSessionId() {
+        String sessionId = PythonExecutor.executeAndGetSessionId(
+                PYTHON_SCRIPT_PATH,
+                PYTHON_EXECUTABLE_PATH,
+                PYTHON_EXECUTION_TIMEOUT
+        );
+        // 校验获取结果
+        if (!StringUtils.hasLength(sessionId)) {
+            log.error("调用Python脚本获取sessionId失败");
+            throw new SystemException("获取sessionId失败");
+        }
+        return sessionId;
+    }
 }

Разница между файлами не показана из-за своего большого размера
+ 862 - 346
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/service/impl/BoHaiCrawlerRequestImpl.java


+ 1 - 1
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/util/BatchNumberGenerator.java

@@ -20,7 +20,7 @@ public final class BatchNumberGenerator {
      * 生成32位批次号
      * 使用UUID去除横线后的32位字符作为批次号
      *
-     * @return 32位批次号字符串
+     * @return String 32位批次号字符串
      */
     public static String generateBatchNumber() {
         String uuid = UUID.randomUUID().toString();

+ 25 - 0
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/util/DateTimeUtils.java

@@ -1,12 +1,16 @@
 package com.jzg.quotation.bohai.crawler.util;
 
+import java.time.Instant;
 import java.time.LocalDate;
 import java.time.format.DateTimeFormatter;
+import java.time.temporal.ChronoUnit;
 
 public class DateTimeUtils {
 
     private static final DateTimeFormatter DATE_FORMATTER = DateTimeFormatter.ofPattern("yyyy-MM-dd");
 
+    private static final DateTimeFormatter DATE_FORMATTER1 = DateTimeFormatter.ofPattern("yyyyMM");
+
     /**
      * 获取当前日期
      *
@@ -15,4 +19,25 @@ public class DateTimeUtils {
     public static String getCurrentDate() {
         return LocalDate.now().format(DATE_FORMATTER);
     }
+
+    public static String getCurrentTime() {
+        return Instant.now()
+                .truncatedTo(ChronoUnit.MILLIS)
+                .toString();
+    }
+
+    /**
+     * 获取当前日期
+     *
+     * @return 当前日期字符串,格式:yyyyMM
+     */
+    public static String getCurrentDate1() {
+        return LocalDate.now().format(DATE_FORMATTER1);
+    }
+
+
+    public static void main(String[] args) {
+        //System.out.println(getCurrentTime());
+        System.out.println(getCurrentDate1());
+    }
 }

+ 24 - 0
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/util/OrderNoGenerator.java

@@ -0,0 +1,24 @@
+package com.jzg.quotation.bohai.crawler.util;
+import java.time.LocalDateTime;
+import java.time.format.DateTimeFormatter;
+import java.util.concurrent.ThreadLocalRandom;
+
+public class OrderNoGenerator {
+
+    private static final String PREFIX = "O14070330";
+    private static final DateTimeFormatter FORMATTER = DateTimeFormatter.ofPattern("yyyyMM");
+
+    /**
+     * 生成订单号
+     * @return String
+     */
+    public static String generate() {
+        String yearMonth = LocalDateTime.now().format(FORMATTER);
+        String randomSuffix = String.format("%04d", ThreadLocalRandom.current().nextInt(0, 10000));
+        return PREFIX + yearMonth + randomSuffix;
+    }
+
+    public static void main(String[] args) {
+        System.out.println(generate());
+    }
+}

+ 3 - 9
tenant/insurance/quotation-bohai/src/main/java/com/jzg/quotation/bohai/crawler/util/PythonExecutor.java

@@ -112,7 +112,6 @@ public class PythonExecutor {
 
         try {
             process = processBuilder.start();
-
             // 读取输出流
             try (BufferedReader reader = new BufferedReader(
                     new InputStreamReader(process.getInputStream(), StandardCharsets.UTF_8))) {
@@ -122,7 +121,6 @@ public class PythonExecutor {
                     log.debug("Python输出: {}", line);
                 }
             }
-
             // 等待进程完成
             boolean finished = process.waitFor(timeoutSeconds, TimeUnit.SECONDS);
             if (!finished) {
@@ -130,16 +128,13 @@ public class PythonExecutor {
                 process.destroyForcibly();
                 return null;
             }
-
             int exitCode = process.exitValue();
             if (exitCode != 0) {
                 log.error("Python脚本执行失败,退出码: {}", exitCode);
                 return null;
             }
-
             log.info("Python脚本执行完成");
             return output.toString();
-
         } catch (Exception e) {
             log.error("执行Python脚本时发生异常", e);
             return null;
@@ -246,13 +241,12 @@ public class PythonExecutor {
             String jsonStr = output.substring(jsonStart + 1, jsonEnd);
             // 解析JSON并获取sessionId
             JSONObject jsonObject = JSON.parseObject(jsonStr);
-            String sessionId = jsonObject.getString("token");
-
-            if (sessionId == null || sessionId.isEmpty()) {
+            String token = jsonObject.getString("token");
+            if (token == null || token.isEmpty()) {
                 log.error("JSON中未找到token字段");
                 return null;
             }
-            return sessionId;
+            return token;
         } catch (Exception e) {
             log.error("解析token时发生异常", e);
             return null;

+ 41 - 4
tenant/insurance/quotation-commons/src/main/java/com/jzg/quotation/commons/component/RequestComponent.java

@@ -439,8 +439,7 @@ public class RequestComponent {
             if (responseBody == null) {
                 responseBody = "";
             }
-            // 处理响应:过滤非法字符并解析JSON
-            //String filteredResponse = filterIllegalCharacters(responseBody);
+
             Response result;
             // 判断返回的字符串是否为有效的JSON格式
             if (isValidJson(responseBody)) {
@@ -850,16 +849,54 @@ public class RequestComponent {
     }
 
     /**
-     * 请求体为 object POST请求返回响应返回类
+     * 请求体为 object POST请求返回响应返回类(支持文件上传)
      *
      * @param url           请求地址
      * @param body          请求体
      * @param responseClass 响应返回类
      * @param headers       请求头
      * @param <Response>    响应返回
-     * @return 响应
+     * @return <Response> ResponseEntity<Response> 响应
      */
+    @SuppressWarnings("unchecked")
     public <Response> ResponseEntity<Response> objectPostForUpload(String url, Object body, Class<Response> responseClass, HttpHeaders headers) {
+        // 如果是MultiValueMap类型,使用 multipart 方式发送(用于文件上传)
+        if (body instanceof MultiValueMap) {
+            MultiValueMap<String, Object> formData = (MultiValueMap<String, Object>) body;
+            WebClient webClient = selectNoSSLWebClient2();
+
+            HttpHeaders requestHeaders = new HttpHeaders();
+            if (headers != null) {
+                requestHeaders.addAll(headers);
+            }
+            requestHeaders.remove("Accept-Encoding");
+
+            log.info("文件上传URL的值:{}", url);
+            ResponseEntity<String> rawResponse = webClient.post()
+                    .uri(url)
+                    .headers(setHeaders(requestHeaders))
+                    .contentType(MediaType.MULTIPART_FORM_DATA)
+                    .body(BodyInserters.fromMultipartData(formData))
+                    .retrieve()
+                    .toEntity(String.class)
+                    .block();
+
+            if (rawResponse == null) {
+                throw new WebClientResponseException(500, "No response received", HttpHeaders.EMPTY, "No response received".getBytes(StandardCharsets.UTF_8), null);
+            }
+
+            String responseBody = rawResponse.getBody();
+            Response result;
+            if (responseBody != null && isValidJson(responseBody)) {
+                result = JSON.parseObject(responseBody, responseClass);
+            } else {
+                result = (Response) responseBody;
+            }
+            HttpHeaders responseHeaders = new HttpHeaders();
+            responseHeaders.setContentType(MediaType.APPLICATION_JSON);
+            return ResponseEntity.status(rawResponse.getStatusCode()).headers(responseHeaders).body(result);
+        }
+        // 非 MultiValueMap 类型,走原来的逻辑
         return post(url, body, responseClass, headers);
     }
 

+ 33 - 0
tenant/insurance/quotation-commons/src/main/java/com/jzg/quotation/commons/config/MongoConfig.java

@@ -4,11 +4,18 @@ package com.jzg.quotation.commons.config;
 import lombok.extern.slf4j.Slf4j;
 import org.springframework.context.annotation.Bean;
 import org.springframework.context.annotation.Configuration;
+import org.springframework.core.convert.converter.Converter;
 import org.springframework.data.mongodb.MongoDatabaseFactory;
 import org.springframework.data.mongodb.core.convert.DefaultDbRefResolver;
 import org.springframework.data.mongodb.core.convert.DefaultMongoTypeMapper;
 import org.springframework.data.mongodb.core.convert.MappingMongoConverter;
+import org.springframework.data.mongodb.core.convert.MongoCustomConversions;
 import org.springframework.data.mongodb.core.mapping.MongoMappingContext;
+import java.time.LocalDateTime;
+import java.time.ZoneId;
+import java.util.ArrayList;
+import java.util.Date;
+import java.util.List;
 
 /**
  * @description: Mongodb 配置类
@@ -29,7 +36,33 @@ public class MongoConfig {
                 context
         );
         converter.setTypeMapper(typeMapper);
+        converter.setCustomConversions(mongoCustomConversions());
+        converter.afterPropertiesSet();
         return converter;
     }
 
+    @Bean
+    public MongoCustomConversions mongoCustomConversions() {
+        List<Converter<?, ?>> converters = new ArrayList<>();
+        converters.add(new DateToLocalDateTimeConverter());
+        converters.add(new LocalDateTimeToDateConverter());
+        return new MongoCustomConversions(converters);
+    }
+
+    // 读取时:UTC Date → 北京时间 LocalDateTime
+    static class DateToLocalDateTimeConverter implements Converter<Date, LocalDateTime> {
+        @Override
+        public LocalDateTime convert(Date source) {
+            return source.toInstant().atZone(ZoneId.of("Asia/Shanghai")).toLocalDateTime();
+        }
+    }
+
+    // 写入时:北京时间 LocalDateTime → UTC Date
+    static class LocalDateTimeToDateConverter implements Converter<LocalDateTime, Date> {
+        @Override
+        public Date convert(LocalDateTime source) {
+            return Date.from(source.atZone(ZoneId.of("Asia/Shanghai")).toInstant());
+        }
+    }
+
 }

+ 0 - 2
tenant/insurance/quotation-summary/src/main/java/com/jzg/quotation/summary/SummaryQuotationApplication.java

@@ -10,8 +10,6 @@ import org.springframework.cloud.openfeign.EnableFeignClients;
 import org.springframework.context.annotation.ComponentScan;
 import org.springframework.data.mongodb.repository.config.EnableMongoRepositories;
 import org.springframework.data.mongodb.repository.support.SimpleMongoRepository;
-
-
 @SpringBootApplication(scanBasePackages = {"com.jzg"})
 @MapperScan({"com.jzg.quotation.summary.mapper", "com.jzg.commons.mapper"})
 @EnableFeignClients(basePackages = "com.jzg.quotation.commons.client")

+ 6 - 3
tenant/insurance/quotation-summary/src/main/java/com/jzg/quotation/summary/controller/UnifyOrderManager.java

@@ -289,7 +289,9 @@ public class UnifyOrderManager {
     public HttpResult underwriting(@RequestBody UnderwritingVo underwritingVo) throws Exception {
         //获取保司实体
         InsOrders insOrders = insOrdersService.getById(underwritingVo.getOrder().getOrdersNo());
+        log.info("insOrders对象的值:{}",JSON.toJSONString(insOrders));
         AssertionUtils.isFail(Objects.isNull(insOrders), "订单不存在");
+
         HttpResult<EsmInsCompany> esmInsCompanyHttpResult = platformClient.findById(insOrders.getCompanyId(), baseController.getToken());
         underwritingVo.getOrder().setInsuranceCompanyCode(esmInsCompanyHttpResult.getData().getCompanyCode());
         underwritingVo.getOrder().setInsuranceCompanyId(esmInsCompanyHttpResult.getData().getId());
@@ -386,8 +388,6 @@ public class UnifyOrderManager {
         paymentLinkVo.getOrder().setInsuranceCompanyCode(esmInsCompanyHttpResult.getData().getCompanyCode());
         paymentLinkVo.getOrder().setInsuranceCompanyId(esmInsCompanyHttpResult.getData().getId());
 
-        QuotationBaseService quoteService = companyFactory.getPaymentLinkService(insOrders, esmInsCompanyHttpResult.getData()
-                .getCompanyCode(), baseController, paymentLinkVo);
 
         List<InsOrdersCarUserInfo> insOrdersCarUserInfos = insOrdersCarUserInfoService.getByOrderId(insOrders.getId());
         InsOrdersPolicy insOrdersPolicy = insOrdersPolicyService.getById(insOrders.getId());
@@ -397,7 +397,10 @@ public class UnifyOrderManager {
         paymentLinkVo.setInsOrdersPolicy(insOrdersPolicy);
         paymentLinkVo.setInsOrdersCosts(insOrdersCosts);
 
-        // 生成支付链接
+        QuotationBaseService quoteService = companyFactory.getPaymentLinkService(insOrders, esmInsCompanyHttpResult.getData()
+                .getCompanyCode(), baseController, paymentLinkVo);
+
+        // 获取支付链接
         PaymentLinkResultsVo paymentLinkResultsVo = quoteService.getPaymentLink(paymentLinkVo);
         log.info("paymentLinkResultsVo对象的值:{}", JSON.toJSONString(paymentLinkResultsVo));
         if(Objects.isNull(paymentLinkResultsVo.getPaymentLink())){

+ 3 - 0
tenant/insurance/quotation-summary/src/main/java/com/jzg/quotation/summary/factory/CompanyFactory.java

@@ -1,6 +1,7 @@
 package com.jzg.quotation.summary.factory;
 
 import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson2.JSON;
 import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
 import com.jzg.commons.core.base.BaseController;
 import com.jzg.commons.core.page.HttpResult;
@@ -152,7 +153,9 @@ public class CompanyFactory {
         String token = baseController.getToken();
         String systemCode = baseController.getAppSystemCode();
         HttpResult<PtlAgreementAttribution> agreementAttribution = platformClient.getAgreementAttribution(insOrders.getAgreementId(), token, systemCode);
+        log.info("agreementAttribution对象的值:{}", JSON.toJSONString(agreementAttribution.getData()));
         AssertionUtils.isFail(agreementAttribution.getCode() == 500, "获取协议属性失败");
+
         Map<String, String> fieldMap = agreementAttribution.getData().getFields().stream()
                 .map(obj -> new JSONObject((Map<String, Object>) obj))  // 转换为 JSONObject
                 .collect(Collectors.toMap(

+ 3 - 1
tenant/insurance/quotation-summary/src/main/java/com/jzg/quotation/summary/state/OrderState.java

@@ -8,7 +8,9 @@ package com.jzg.quotation.summary.state;
 public class OrderState {
 
     public enum OrderStateEnum {
-        // 订单已提交
+        /**
+         * 订单已提交
+         */
         QUOTE_ING(0),
         // 待核保
         WAIT_AUDIT(1),

+ 1 - 3
tenant/insurance/quotation-summary/src/main/java/com/jzg/quotation/summary/state/listener/OrderStateListener.java

@@ -16,14 +16,12 @@ import org.springframework.statemachine.support.DefaultStateMachineContext;
 import org.springframework.stereotype.Component;
 import reactor.core.publisher.Flux;
 import reactor.core.publisher.Mono;
-
 import java.util.concurrent.atomic.AtomicBoolean;
 
 /**
  * @author quchen
  * @date 2025/2/26 10:57
  */
-
 @Component
 @Slf4j
 public class OrderStateListener {
@@ -182,7 +180,7 @@ public class OrderStateListener {
 
 
     public StateResult statusChange(InsOrderStatusEnum insOrderStatusEnum, String currentStatus) {
-        log.info("设置的订单状态:{},当前的订单状态:{}", insOrderStatusEnum,currentStatus);
+        log.info("设置的订单状态{},当前的订单状态:{}", insOrderStatusEnum,currentStatus);
         StateResult stateResult = new StateResult();
         switch(insOrderStatusEnum){
             //报价失败

Некоторые файлы не были показаны из-за большого количества измененных файлов