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

添加泰康 添加 SaveQuoteResult 结构

wlq 1 год назад
Родитель
Сommit
64c82c3f62

+ 2 - 0
tenant/insurance/quotation-taikang/src/main/java/com/jzg/quotation/taikang/client/HttpURL.java

@@ -55,4 +55,6 @@ public interface HttpURL {
      * 车船税接口
      */
     String agentTax = host + "/carSelfService/rest/agent/tax";
+
+    String saveQuote = host + "/carSelfService/rest/save/quote";
 }

+ 35 - 0
tenant/insurance/quotation-taikang/src/main/java/com/jzg/quotation/taikang/entity/SaveQuoteParam.java

@@ -0,0 +1,35 @@
+package com.jzg.quotation.taikang.entity;
+
+import com.jzg.quotation.taikang.client.UnknownFieldEntity;
+import lombok.Getter;
+import lombok.Setter;
+
+@Setter
+@Getter
+public class SaveQuoteParam extends UnknownFieldEntity {
+
+    /**
+     * 订单ID
+     */
+    private String orderID;
+
+    /**
+     * 渠道代码
+     */
+    private String channelCode;
+
+    /**
+     * 来源ID
+     */
+    private String fromID;
+
+    /**
+     * 报价标志
+     */
+    private String quoteFlag;
+
+    /**
+     * 平台ID
+     */
+    private String tplatformId;
+}

+ 346 - 0
tenant/insurance/quotation-taikang/src/main/java/com/jzg/quotation/taikang/entity/SaveQuoteResult.java

@@ -0,0 +1,346 @@
+package com.jzg.quotation.taikang.entity;
+
+import com.jzg.quotation.taikang.client.BaseResponse;
+import com.jzg.quotation.taikang.client.UnknownFieldEntity;
+import lombok.Getter;
+import lombok.Setter;
+
+import java.util.List;
+
+@Setter
+@Getter
+public class SaveQuoteResult extends UnknownFieldEntity {
+    public static final class Response extends BaseResponse<SaveQuoteResult> {
+    }
+
+    /**
+     * 省份名称
+     */
+    private String provinceName;
+
+    /**
+     * 省份代码
+     */
+    private String provinceCode;
+
+    /**
+     * 城市代码
+     */
+    private String cityCode;
+
+    /**
+     * 城市名称
+     */
+    private String cityName;
+
+    /**
+     * 北京标志
+     */
+    private String bjFlag;
+
+    /**
+     * 车牌号
+     */
+    private String licenseNo;
+
+    /**
+     * 车牌类型
+     */
+    private String licenseType;
+
+    /**
+     * 车牌类型中文名称
+     */
+    private String licenseTypeChinese;
+
+    /**
+     * 是否新车无牌
+     */
+    private String isNewCarWithoutLicense;
+
+    /**
+     * 电话号码
+     */
+    private String phoneNo;
+
+    /**
+     * 订单ID
+     */
+    private String orderID;
+
+    /**
+     * openID
+     */
+    private String openID;
+
+    /**
+     * 客户端类型
+     */
+    private String clientType;
+
+    /**
+     * 省份代码Code
+     */
+    private String provinceCodeCode;
+
+    /**
+     * 制造厂商
+     */
+    private String makeCom;
+
+    /**
+     * 操作代码
+     */
+    private String operateCode;
+
+    /**
+     * 公司代码
+     */
+    private String comCode;
+
+    /**
+     * 公司代码1
+     */
+    private String comCode1;
+
+    /**
+     * 区域标志
+     */
+    private String areaFlag;
+
+    /**
+     * 处理人代码
+     */
+    private String handlerCode;
+
+    /**
+     * 处理人1代码
+     */
+    private String handler1Code;
+
+    /**
+     * 疫情车辆
+     */
+    private String ecdemicVehicle;
+
+    /**
+     * 渠道代码
+     */
+    private String channelCode;
+
+    /**
+     * 表单ID
+     */
+    private String formID;
+
+    /**
+     * 内部员工ID
+     */
+    private String innerStaffID;
+
+    /**
+     * 设备类型
+     */
+    private String deviceType;
+
+    /**
+     * 车牌号前缀
+     */
+    private String licenseHead;
+
+    /**
+     * 车牌号主体
+     */
+    private String licenseBody;
+
+    /**
+     * 生命公司代码
+     */
+    private String lifeComCode;
+
+    /**
+     * 生命公司名称
+     */
+    private String lifeComName;
+
+    /**
+     * 生命代理人代码
+     */
+    private String lifeAgentCode;
+
+    /**
+     * 生命代理人名称
+     */
+    private String lifeAgentName;
+
+    /**
+     * 生命代理人电话
+     */
+    private String lifeAgentPhone;
+
+    /**
+     * 用户ID
+     */
+    private String userId;
+
+    /**
+     * 续保标志
+     */
+    private String renewalFlag;
+
+    /**
+     * 保险单号(财险)
+     */
+    private String policyNoCi;
+
+    /**
+     * 保险单号(自保)
+     */
+    private String policyNoBz;
+
+    /**
+     * 身份证号
+     */
+    private String identifyNum;
+
+    /**
+     * 编码Code
+     */
+    private String codeCode;
+
+    /**
+     * 渠道订单ID
+     */
+    private String channelOrderId;
+
+    /**
+     * 渠道用户ID
+     */
+    private String channelUserId;
+
+    /**
+     * 自保保单类型
+     */
+    private String bzPolicyType;
+
+    /**
+     * 财险保单类型
+     */
+    private String ciPolicyType;
+
+    /**
+     * 提案类型
+     */
+    private String proposalType;
+
+    /**
+     * 真实姓名
+     */
+    private String realName;
+
+    /**
+     * 发行代码
+     */
+    private String issueCode;
+
+    /**
+     * 县/区代码
+     */
+    private String countyCode;
+
+    /**
+     * 平台ID
+     */
+    private String tplatformId;
+
+    /**
+     * 省份Dto列表
+     */
+    private List<ProvinceDto> provinceDtoList;
+
+    /**
+     * 校验码信息
+     */
+    private String checkCodeMeg;
+
+    /**
+     * 代理人
+     */
+    private String agent;
+
+    /**
+     * 订单管理标志
+     */
+    private String orderManageFlag;
+
+    /**
+     * 江苏监管开关
+     */
+    private String jiangsuJgSwitch;
+
+    /**
+     * 是否直销标志
+     */
+    private String isDirectSaleFlag;
+
+    /**
+     * 蚂蚁模式
+     */
+    private String antMode;
+
+    /**
+     * 上级代理人编号
+     */
+    private String superiorAgentNo;
+
+    /**
+     * 上级代理人名称
+     */
+    private String superiorAgentName;
+
+    /**
+     * 上级代理人手机
+     */
+    private String superiorAgentMobile;
+
+    /**
+     * 网军标志
+     */
+    private String cyberArmyFlag;
+
+    /**
+     * 线索ID
+     */
+    private String leadsId;
+
+    /**
+     * 团购订单标志
+     */
+    private String groupOrderFlag;
+
+    /**
+     * 种子标志
+     */
+    private String seedFlag;
+
+    /**
+     * 车辆地址列表
+     */
+    private List<String> motorAddressList;
+
+    /**
+     * 代理人入职日期
+     */
+    private String agentEmployDate;
+
+    @Override
+    protected void addChildUnknownFields() {
+        addChildUnknownField("provinceDtoList", provinceDtoList);
+    }
+
+    @Setter
+    @Getter
+    public static class ProvinceDto extends UnknownFieldEntity {
+        // 根据实际情况添加 ProvinceDto 的字段
+    }
+}

+ 24 - 0
tenant/insurance/quotation-taikang/src/test/java/com/jzg/quotation/taikang/entity/SaveQuoteResultTest.java

@@ -0,0 +1,24 @@
+package com.jzg.quotation.taikang.entity;
+
+import com.jzg.quotation.taikang.JsonUtil;
+import org.junit.jupiter.api.Test;
+
+import java.util.Map;
+
+public class SaveQuoteResultTest {
+
+    @Test
+    public void test1() {
+        String json = """
+{ "status": "1", "data": { "provinceName": null, "provinceCode": null, "cityCode": null, "cityName": null, "bjFlag": null, "licenseNo": null, "licenseType": null, "licenseTypeChinese": null, "isNewCarWithoutLicense": null, "phoneNo": null, "orderID": "WBPC202503071419220680000", "openID": null, "clientType": null, "provinceCodeCode": null, "makeCom": null, "operateCode": null, "comCode": null, "comCode1": null, "areaFlag": null, "handlerCode": null, "handler1Code": null, "ecdemicVehicle": null, "channelCode": null, "formID": null, "innerStaffID": null, "deviceType": null, "licenseHead": null, "licenseBody": null, "lifeComCode": null, "lifeComName": null, "lifeAgentCode": null, "lifeAgentName": null, "lifeAgentPhone": null, "userId": null, "renewalFlag": null, "policyNoCi": null, "policyNoBz": null, "identifyNum": null, "codeCode": null, "channelOrderId": null, "channelUserId": null, "bzPolicyType": null, "ciPolicyType": null, "proposalType": null, "realName": null, "issueCode": null, "countyCode": null, "tplatformId": null, "provinceDtoList": null, "checkCodeMeg": null, "agent": null, "orderManageFlag": null, "jiangsuJgSwitch": null, "isDirectSaleFlag": null, "antMode": null, "superiorAgentNo": null, "superiorAgentName": null, "superiorAgentMobile": null, "cyberArmyFlag": null, "leadsId": null, "groupOrderFlag": null, "seedFlag": null, "motorAddressList": null, "agentEmployDate": null } }                
+""";
+
+        SaveQuoteResult.Response response = JsonUtil.readObjcet(json, SaveQuoteResult.Response.class);
+
+
+        Map<String, Object> unknownFields = response.getUnknownFields();
+
+        System.out.println("unknownFields: ");
+        System.out.println(unknownFields);
+    }
+}