|
@@ -27,6 +27,7 @@ import com.jzg.quotation.commons.constant.InsuranceCode;
|
|
|
import com.jzg.quotation.commons.standard.conversion.ConfigureParametersConversion;
|
|
import com.jzg.quotation.commons.standard.conversion.ConfigureParametersConversion;
|
|
|
import com.jzg.quotation.zijin.crawler.entity.request.*;
|
|
import com.jzg.quotation.zijin.crawler.entity.request.*;
|
|
|
import com.jzg.quotation.zijin.crawler.entity.response.*;
|
|
import com.jzg.quotation.zijin.crawler.entity.response.*;
|
|
|
|
|
+import com.jzg.quotation.zijin.crawler.service.ZiJinCrawlerRequest;
|
|
|
import lombok.RequiredArgsConstructor;
|
|
import lombok.RequiredArgsConstructor;
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
import org.springframework.http.HttpHeaders;
|
|
import org.springframework.http.HttpHeaders;
|
|
@@ -46,23 +47,23 @@ import java.util.*;
|
|
|
* @author
|
|
* @author
|
|
|
* @since
|
|
* @since
|
|
|
*/
|
|
*/
|
|
|
-@QuoteCrawlerService(value = InsuranceCode.INSURANCE_BPIC)
|
|
|
|
|
|
|
+@QuoteCrawlerService(value = InsuranceCode.INSURANCE_ZKIC)
|
|
|
@RequiredArgsConstructor
|
|
@RequiredArgsConstructor
|
|
|
@Slf4j
|
|
@Slf4j
|
|
|
-public class ZiJinCrawlerRequestImpl implements QuotationCrawlerBaseService {
|
|
|
|
|
|
|
+public class ZiJinCrawlerRequestImpl implements ZiJinCrawlerRequest {
|
|
|
|
|
|
|
|
- private final ZiJinCrawlerRequestComponent boHaiCrawlerRequestComponent;
|
|
|
|
|
|
|
+ private final ZiJinCrawlerRequestComponent ziJinCrawlerRequestComponent;
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
* 归属信息构建组件,用于构建机构、套餐、渠道等归属信息
|
|
* 归属信息构建组件,用于构建机构、套餐、渠道等归属信息
|
|
|
*/
|
|
*/
|
|
|
- private final ZiJinBuildingAttributionInformation boHaiBuildingAttributionInformation;
|
|
|
|
|
|
|
+ private final ZiJinBuildingAttributionInformation ziJinBuildingAttributionInformation;
|
|
|
|
|
|
|
|
- private final ZiJinCrawlerCacheComponent boHaiCrawlerCacheComponent;
|
|
|
|
|
|
|
+ private final ZiJinCrawlerCacheComponent ziJinCrawlerCacheComponent;
|
|
|
|
|
|
|
|
- private final ZiJinCrawlerOrderService boHaiCrawlerOrderService;
|
|
|
|
|
|
|
+ private final ZiJinCrawlerOrderService ziJinCrawlerOrderService;
|
|
|
|
|
|
|
|
- private final ZiJinCrawlerQuoteProcessService boHaiCrawlerQuoteProcessService;
|
|
|
|
|
|
|
+ private final ZiJinCrawlerQuoteProcessService ziJinCrawlerQuoteProcessService;
|
|
|
|
|
|
|
|
private static final String TOKEN = "114050281-ab12387d7bb7bd319ac3b7d4ddd22090";
|
|
private static final String TOKEN = "114050281-ab12387d7bb7bd319ac3b7d4ddd22090";
|
|
|
|
|
|
|
@@ -73,7 +74,7 @@ public class ZiJinCrawlerRequestImpl implements QuotationCrawlerBaseService {
|
|
|
*/
|
|
*/
|
|
|
@Override
|
|
@Override
|
|
|
public void login(LoginBase loginBase) {
|
|
public void login(LoginBase loginBase) {
|
|
|
- boHaiCrawlerQuoteProcessService.login(loginBase.getUsername(), loginBase.getPassword());
|
|
|
|
|
|
|
+ ziJinCrawlerQuoteProcessService.login(loginBase.getUsername(), loginBase.getPassword());
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
@@ -84,10 +85,10 @@ public class ZiJinCrawlerRequestImpl implements QuotationCrawlerBaseService {
|
|
|
*/
|
|
*/
|
|
|
@Override
|
|
@Override
|
|
|
public QuoteResultsVo quote(QuoteVo quoteVo) {
|
|
public QuoteResultsVo quote(QuoteVo quoteVo) {
|
|
|
- // 1.0 归属信息
|
|
|
|
|
|
|
+ // 归属信息
|
|
|
AttributionInformationVo attributionInformationVo = quoteVo.getOrder().getAttributionInformationVo();
|
|
AttributionInformationVo attributionInformationVo = quoteVo.getOrder().getAttributionInformationVo();
|
|
|
- HttpHeaders headers = boHaiCrawlerQuoteProcessService.getHeaders(attributionInformationVo.getUsername(), attributionInformationVo.getPassword());
|
|
|
|
|
- String userCode = boHaiCrawlerCacheComponent.getUserCode(attributionInformationVo.getUsername());
|
|
|
|
|
|
|
+ HttpHeaders headers = ziJinCrawlerQuoteProcessService.getHeaders(attributionInformationVo.getUsername(), attributionInformationVo.getPassword());
|
|
|
|
|
+ String userCode = ziJinCrawlerCacheComponent.getUserCode(attributionInformationVo.getUsername());
|
|
|
log.info("userCode:{}", userCode);
|
|
log.info("userCode:{}", userCode);
|
|
|
|
|
|
|
|
// 1.1 解析配置参数
|
|
// 1.1 解析配置参数
|
|
@@ -97,507 +98,88 @@ public class ZiJinCrawlerRequestImpl implements QuotationCrawlerBaseService {
|
|
|
// 1.2 构建归属信息(机构、套餐、渠道信息)
|
|
// 1.2 构建归属信息(机构、套餐、渠道信息)
|
|
|
//ProposalInfoDTO proposalInfoDTO = boHaiBuildingAttributionInformation.build(parameters, userCode, headers);
|
|
//ProposalInfoDTO proposalInfoDTO = boHaiBuildingAttributionInformation.build(parameters, userCode, headers);
|
|
|
|
|
|
|
|
- // 2.0 生成订单号(没有这个逻辑)
|
|
|
|
|
- //String orderNo = generateOrderNo(parameters, headers);
|
|
|
|
|
-
|
|
|
|
|
- // 2.1 车辆查询
|
|
|
|
|
- ZiJinCrawlerCarResponse boHaiCrawlerCarResponse = null;
|
|
|
|
|
|
|
+ // 查询车辆信息
|
|
|
|
|
+ ZiJinCrawlerCarResponse ziJinCrawlerCarResponse = null;
|
|
|
try {
|
|
try {
|
|
|
- ZiJinCrawlerCarRequest boHaiCrawlerCarRequest = new ZiJinCrawlerCarRequest(quoteVo.getCarInfoVo(), parameters.getOrgName(), parameters.getCDptCde(), userCode);
|
|
|
|
|
- boHaiCrawlerCarResponse = boHaiCrawlerRequestComponent.car(boHaiCrawlerCarRequest, headers);
|
|
|
|
|
- log.info("boHaiCrawlerCarResponse参数的值:{}", JSON.toJSONString(boHaiCrawlerCarResponse));
|
|
|
|
|
|
|
+ ZiJinCrawlerCarRequest ziJinCrawlerCarRequest = new ZiJinCrawlerCarRequest();
|
|
|
|
|
+ ziJinCrawlerCarRequest.setChannelCode("KSCD_PROD");
|
|
|
|
|
+ ziJinCrawlerCarRequest.setComCode(parameters.getComCode());
|
|
|
|
|
+ ziJinCrawlerCarRequest.setLicenseNo("");
|
|
|
|
|
+ ziJinCrawlerCarRequest.setVin("");
|
|
|
|
|
+ ziJinCrawlerCarResponse = ziJinCrawlerRequestComponent.car(ziJinCrawlerCarRequest, headers);
|
|
|
|
|
+ log.info("ziJinCrawlerCarResponse参数的值:{}", JSON.toJSONString(ziJinCrawlerCarResponse));
|
|
|
|
|
+
|
|
|
|
|
+ // 车辆和交通查询(获取订单号)
|
|
|
|
|
+ ZiJinCrawlerGetOrderNoRequest ziJinCrawlerGetOrderNoRequest = new ZiJinCrawlerGetOrderNoRequest();
|
|
|
|
|
+ ziJinCrawlerGetOrderNoRequest.setBrandName("荣威CSA6452NEAQ多用途乘用车");
|
|
|
|
|
+ ziJinCrawlerGetOrderNoRequest.setLicenseNo("晋HJW581");
|
|
|
|
|
+ ziJinCrawlerGetOrderNoRequest.setOperatorCode("214000151");
|
|
|
|
|
+ ziJinCrawlerGetOrderNoRequest.setOrderOrigin("KSCD_PROD");
|
|
|
|
|
+ ziJinCrawlerGetOrderNoRequest.setProposalAreaCode("140000");
|
|
|
|
|
+ ziJinCrawlerGetOrderNoRequest.setProposalCityCode("140000");
|
|
|
|
|
+ ziJinCrawlerGetOrderNoRequest.setUserComCode("2140000601");
|
|
|
|
|
+ ziJinCrawlerGetOrderNoRequest.setVinNo("LSJA24U69MS091895");
|
|
|
|
|
+ ziJinCrawlerGetOrderNoRequest.setModelCode("RWD1598SQQ");
|
|
|
|
|
+ ziJinCrawlerGetOrderNoRequest.setProductCode("CAR20190517");
|
|
|
|
|
+ ziJinCrawlerGetOrderNoRequest.setProductName("机动车保险");
|
|
|
|
|
+ ziJinCrawlerGetOrderNoRequest.setTerminalId("KSCD");
|
|
|
|
|
+ ziJinCrawlerGetOrderNoRequest.setTerminalIdType("Vue-PC");
|
|
|
|
|
+
|
|
|
|
|
+ ZiJinCrawlerGetOrderNoResponse ziJinCrawlerGetOrderNoResponse = ziJinCrawlerRequestComponent.getOrderNo(ziJinCrawlerGetOrderNoRequest, headers);
|
|
|
|
|
+ log.info("ziJinCrawlerGetOrderNoResponse参数的值:{}", JSON.toJSONString(ziJinCrawlerGetOrderNoResponse));
|
|
|
|
|
+
|
|
|
|
|
+ //获取车辆实际价值
|
|
|
|
|
+ ZiJinCrawlerGetCarActualValueRequest ziJinCrawlerGetCarActualValueRequest = new ZiJinCrawlerGetCarActualValueRequest();
|
|
|
|
|
+
|
|
|
|
|
+ ziJinCrawlerGetCarActualValueRequest.setCarKindCode("A0");
|
|
|
|
|
+ ziJinCrawlerGetCarActualValueRequest.setEnrollDate("2021-11-01");
|
|
|
|
|
+ ziJinCrawlerGetCarActualValueRequest.setUpdateEnrollDate("2021-11-01");
|
|
|
|
|
+ ziJinCrawlerGetCarActualValueRequest.setPurchasePrice("103800");
|
|
|
|
|
+ ziJinCrawlerGetCarActualValueRequest.setSeatCount(5);
|
|
|
|
|
+ ziJinCrawlerGetCarActualValueRequest.setUseNatureCode("85");
|
|
|
|
|
+ ziJinCrawlerGetCarActualValueRequest.setStartDate("2025-11-05");
|
|
|
|
|
+ ziJinCrawlerGetCarActualValueRequest.setNewEnergyFlag("0");
|
|
|
|
|
+ ziJinCrawlerGetCarActualValueRequest.setModelEnergyType("D1");
|
|
|
|
|
+
|
|
|
|
|
+ ZiJinCrawlerGetCarActualValueResponse ziJinCrawlerGetCarActualValueResponse = ziJinCrawlerRequestComponent.getCarActualValue(ziJinCrawlerGetCarActualValueRequest, headers);
|
|
|
|
|
+ log.info("ziJinCrawlerGetCarActualValueResponse参数的值:{}", JSON.toJSONString(ziJinCrawlerGetCarActualValueResponse));
|
|
|
} catch (Exception e) {
|
|
} catch (Exception e) {
|
|
|
e.printStackTrace();
|
|
e.printStackTrace();
|
|
|
throw new RuntimeException(e);
|
|
throw new RuntimeException(e);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- //2.2 车辆确认
|
|
|
|
|
- String currentValue = null;
|
|
|
|
|
- try {
|
|
|
|
|
- Map<String, Object> vehicleConfirmationResult = getVehicleConfirmationResponse(quoteVo, boHaiCrawlerCarResponse, parameters, headers);
|
|
|
|
|
- //获取车辆当前价值
|
|
|
|
|
- currentValue = (String) vehicleConfirmationResult.get("currentValue");
|
|
|
|
|
- log.info("车辆当前价值:{}", currentValue);
|
|
|
|
|
- } catch (Exception e) {
|
|
|
|
|
- e.printStackTrace();
|
|
|
|
|
- throw new RuntimeException(e);
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
- // 3.0 报价接口
|
|
|
|
|
- /*ZiJinCrawlerQuotationRequest boHaiCrawlerQuotationRequest = new ZiJinCrawlerQuotationRequest(parameters, quoteVo, currentValue, "", quoteVo.getAccidentalDrivings(), "");*/
|
|
|
|
|
- ZiJinCrawlerQuotationRequest2 boHaiCrawlerQuotationRequest2 = new ZiJinCrawlerQuotationRequest2();
|
|
|
|
|
- ZiJinCrawlerQuotationRequest2.Head head = new ZiJinCrawlerQuotationRequest2.Head();
|
|
|
|
|
- head.setTransType("Req");
|
|
|
|
|
- head.setTransCode("PremiumProposal");
|
|
|
|
|
- head.setToken(TOKEN);
|
|
|
|
|
- boHaiCrawlerQuotationRequest2.setHead(head);
|
|
|
|
|
-
|
|
|
|
|
- // 使用 setter 方式设置 businessData、insuredList、riskList、以及登录信息
|
|
|
|
|
- ZiJinCrawlerQuotationRequest2.BusinessData businessData = new ZiJinCrawlerQuotationRequest2.BusinessData();
|
|
|
|
|
-
|
|
|
|
|
- // 业务主信息
|
|
|
|
|
- ZiJinCrawlerQuotationRequest2.BusinessMainInfo mainInfo = new ZiJinCrawlerQuotationRequest2.BusinessMainInfo();
|
|
|
|
|
- mainInfo.setOrderNo("O140703302025063172");
|
|
|
|
|
- mainInfo.setFixPriceType("Y2");
|
|
|
|
|
- mainInfo.setRiskControlFlag("");
|
|
|
|
|
- mainInfo.setUuid("");
|
|
|
|
|
- mainInfo.setTrial(1);
|
|
|
|
|
- mainInfo.setArgueSolution("1");
|
|
|
|
|
- mainInfo.setArbitBoardName("");
|
|
|
|
|
- mainInfo.setBusinessType("OTemp");
|
|
|
|
|
- mainInfo.setComCode("14070201");
|
|
|
|
|
- mainInfo.setBusinessCategories1("1");
|
|
|
|
|
- mainInfo.setBusinessCategories2("2");
|
|
|
|
|
- mainInfo.setBusinessCategories3("A06");
|
|
|
|
|
- mainInfo.setHandlerCode("114050281");
|
|
|
|
|
- mainInfo.setAgentCode("M140301000249");
|
|
|
|
|
- mainInfo.setAgentName("太原天勤保险代理有限公司");
|
|
|
|
|
- mainInfo.setAgreementNo("C142024004345_2");
|
|
|
|
|
- mainInfo.setCityCode("140700");
|
|
|
|
|
- mainInfo.setCountyCode("140781");
|
|
|
|
|
- mainInfo.setOperateDate("2025-10-09");
|
|
|
|
|
- mainInfo.setGoalInsuredFlag("2");
|
|
|
|
|
- mainInfo.setUnderUnit("");
|
|
|
|
|
- mainInfo.setIdentifyType("006");
|
|
|
|
|
- mainInfo.setIdentifyDetail("00001");
|
|
|
|
|
- mainInfo.setIdentifyCode("");
|
|
|
|
|
- mainInfo.setIdentifyVip("");
|
|
|
|
|
- mainInfo.setComputerIp("");
|
|
|
|
|
- mainInfo.setMainCarKindBC("0");
|
|
|
|
|
- mainInfo.setResourceTypeCode("004");
|
|
|
|
|
- mainInfo.setExpectDiscount("");
|
|
|
|
|
- mainInfo.setReportNo("");
|
|
|
|
|
- mainInfo.setExpectedCommission("");
|
|
|
|
|
- mainInfo.setBusinessAttribute("2");
|
|
|
|
|
- mainInfo.setChannelType("");
|
|
|
|
|
- mainInfo.setSalerIdentifyNumber("");
|
|
|
|
|
- mainInfo.setSdId("");
|
|
|
|
|
- mainInfo.setTbMode("");
|
|
|
|
|
- mainInfo.setBussUnitCodeCI("");
|
|
|
|
|
- mainInfo.setBussUnitCode("");
|
|
|
|
|
- mainInfo.setPriceMode("");
|
|
|
|
|
- mainInfo.setHighRiskAssessId("");
|
|
|
|
|
- mainInfo.setReCustomerType("");
|
|
|
|
|
- mainInfo.setLastYearAdjustValue("");
|
|
|
|
|
- businessData.setBusinessMainInfo(mainInfo);
|
|
|
|
|
-
|
|
|
|
|
- // 车辆信息
|
|
|
|
|
- ZiJinCrawlerQuotationRequest2.CarInfo carInfo = new ZiJinCrawlerQuotationRequest2.CarInfo();
|
|
|
|
|
- ZiJinCrawlerQuotationRequest2.ItemCarInfo item = new ZiJinCrawlerQuotationRequest2.ItemCarInfo();
|
|
|
|
|
- item.setCertificateNo("");
|
|
|
|
|
- item.setCertificateType("");
|
|
|
|
|
- item.setOtherEnergyTypeDesc("");
|
|
|
|
|
- item.setPureRange("");
|
|
|
|
|
- item.setPmFuelType("A");
|
|
|
|
|
- item.setCarCheckStatus("");
|
|
|
|
|
- //实际价值
|
|
|
|
|
- item.setActualValue("15380.00");
|
|
|
|
|
- item.setOtherNature7BI("0");
|
|
|
|
|
- //协商价值
|
|
|
|
|
- item.setNegotiatedValue("15380.00");
|
|
|
|
|
- item.setNewVehicleFlag("0");
|
|
|
|
|
- item.setLicenseNo("晋K38V85");
|
|
|
|
|
- item.setFrameNo("LJDLAA197D0029125");
|
|
|
|
|
- item.setEngineNo("D5685636");
|
|
|
|
|
- item.setVinNo("LJDLAA197D0029125");
|
|
|
|
|
- item.setNoLicenseFlag("");
|
|
|
|
|
- item.setLicenseColorCode("01");
|
|
|
|
|
- item.setUseNatureCode("8A");
|
|
|
|
|
- item.setMainCarKindCode("A");
|
|
|
|
|
- item.setCarKindCode("A0");
|
|
|
|
|
- item.setBrandName("起亚YQZ7143A轿车");
|
|
|
|
|
- item.setSeatCount("5");
|
|
|
|
|
- item.setTonCount("0.0000");
|
|
|
|
|
- item.setPurchasePrice("76900");
|
|
|
|
|
- item.setBasePurchasePrice("76900");
|
|
|
|
|
- item.setExhaustScale(1.396);
|
|
|
|
|
- item.setEnrollDate("2013-10-14");
|
|
|
|
|
- item.setUseYearsBI("12");
|
|
|
|
|
- item.setUseYearsCI(11);
|
|
|
|
|
- item.setUseYearsDI("");
|
|
|
|
|
- item.setChgOwnerFlag("1");
|
|
|
|
|
- item.setChgTypeFlag("0");
|
|
|
|
|
- item.setChgOwnerDate("2024-11-05");
|
|
|
|
|
- item.setCountryNature("C");
|
|
|
|
|
- item.setModelCode("KED1014DFY");
|
|
|
|
|
- item.setRunMiles(20000);
|
|
|
|
|
- item.setRunAreaCode("02");
|
|
|
|
|
- item.setTrafficViolationRecords("0");
|
|
|
|
|
- item.setColorCode("99");
|
|
|
|
|
- item.setMadeFactory("东风悦达起亚汽车有限公司");
|
|
|
|
|
- item.setMakeDate("");
|
|
|
|
|
- item.setVehicleBrand("起亚");
|
|
|
|
|
- item.setCompleteKerbMass(1087);
|
|
|
|
|
- item.setLicenseKindCode("02");
|
|
|
|
|
- item.setLicenseCategory("K33");
|
|
|
|
|
- item.setRenewalFlagBI("0");
|
|
|
|
|
- item.setDamagedFactorGrade("");
|
|
|
|
|
- item.setSpecialVehicleFlag("0");
|
|
|
|
|
- item.setLoanVehicleFlag("0");
|
|
|
|
|
- item.setProportion("");
|
|
|
|
|
- item.setEnergySavingOrNewEnergy("0");
|
|
|
|
|
- item.setLastProducerCode("0");
|
|
|
|
|
- item.setDebtFlag("");
|
|
|
|
|
- item.setRestricFlag("00");
|
|
|
|
|
- item.setSearchSequenceNo("");
|
|
|
|
|
- item.setIsTaxi("0");
|
|
|
|
|
- item.setFuelType1("0");
|
|
|
|
|
- item.setSpecifiedQueryArea("");
|
|
|
|
|
- item.setIndustryCarTypeCode("BYDLKFUC0007");
|
|
|
|
|
- item.setIndustryCarTypeName("起亚YQZ7143A GLS");
|
|
|
|
|
- item.setCarABSFlag(null);
|
|
|
|
|
- item.setFuelType2("");
|
|
|
|
|
- item.setMiniCar("");
|
|
|
|
|
- item.setCarAddressCode("");
|
|
|
|
|
- item.setIssueDate("2013-10-14");
|
|
|
|
|
- item.setNewDeviceFlag("0");
|
|
|
|
|
- item.setInvoiceNo("");
|
|
|
|
|
- item.setOwnerAddress("");
|
|
|
|
|
- item.setTractorType("");
|
|
|
|
|
- item.setNoClaimAdjustReason("");
|
|
|
|
|
- item.setNoDamageYearsBI("");
|
|
|
|
|
- item.setNoDamageYearsCI("");
|
|
|
|
|
- item.setNoLoyaltyAdjustReason("");
|
|
|
|
|
- item.setPowerType("汽油");
|
|
|
|
|
- item.setPowerTypeCode("D1");
|
|
|
|
|
- item.setSeries("K2");
|
|
|
|
|
- item.setSeriesCode(null);
|
|
|
|
|
- item.setPriorityServicerType("0");
|
|
|
|
|
- item.setPriorityServicerCode("");
|
|
|
|
|
- item.setNoticeType("YQZ7143A");
|
|
|
|
|
- item.setPureRiskPremium("0.0");
|
|
|
|
|
- item.setEcdemicVehicleFlag("0");
|
|
|
|
|
- item.setNewCarFlag("0");
|
|
|
|
|
- item.setPrnExhaustScale("");
|
|
|
|
|
- item.setPrnCompleteKerbMassNew("");
|
|
|
|
|
- item.setIsNetworkCar(0);
|
|
|
|
|
- item.setPower("78.7");
|
|
|
|
|
- item.setCarUsage("起亚牌YQZ7143A");
|
|
|
|
|
- item.setCarChecker("");
|
|
|
|
|
- item.setCarCheckTime("2025-10-09 17:14");
|
|
|
|
|
- item.setVerifyReason("");
|
|
|
|
|
- item.setCarCheckDelayDays("");
|
|
|
|
|
- item.setVerifyReasonOtherReason("");
|
|
|
|
|
- item.setVerifyStatus("");
|
|
|
|
|
- item.setCarCheckReason("");
|
|
|
|
|
- item.setCarCheckOtherReason("");
|
|
|
|
|
- item.setRiskType("1");
|
|
|
|
|
- item.setVehicleStyleUniqueId("14970");
|
|
|
|
|
- item.setIsNewCar("0");
|
|
|
|
|
- item.setJyPreCarNo("c44a2adbb1a145b58ff7e1aef164ebd6");
|
|
|
|
|
- carInfo.setItemCarInfo(item);
|
|
|
|
|
- carInfo.setChargingInfoList(Collections.emptyList());
|
|
|
|
|
- carInfo.setDeviceList(Collections.emptyList());
|
|
|
|
|
- businessData.setCarInfo(carInfo);
|
|
|
|
|
-
|
|
|
|
|
- // 被保险人列表
|
|
|
|
|
- List<ZiJinCrawlerQuotationRequest2.Insured> insuredList = new ArrayList<>();
|
|
|
|
|
- ZiJinCrawlerQuotationRequest2.Insured insured1 = new ZiJinCrawlerQuotationRequest2.Insured();
|
|
|
|
|
- insured1.setSerialNo("1");
|
|
|
|
|
- insured1.setInsuredCode("");
|
|
|
|
|
- insured1.setIdentifyNumber("");
|
|
|
|
|
- insured1.setIdentifyType("01");
|
|
|
|
|
- insured1.setInsuredName("");
|
|
|
|
|
- insured1.setInsuredFlag("2");
|
|
|
|
|
- insured1.setInsuredType("1");
|
|
|
|
|
- insured1.setGender("");
|
|
|
|
|
- insured1.setInsuredNature("3");
|
|
|
|
|
- insured1.setPhoneNumber("");
|
|
|
|
|
- insured1.setMobile("");
|
|
|
|
|
- insured1.setInsuredAddress("");
|
|
|
|
|
- insured1.setPostCode("");
|
|
|
|
|
- insured1.setPostAddress("");
|
|
|
|
|
- insured1.setOrgCode("");
|
|
|
|
|
- insured1.setAge("");
|
|
|
|
|
- insured1.setBirthDay("");
|
|
|
|
|
- insured1.setIsIndividualBusi("");
|
|
|
|
|
- insured1.setAppliCitizenshipBC("01");
|
|
|
|
|
- insured1.setAppliCountryBC("008zg");
|
|
|
|
|
- insured1.setEmail("");
|
|
|
|
|
- insured1.setBusinessLicenseType("");
|
|
|
|
|
- insured1.setNation("");
|
|
|
|
|
- insured1.setIdentifyAddress("");
|
|
|
|
|
- insured1.setIdentifyStartDate("");
|
|
|
|
|
- insured1.setIdentifyEndDate("");
|
|
|
|
|
- insured1.setCarInsuredRelation("");
|
|
|
|
|
- insured1.setBusinessSort("15");
|
|
|
|
|
- insured1.setLinkerName("");
|
|
|
|
|
- //设置为空
|
|
|
|
|
- insured1.setIsSpecialDInsured("");
|
|
|
|
|
- insured1.setSpecialDInsuredName("");
|
|
|
|
|
- insured1.setSpecialDInsuredIDType("");
|
|
|
|
|
- insured1.setSpecialDInsuredID("");
|
|
|
|
|
- insured1.setNoSpecialDInsuredP("");
|
|
|
|
|
- insured1.setBenefitFlag("");
|
|
|
|
|
- insured1.setIsGreenIndustryFlag("");
|
|
|
|
|
- insured1.setGreenIndustryFCode("");
|
|
|
|
|
- insured1.setGreenIndustrySCode("");
|
|
|
|
|
- insured1.setGreenIndustryTCode("");
|
|
|
|
|
- insuredList.add(insured1);
|
|
|
|
|
-
|
|
|
|
|
- ZiJinCrawlerQuotationRequest2.Insured insured2 = new ZiJinCrawlerQuotationRequest2.Insured();
|
|
|
|
|
- insured2.setSerialNo("2");
|
|
|
|
|
- insured2.setInsuredCode("");
|
|
|
|
|
- insured2.setIdentifyNumber("142626196108011016");
|
|
|
|
|
- insured2.setIdentifyType("01");
|
|
|
|
|
- insured2.setInsuredName("段志文");
|
|
|
|
|
- insured2.setInsuredFlag("1");
|
|
|
|
|
- insured2.setInsuredType("1");
|
|
|
|
|
- insured2.setGender("1");
|
|
|
|
|
- insured2.setInsuredNature("3");
|
|
|
|
|
- insured2.setPhoneNumber("");
|
|
|
|
|
- insured2.setMobile("");
|
|
|
|
|
- insured2.setInsuredAddress("");
|
|
|
|
|
- insured2.setPostCode("");
|
|
|
|
|
- insured2.setPostAddress("");
|
|
|
|
|
- insured2.setOrgCode("");
|
|
|
|
|
- insured2.setAge(64);
|
|
|
|
|
- insured2.setBirthDay("1961-08-01");
|
|
|
|
|
- insured2.setIsIndividualBusi("");
|
|
|
|
|
- insured2.setAppliCitizenshipBC("01");
|
|
|
|
|
- insured2.setAppliCountryBC("008zg");
|
|
|
|
|
- insured2.setEmail("");
|
|
|
|
|
- insured2.setBusinessLicenseType("");
|
|
|
|
|
- insured2.setNation("");
|
|
|
|
|
- insured2.setIdentifyAddress("");
|
|
|
|
|
- insured2.setIdentifyStartDate("");
|
|
|
|
|
- insured2.setIdentifyEndDate("");
|
|
|
|
|
- insured2.setCarInsuredRelation("1");
|
|
|
|
|
- insured2.setBusinessSort("15");
|
|
|
|
|
- insured2.setLinkerName("");
|
|
|
|
|
- insured2.setIsSpecialDInsured("0");
|
|
|
|
|
- insured2.setSpecialDInsuredName("");
|
|
|
|
|
- insured2.setSpecialDInsuredIDType("");
|
|
|
|
|
- insured2.setSpecialDInsuredID("");
|
|
|
|
|
- insured2.setNoSpecialDInsuredP("1");
|
|
|
|
|
- insured2.setBenefitFlag("0");
|
|
|
|
|
- insured2.setIsGreenIndustryFlag("");
|
|
|
|
|
- insured2.setGreenIndustryFCode("");
|
|
|
|
|
- insured2.setGreenIndustrySCode("");
|
|
|
|
|
- insured2.setGreenIndustryTCode("");
|
|
|
|
|
- insuredList.add(insured2);
|
|
|
|
|
|
|
+ // 报价接口
|
|
|
|
|
+ ZiJinCrawlerQuotationRequest ziJinCrawlerQuotationRequest = new ZiJinCrawlerQuotationRequest();
|
|
|
|
|
|
|
|
- ZiJinCrawlerQuotationRequest2.Insured insured3 = new ZiJinCrawlerQuotationRequest2.Insured();
|
|
|
|
|
- insured3.setSerialNo("3");
|
|
|
|
|
- insured3.setInsuredCode("");
|
|
|
|
|
- insured3.setIdentifyNumber("142626196108011016");
|
|
|
|
|
- insured3.setIdentifyType("01");
|
|
|
|
|
- insured3.setInsuredName("段志文");
|
|
|
|
|
- insured3.setInsuredFlag("3");
|
|
|
|
|
- insured3.setInsuredType("1");
|
|
|
|
|
- insured3.setGender("1");
|
|
|
|
|
- insured3.setInsuredNature("1");
|
|
|
|
|
- insured3.setPhoneNumber("");
|
|
|
|
|
- insured3.setMobile("");
|
|
|
|
|
- insured3.setInsuredAddress("");
|
|
|
|
|
- insured3.setPostCode("");
|
|
|
|
|
- insured3.setPostAddress("");
|
|
|
|
|
- insured3.setOrgCode("");
|
|
|
|
|
- insured3.setAge("");
|
|
|
|
|
- insured3.setBirthDay("1961-08-01");
|
|
|
|
|
- insured3.setIsIndividualBusi("");
|
|
|
|
|
- insured3.setAppliCitizenshipBC("01");
|
|
|
|
|
- insured3.setAppliCountryBC("008zg");
|
|
|
|
|
- insured3.setEmail("");
|
|
|
|
|
- insured3.setBusinessLicenseType("");
|
|
|
|
|
- insured3.setNation("");
|
|
|
|
|
- insured3.setIdentifyAddress("");
|
|
|
|
|
- insured3.setIdentifyStartDate("");
|
|
|
|
|
- insured3.setIdentifyEndDate("");
|
|
|
|
|
- insured3.setCarInsuredRelation("");
|
|
|
|
|
- insured3.setBusinessSort("15");
|
|
|
|
|
- insured3.setLinkerName("");
|
|
|
|
|
- //设置为空
|
|
|
|
|
- insured3.setIsSpecialDInsured("");
|
|
|
|
|
- insured3.setSpecialDInsuredName("");
|
|
|
|
|
- insured3.setSpecialDInsuredIDType("");
|
|
|
|
|
- insured3.setSpecialDInsuredID("");
|
|
|
|
|
- insured3.setNoSpecialDInsuredP("");
|
|
|
|
|
- insured3.setBenefitFlag("");
|
|
|
|
|
- insured3.setIsGreenIndustryFlag("");
|
|
|
|
|
- insured3.setGreenIndustryFCode("");
|
|
|
|
|
- insured3.setGreenIndustrySCode("");
|
|
|
|
|
- insured3.setGreenIndustryTCode("");
|
|
|
|
|
- insuredList.add(insured3);
|
|
|
|
|
- businessData.setInsuredList(insuredList);
|
|
|
|
|
-
|
|
|
|
|
- // 风险列表
|
|
|
|
|
- List<ZiJinCrawlerQuotationRequest2.Risk> riskList = new ArrayList<>();
|
|
|
|
|
- // 交强险
|
|
|
|
|
- ZiJinCrawlerQuotationRequest2.Risk jqRisk = new ZiJinCrawlerQuotationRequest2.Risk();
|
|
|
|
|
- List<ZiJinCrawlerQuotationRequest2.ItemKind> jqItemKinds = new ArrayList<>();
|
|
|
|
|
-
|
|
|
|
|
- //交强险列表
|
|
|
|
|
- ZiJinCrawlerQuotationRequest2.ItemKind jqItem = new ZiJinCrawlerQuotationRequest2.ItemKind();
|
|
|
|
|
- jqItem.setItemKindNo("0");
|
|
|
|
|
- jqItem.setKindCode("BZ");
|
|
|
|
|
- jqItem.setKindName("机动车交通事故责任强制保险");
|
|
|
|
|
- jqItem.setOperateType("");
|
|
|
|
|
- jqItem.setStartDate("2025-10-10");
|
|
|
|
|
- jqItem.setStartHour("");
|
|
|
|
|
- jqItem.setEndDate("2026-10-09");
|
|
|
|
|
- jqItem.setEndHour("");
|
|
|
|
|
- jqItem.setAmount("");
|
|
|
|
|
- jqItem.setUnitAmount("");
|
|
|
|
|
- jqItem.setQuantity("");
|
|
|
|
|
- jqItem.setModeCode("");
|
|
|
|
|
- jqItem.setModeName("");
|
|
|
|
|
- jqItem.setShortRateFlag("2");
|
|
|
|
|
- jqItem.setShortRate("");
|
|
|
|
|
- jqItem.setCalculateFlag("Y");
|
|
|
|
|
- jqItem.setRate("");
|
|
|
|
|
- jqItem.setNotDeductibleFlag("0");
|
|
|
|
|
- jqItem.setDeductibleRatio("");
|
|
|
|
|
- jqItem.setDiscount("");
|
|
|
|
|
- jqItem.setAdjustRate("");
|
|
|
|
|
- jqItem.setValue("");
|
|
|
|
|
- jqItemKinds.add(jqItem);
|
|
|
|
|
- jqRisk.setItemKindList(jqItemKinds);
|
|
|
|
|
-
|
|
|
|
|
- ZiJinCrawlerQuotationRequest2.RiskMainInfo jqMain = new ZiJinCrawlerQuotationRequest2.RiskMainInfo();
|
|
|
|
|
- jqMain.setIsDrivingFee("1");
|
|
|
|
|
- jqMain.setAgriflag("012001");
|
|
|
|
|
- jqMain.setClassCode("");
|
|
|
|
|
- jqMain.setRiskCode("0330");
|
|
|
|
|
- jqMain.setContractNo("");
|
|
|
|
|
- jqMain.setDiscount("");
|
|
|
|
|
- jqMain.setCurrency("CNY");
|
|
|
|
|
- jqMain.setLastPolicyNo("");
|
|
|
|
|
- jqMain.setRenewalFlag("0");
|
|
|
|
|
- jqMain.setStartDate("2025-10-10");
|
|
|
|
|
- jqMain.setStartHour("0");
|
|
|
|
|
- jqMain.setEndDate("2026-10-09");
|
|
|
|
|
- jqMain.setEndHour("24");
|
|
|
|
|
- jqMain.setImmediatelyActiveFlag("");
|
|
|
|
|
- jqMain.setActiveStartTime("");
|
|
|
|
|
- jqMain.setActiveEndTime("");
|
|
|
|
|
- jqMain.setQuerySequenceNo("");
|
|
|
|
|
- jqMain.setConfirmSequenceNo("");
|
|
|
|
|
- jqMain.setSpecialContractFlag("");
|
|
|
|
|
- jqMain.setSpecialContractSummary("");
|
|
|
|
|
- jqMain.setNoneFluctuateFlag("N1");
|
|
|
|
|
- jqMain.setNcdCoefficient("");
|
|
|
|
|
- jqMain.setChannelCoefficient("1.00");
|
|
|
|
|
- jqMain.setUnderwritingCoefficient("");
|
|
|
|
|
- jqMain.setAdjustCoefficient("");
|
|
|
|
|
- jqMain.setTrafficViolationCoefficient("");
|
|
|
|
|
- jqMain.setChannelCoefficientVariation("");
|
|
|
|
|
- jqMain.setUnderwritingCoefficientVariation("");
|
|
|
|
|
- jqMain.setIfNeedQuote("");
|
|
|
|
|
- jqMain.setHopeRate("");
|
|
|
|
|
- jqMain.setProposalNo("");
|
|
|
|
|
-
|
|
|
|
|
- jqMain.setCustomerCoefficient("364001");
|
|
|
|
|
- jqMain.setFleetCoefficient("365000");
|
|
|
|
|
- jqMain.setSignDate("2025-10-09");
|
|
|
|
|
- jqMain.setOperateDate("2025-10-09");
|
|
|
|
|
- jqMain.setInputDate("2025-10-09");
|
|
|
|
|
- jqMain.setPricingAdjustValue("1");
|
|
|
|
|
- jqMain.setNoneFluctuateFeeRate("N1");
|
|
|
|
|
- jqRisk.setRiskMainInfo(jqMain);
|
|
|
|
|
-
|
|
|
|
|
- ZiJinCrawlerQuotationRequest2.CarShipTaxInfo taxInfo = new ZiJinCrawlerQuotationRequest2.CarShipTaxInfo();
|
|
|
|
|
- taxInfo.setTaxPayerIdentifier("142626196108011016");
|
|
|
|
|
- taxInfo.setTaxPayerName("段志文");
|
|
|
|
|
- taxInfo.setTaxPayerIdentifyNumberType("01");
|
|
|
|
|
- taxInfo.setTaxPayerIdentifyNumber("142626196108011016");
|
|
|
|
|
- taxInfo.setUnladenMassCS(1087);
|
|
|
|
|
- taxInfo.setLicenseCategory("K33");
|
|
|
|
|
- taxInfo.setCertificateDate("2013-10-14");
|
|
|
|
|
- taxInfo.setTaxItemCode("A");
|
|
|
|
|
- taxInfo.setTaxItemName("载客汽车");
|
|
|
|
|
- taxInfo.setTaxRelifFlag("1");
|
|
|
|
|
- taxInfo.setCalculateMode("1");
|
|
|
|
|
- taxInfo.setCalLateFeeFlag("0");
|
|
|
|
|
- taxInfo.setCalPayBalanceFeeFlag("0");
|
|
|
|
|
- taxInfo.setTaxType("1");
|
|
|
|
|
- taxInfo.setTaxNumType("1");
|
|
|
|
|
- taxInfo.setPayTaxDate("202510");
|
|
|
|
|
- taxInfo.setCarOwnerNature("1");
|
|
|
|
|
- taxInfo.setCarAddressCode("120000");
|
|
|
|
|
- taxInfo.setUseType("100");
|
|
|
|
|
- taxInfo.setCalFeeFlag("00");
|
|
|
|
|
- jqRisk.setCarShipTaxInfo(taxInfo);
|
|
|
|
|
- riskList.add(jqRisk);
|
|
|
|
|
-
|
|
|
|
|
- // 商业险(车辆损失险)
|
|
|
|
|
- ZiJinCrawlerQuotationRequest2.Risk syRisk = new ZiJinCrawlerQuotationRequest2.Risk();
|
|
|
|
|
- List<ZiJinCrawlerQuotationRequest2.ItemKind> syItemKinds = new ArrayList<>();
|
|
|
|
|
- ZiJinCrawlerQuotationRequest2.ItemKind syItem = new ZiJinCrawlerQuotationRequest2.ItemKind();
|
|
|
|
|
- syItem.setItemKindNo("1");
|
|
|
|
|
- syItem.setKindCode("A");
|
|
|
|
|
- syItem.setKindName("车辆损失险");
|
|
|
|
|
- syItem.setStartDate("2025-12-01");
|
|
|
|
|
- syItem.setStartHour("0");
|
|
|
|
|
- syItem.setEndDate("2026-11-30");
|
|
|
|
|
- syItem.setEndHour("24");
|
|
|
|
|
- syItem.setAmount("15380.00");
|
|
|
|
|
- syItem.setShortRateFlag("3");
|
|
|
|
|
- syItem.setCalculateFlag("Y");
|
|
|
|
|
- syItem.setNotDeductibleFlag("0");
|
|
|
|
|
- syItemKinds.add(syItem);
|
|
|
|
|
- syRisk.setItemKindList(syItemKinds);
|
|
|
|
|
-
|
|
|
|
|
- ZiJinCrawlerQuotationRequest2.RiskMainInfo syMain = new ZiJinCrawlerQuotationRequest2.RiskMainInfo();
|
|
|
|
|
- syMain.setIsDrivingFee("1");
|
|
|
|
|
- syMain.setAgriflag("012001");
|
|
|
|
|
- syMain.setRiskCode("0380");
|
|
|
|
|
- syMain.setCurrency("CNY");
|
|
|
|
|
- syMain.setRenewalFlag("0");
|
|
|
|
|
- syMain.setStartDate("2025-12-01");
|
|
|
|
|
- syMain.setStartHour("0");
|
|
|
|
|
- syMain.setEndDate("2026-11-30");
|
|
|
|
|
- syMain.setEndHour("24");
|
|
|
|
|
- syMain.setNcdCoefficient("1");
|
|
|
|
|
- syMain.setChannelCoefficient("1.00");
|
|
|
|
|
- syMain.setCustomerProperty("001");
|
|
|
|
|
- syMain.setRiskCoefficient("362003");
|
|
|
|
|
- syMain.setBusinessCoefficient("363000");
|
|
|
|
|
- syMain.setVehicleCoefficient("000");
|
|
|
|
|
- syMain.setCustomerCoefficient("364001");
|
|
|
|
|
- syMain.setFleetCoefficient("365000");
|
|
|
|
|
- syMain.setClauseType("F91");
|
|
|
|
|
- syMain.setSignDate("2025-10-09");
|
|
|
|
|
- syMain.setOperateDate("2025-10-09");
|
|
|
|
|
- syMain.setInputDate("2025-10-09");
|
|
|
|
|
- syRisk.setRiskMainInfo(syMain);
|
|
|
|
|
- riskList.add(syRisk);
|
|
|
|
|
- businessData.setRiskList(riskList);
|
|
|
|
|
-
|
|
|
|
|
- // 赋值到请求对象
|
|
|
|
|
- boHaiCrawlerQuotationRequest2.setBusinessData(businessData);
|
|
|
|
|
- boHaiCrawlerQuotationRequest2.setLoginCom("14070201");
|
|
|
|
|
- boHaiCrawlerQuotationRequest2.setUserCode("114050281");
|
|
|
|
|
- boHaiCrawlerQuotationRequest2.setFirstUserCode("114050281");
|
|
|
|
|
-
|
|
|
|
|
- ZiJinCrawlerQuotationResponse boHaiCrawlerQuotationResponse = boHaiCrawlerRequestComponent.quotation(boHaiCrawlerQuotationRequest2, headers);
|
|
|
|
|
|
|
+ ZiJinCrawlerQuotationResponse boHaiCrawlerQuotationResponse = ziJinCrawlerRequestComponent.quotation(ziJinCrawlerQuotationRequest, headers);
|
|
|
log.info("boHaiCrawlerQuotationResponse参数的值:{}", JSON.toJSONString(boHaiCrawlerQuotationResponse));
|
|
log.info("boHaiCrawlerQuotationResponse参数的值:{}", JSON.toJSONString(boHaiCrawlerQuotationResponse));
|
|
|
- if(boHaiCrawlerQuotationResponse.getData() == null){
|
|
|
|
|
|
|
+ if (boHaiCrawlerQuotationResponse.getData() == null) {
|
|
|
//报价失败
|
|
//报价失败
|
|
|
return ZiJinCrawlerQuoteResultsVoBuild.buildQuoteFailResultsVo(boHaiCrawlerQuotationResponse);
|
|
return ZiJinCrawlerQuoteResultsVoBuild.buildQuoteFailResultsVo(boHaiCrawlerQuotationResponse);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
// 4.0 处理报价失败
|
|
// 4.0 处理报价失败
|
|
|
if (!ResponseCode.R_Z00001.equals(boHaiCrawlerQuotationResponse.getResponseCode())) {
|
|
if (!ResponseCode.R_Z00001.equals(boHaiCrawlerQuotationResponse.getResponseCode())) {
|
|
|
- boHaiCrawlerOrderService.save(quoteVo, boHaiCrawlerQuotationResponse, false);
|
|
|
|
|
|
|
+ ziJinCrawlerOrderService.save(quoteVo, boHaiCrawlerQuotationResponse, false);
|
|
|
return ZiJinCrawlerQuoteResultsVoBuild.buildQuoteFailResultsVo(boHaiCrawlerQuotationResponse);
|
|
return ZiJinCrawlerQuoteResultsVoBuild.buildQuoteFailResultsVo(boHaiCrawlerQuotationResponse);
|
|
|
} else {
|
|
} else {
|
|
|
//报价成功
|
|
//报价成功
|
|
|
- boHaiCrawlerOrderService.save(quoteVo, boHaiCrawlerQuotationResponse, true);
|
|
|
|
|
|
|
+ ziJinCrawlerOrderService.save(quoteVo, boHaiCrawlerQuotationResponse, true);
|
|
|
return ZiJinCrawlerQuoteResultsVoBuild.buildQuoteResultsVo(quoteVo.getOrder().getOrdersNo(), quoteVo, boHaiCrawlerQuotationResponse);
|
|
return ZiJinCrawlerQuoteResultsVoBuild.buildQuoteResultsVo(quoteVo.getOrder().getOrdersNo(), quoteVo, boHaiCrawlerQuotationResponse);
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
* 核保
|
|
* 核保
|
|
|
|
|
+ *
|
|
|
* @param underwritingVo
|
|
* @param underwritingVo
|
|
|
* @return UnderwritingResultsVo
|
|
* @return UnderwritingResultsVo
|
|
|
*/
|
|
*/
|
|
|
@Override
|
|
@Override
|
|
|
public UnderwritingResultsVo underwriting(UnderwritingVo underwritingVo) {
|
|
public UnderwritingResultsVo underwriting(UnderwritingVo underwritingVo) {
|
|
|
AttributionInformationVo attributionInformationVo = underwritingVo.getOrder().getAttributionInformationVo();
|
|
AttributionInformationVo attributionInformationVo = underwritingVo.getOrder().getAttributionInformationVo();
|
|
|
- ZiJinCrawlerOrder boHaiCrawlerOrder = boHaiCrawlerOrderService.getById(underwritingVo.getOrder().getOrdersNo());
|
|
|
|
|
- HttpHeaders headers = boHaiCrawlerQuoteProcessService.getHeaders(attributionInformationVo.getUsername(), attributionInformationVo.getPassword());
|
|
|
|
|
|
|
+ ZiJinCrawlerOrder boHaiCrawlerOrder = ziJinCrawlerOrderService.getById(underwritingVo.getOrder().getOrdersNo());
|
|
|
|
|
+ HttpHeaders headers = ziJinCrawlerQuoteProcessService.getHeaders(attributionInformationVo.getUsername(), attributionInformationVo.getPassword());
|
|
|
|
|
|
|
|
//UnderwritingRequest underwritingRequest = new UnderwritingRequest(attributionInformationVo.getConfigInfo(), boHaiCrawlerOrder.getOrderNo());
|
|
//UnderwritingRequest underwritingRequest = new UnderwritingRequest(attributionInformationVo.getConfigInfo(), boHaiCrawlerOrder.getOrderNo());
|
|
|
|
|
|
|
@@ -607,7 +189,7 @@ public class ZiJinCrawlerRequestImpl implements QuotationCrawlerBaseService {
|
|
|
ZiJinCrawlerUnderwritingRequest2.BusinessData businessData = createBusinessData();
|
|
ZiJinCrawlerUnderwritingRequest2.BusinessData businessData = createBusinessData();
|
|
|
ZiJinCrawlerUnderwritingRequest2 boHaiCrawlerUnderwritingRequest2 = new ZiJinCrawlerUnderwritingRequest2(head, businessData);
|
|
ZiJinCrawlerUnderwritingRequest2 boHaiCrawlerUnderwritingRequest2 = new ZiJinCrawlerUnderwritingRequest2(head, businessData);
|
|
|
// 核保
|
|
// 核保
|
|
|
- boHaiUnderwritingResponse = boHaiCrawlerRequestComponent.underwriting(boHaiCrawlerUnderwritingRequest2, headers);
|
|
|
|
|
|
|
+ boHaiUnderwritingResponse = ziJinCrawlerRequestComponent.underwriting(boHaiCrawlerUnderwritingRequest2, headers);
|
|
|
} catch (Exception e) {
|
|
} catch (Exception e) {
|
|
|
throw new RuntimeException(e);
|
|
throw new RuntimeException(e);
|
|
|
}
|
|
}
|
|
@@ -625,7 +207,7 @@ public class ZiJinCrawlerRequestImpl implements QuotationCrawlerBaseService {
|
|
|
underwritingResultsVo.setJqApplyNo(boHaiUnderwritingResponse.getBusinessData().getBusinessMainInfo().getBusinessNoList().get(0).getProposalNoCI());
|
|
underwritingResultsVo.setJqApplyNo(boHaiUnderwritingResponse.getBusinessData().getBusinessMainInfo().getBusinessNoList().get(0).getProposalNoCI());
|
|
|
underwritingResultsVo.setSyApplyNo(boHaiUnderwritingResponse.getBusinessData().getBusinessMainInfo().getBusinessNoList().get(0).getProposalNoBI());
|
|
underwritingResultsVo.setSyApplyNo(boHaiUnderwritingResponse.getBusinessData().getBusinessMainInfo().getBusinessNoList().get(0).getProposalNoBI());
|
|
|
}
|
|
}
|
|
|
- }else{
|
|
|
|
|
|
|
+ } else {
|
|
|
underwritingResultsVo.setUnderwritingStatus(InsOrderStatusEnum.AUDIT_FAIL);
|
|
underwritingResultsVo.setUnderwritingStatus(InsOrderStatusEnum.AUDIT_FAIL);
|
|
|
StringBuilder sb = new StringBuilder();
|
|
StringBuilder sb = new StringBuilder();
|
|
|
if (null != boHaiUnderwritingResponse.getHead().getReturnMessage()) {
|
|
if (null != boHaiUnderwritingResponse.getHead().getReturnMessage()) {
|
|
@@ -639,6 +221,7 @@ public class ZiJinCrawlerRequestImpl implements QuotationCrawlerBaseService {
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
* 获取支付链接
|
|
* 获取支付链接
|
|
|
|
|
+ *
|
|
|
* @param paymentLinkVo
|
|
* @param paymentLinkVo
|
|
|
* @return PaymentLinkResultsVo
|
|
* @return PaymentLinkResultsVo
|
|
|
*/
|
|
*/
|
|
@@ -648,13 +231,13 @@ public class ZiJinCrawlerRequestImpl implements QuotationCrawlerBaseService {
|
|
|
//获取归属信息
|
|
//获取归属信息
|
|
|
AttributionInformationVo attributionInformationVo = paymentLinkVo.getOrder().getAttributionInformationVo();
|
|
AttributionInformationVo attributionInformationVo = paymentLinkVo.getOrder().getAttributionInformationVo();
|
|
|
log.info("attributionInformationVo对象的值:{}", JSONObject.toJSONString(attributionInformationVo));
|
|
log.info("attributionInformationVo对象的值:{}", JSONObject.toJSONString(attributionInformationVo));
|
|
|
- HttpHeaders headers = boHaiCrawlerQuoteProcessService.getHeaders(attributionInformationVo.getUsername(), attributionInformationVo.getPassword());
|
|
|
|
|
- ZiJinCrawlerOrder boHaiCrawlerOrder = boHaiCrawlerOrderService.getById(paymentLinkVo.getOrder().getOrdersNo());
|
|
|
|
|
|
|
+ HttpHeaders headers = ziJinCrawlerQuoteProcessService.getHeaders(attributionInformationVo.getUsername(), attributionInformationVo.getPassword());
|
|
|
|
|
+ ZiJinCrawlerOrder boHaiCrawlerOrder = ziJinCrawlerOrderService.getById(paymentLinkVo.getOrder().getOrdersNo());
|
|
|
|
|
|
|
|
log.info("获取支付链接,订单号:{}", boHaiCrawlerOrder.getOrderNo());
|
|
log.info("获取支付链接,订单号:{}", boHaiCrawlerOrder.getOrderNo());
|
|
|
ZiJinCrawlerPaymentCertiNoQueryRequest boHaiCrawlerPaymentCertiNoQueryRequest = buildPaymentCertiNoQueryRequest(boHaiCrawlerOrder.getOrderNo());
|
|
ZiJinCrawlerPaymentCertiNoQueryRequest boHaiCrawlerPaymentCertiNoQueryRequest = buildPaymentCertiNoQueryRequest(boHaiCrawlerOrder.getOrderNo());
|
|
|
|
|
|
|
|
- ZiJinCrawlerQrcodeResponse boHaiPaymentResponse = boHaiCrawlerRequestComponent.payment(boHaiCrawlerPaymentCertiNoQueryRequest, headers);
|
|
|
|
|
|
|
+ ZiJinCrawlerQrcodeResponse boHaiPaymentResponse = ziJinCrawlerRequestComponent.payment(boHaiCrawlerPaymentCertiNoQueryRequest, headers);
|
|
|
PaymentLinkResultsVo paymentLinkResultsVo = new PaymentLinkResultsVo();
|
|
PaymentLinkResultsVo paymentLinkResultsVo = new PaymentLinkResultsVo();
|
|
|
paymentLinkResultsVo.setPaymentLink(boHaiPaymentResponse.getUrl());
|
|
paymentLinkResultsVo.setPaymentLink(boHaiPaymentResponse.getUrl());
|
|
|
return paymentLinkResultsVo;
|
|
return paymentLinkResultsVo;
|
|
@@ -669,6 +252,7 @@ public class ZiJinCrawlerRequestImpl implements QuotationCrawlerBaseService {
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
* 影像上传
|
|
* 影像上传
|
|
|
|
|
+ *
|
|
|
* @param insuranceUploadImageVo
|
|
* @param insuranceUploadImageVo
|
|
|
*/
|
|
*/
|
|
|
@Override
|
|
@Override
|
|
@@ -676,15 +260,15 @@ public class ZiJinCrawlerRequestImpl implements QuotationCrawlerBaseService {
|
|
|
try {
|
|
try {
|
|
|
//获取归属信息
|
|
//获取归属信息
|
|
|
AttributionInformationVo attributionInformationVo = insuranceUploadImageVo.getOrder().getAttributionInformationVo();
|
|
AttributionInformationVo attributionInformationVo = insuranceUploadImageVo.getOrder().getAttributionInformationVo();
|
|
|
- ZiJinCrawlerOrder boHaiCrawlerOrder = boHaiCrawlerOrderService.getById(insuranceUploadImageVo.getOrder().getOrdersNo());
|
|
|
|
|
- HttpHeaders headers = boHaiCrawlerQuoteProcessService.getHeaders(attributionInformationVo.getUsername(), attributionInformationVo.getPassword());
|
|
|
|
|
|
|
+ ZiJinCrawlerOrder boHaiCrawlerOrder = ziJinCrawlerOrderService.getById(insuranceUploadImageVo.getOrder().getOrdersNo());
|
|
|
|
|
+ HttpHeaders headers = ziJinCrawlerQuoteProcessService.getHeaders(attributionInformationVo.getUsername(), attributionInformationVo.getPassword());
|
|
|
|
|
|
|
|
ZiJinCrawlerConfigureParameters parameters = ConfigureParametersConversion.conversionEntity(ZiJinCrawlerConfigureParameters.class, attributionInformationVo.getConfigInfo());
|
|
ZiJinCrawlerConfigureParameters parameters = ConfigureParametersConversion.conversionEntity(ZiJinCrawlerConfigureParameters.class, attributionInformationVo.getConfigInfo());
|
|
|
|
|
|
|
|
// 上传影像文件请求参数
|
|
// 上传影像文件请求参数
|
|
|
ZiJinCrawlerImageUploadRequestDto boHaiCrawlerImageUploadRequest = new ZiJinCrawlerImageUploadRequestDto(parameters, boHaiCrawlerOrder.getOrderNo(), insuranceUploadImageVo.getImageVoList());
|
|
ZiJinCrawlerImageUploadRequestDto boHaiCrawlerImageUploadRequest = new ZiJinCrawlerImageUploadRequestDto(parameters, boHaiCrawlerOrder.getOrderNo(), insuranceUploadImageVo.getImageVoList());
|
|
|
- ZiJinCrawlerImageUploadSubmitResponse boHaiCrawlerImageUploadSubmitResponse = boHaiCrawlerRequestComponent.uploadImage(boHaiCrawlerImageUploadRequest, headers);
|
|
|
|
|
- log.info("boHaiCrawlerImageUploadSubmitResponse对象的值:{}",JSON.toJSONString(boHaiCrawlerImageUploadSubmitResponse));
|
|
|
|
|
|
|
+ ZiJinCrawlerImageUploadSubmitResponse boHaiCrawlerImageUploadSubmitResponse = ziJinCrawlerRequestComponent.uploadImage(boHaiCrawlerImageUploadRequest, headers);
|
|
|
|
|
+ log.info("boHaiCrawlerImageUploadSubmitResponse对象的值:{}", JSON.toJSONString(boHaiCrawlerImageUploadSubmitResponse));
|
|
|
} catch (Exception e) {
|
|
} catch (Exception e) {
|
|
|
e.printStackTrace();
|
|
e.printStackTrace();
|
|
|
throw new RuntimeException(e);
|
|
throw new RuntimeException(e);
|
|
@@ -693,6 +277,7 @@ public class ZiJinCrawlerRequestImpl implements QuotationCrawlerBaseService {
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
* 构建支付凭证查询请求对象
|
|
* 构建支付凭证查询请求对象
|
|
|
|
|
+ *
|
|
|
* @param orderNo 订单号
|
|
* @param orderNo 订单号
|
|
|
* @return ZiJinCrawlerPaymentCertiNoQueryRequest 支付凭证查询请求对象
|
|
* @return ZiJinCrawlerPaymentCertiNoQueryRequest 支付凭证查询请求对象
|
|
|
*/
|
|
*/
|
|
@@ -800,6 +385,7 @@ public class ZiJinCrawlerRequestImpl implements QuotationCrawlerBaseService {
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
* 下载保单
|
|
* 下载保单
|
|
|
|
|
+ *
|
|
|
* @param downloadPolicyVo
|
|
* @param downloadPolicyVo
|
|
|
* @return DownloadPolicyResultVo
|
|
* @return DownloadPolicyResultVo
|
|
|
*/
|
|
*/
|
|
@@ -807,8 +393,8 @@ public class ZiJinCrawlerRequestImpl implements QuotationCrawlerBaseService {
|
|
|
public DownloadPolicyResultVo downloadPolicy(DownloadPolicyVo downloadPolicyVo) {
|
|
public DownloadPolicyResultVo downloadPolicy(DownloadPolicyVo downloadPolicyVo) {
|
|
|
//获取归属信息
|
|
//获取归属信息
|
|
|
AttributionInformationVo attributionInformationVo = downloadPolicyVo.getOrder().getAttributionInformationVo();
|
|
AttributionInformationVo attributionInformationVo = downloadPolicyVo.getOrder().getAttributionInformationVo();
|
|
|
- HttpHeaders headers = boHaiCrawlerQuoteProcessService.getHeaders(attributionInformationVo.getUsername(), attributionInformationVo.getPassword());
|
|
|
|
|
- ZiJinCrawlerOrder boHaiCrawlerOrder = boHaiCrawlerOrderService.getById(downloadPolicyVo.getOrder().getOrdersNo());
|
|
|
|
|
|
|
+ HttpHeaders headers = ziJinCrawlerQuoteProcessService.getHeaders(attributionInformationVo.getUsername(), attributionInformationVo.getPassword());
|
|
|
|
|
+ ZiJinCrawlerOrder boHaiCrawlerOrder = ziJinCrawlerOrderService.getById(downloadPolicyVo.getOrder().getOrdersNo());
|
|
|
|
|
|
|
|
/*ElectronicPolicyRequest electronicPolicyRequest = new ElectronicPolicyRequest(attributionInformationVo.getConfigInfo(),
|
|
/*ElectronicPolicyRequest electronicPolicyRequest = new ElectronicPolicyRequest(attributionInformationVo.getConfigInfo(),
|
|
|
boHaiCrawlerOrder.getOrderNo(), boHaiCrawlerOrder.getCiPolicyNo(), boHaiCrawlerOrder.getBiPolicyNo());*/
|
|
boHaiCrawlerOrder.getOrderNo(), boHaiCrawlerOrder.getCiPolicyNo(), boHaiCrawlerOrder.getBiPolicyNo());*/
|
|
@@ -819,15 +405,15 @@ public class ZiJinCrawlerRequestImpl implements QuotationCrawlerBaseService {
|
|
|
// 下载交强险保单
|
|
// 下载交强险保单
|
|
|
if (StringUtils.hasLength(boHaiCrawlerOrder.getCiPolicyNo())) {
|
|
if (StringUtils.hasLength(boHaiCrawlerOrder.getCiPolicyNo())) {
|
|
|
//boHaiCrawlerDownloadRequest.setBusinessNo(boHaiCrawlerOrder.getCiPolicyNo());
|
|
//boHaiCrawlerDownloadRequest.setBusinessNo(boHaiCrawlerOrder.getCiPolicyNo());
|
|
|
- response = boHaiCrawlerRequestComponent.electronPolicyIODownload(boHaiCrawlerDownloadRequest, headers);
|
|
|
|
|
|
|
+ response = ziJinCrawlerRequestComponent.electronPolicyIODownload(boHaiCrawlerDownloadRequest, headers);
|
|
|
downloadPolicyResultVo.setJqUrl(response.getFiles().get(0).getAddress());
|
|
downloadPolicyResultVo.setJqUrl(response.getFiles().get(0).getAddress());
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
// 下载商业险保单
|
|
// 下载商业险保单
|
|
|
if (StringUtils.hasLength(boHaiCrawlerOrder.getBiPolicyNo())) {
|
|
if (StringUtils.hasLength(boHaiCrawlerOrder.getBiPolicyNo())) {
|
|
|
boHaiCrawlerDownloadRequest.setBusinessNo(boHaiCrawlerOrder.getBiPolicyNo());
|
|
boHaiCrawlerDownloadRequest.setBusinessNo(boHaiCrawlerOrder.getBiPolicyNo());
|
|
|
- response = boHaiCrawlerRequestComponent.electronPolicyIODownload(boHaiCrawlerDownloadRequest, headers);
|
|
|
|
|
- if(!CollectionUtils.isEmpty(response.getFiles())){
|
|
|
|
|
|
|
+ response = ziJinCrawlerRequestComponent.electronPolicyIODownload(boHaiCrawlerDownloadRequest, headers);
|
|
|
|
|
+ if (!CollectionUtils.isEmpty(response.getFiles())) {
|
|
|
downloadPolicyResultVo.setSyUrl(response.getFiles().get(0).getAddress());
|
|
downloadPolicyResultVo.setSyUrl(response.getFiles().get(0).getAddress());
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
@@ -835,8 +421,8 @@ public class ZiJinCrawlerRequestImpl implements QuotationCrawlerBaseService {
|
|
|
// 下载驾意险保单
|
|
// 下载驾意险保单
|
|
|
if (StringUtils.hasLength(boHaiCrawlerOrder.getNiPolicyNo())) {
|
|
if (StringUtils.hasLength(boHaiCrawlerOrder.getNiPolicyNo())) {
|
|
|
boHaiCrawlerDownloadRequest.setBusinessNo(boHaiCrawlerOrder.getNiPolicyNo());
|
|
boHaiCrawlerDownloadRequest.setBusinessNo(boHaiCrawlerOrder.getNiPolicyNo());
|
|
|
- response = boHaiCrawlerRequestComponent.electronPolicyIODownload(boHaiCrawlerDownloadRequest, headers);
|
|
|
|
|
- if(!CollectionUtils.isEmpty(response.getFiles())){
|
|
|
|
|
|
|
+ response = ziJinCrawlerRequestComponent.electronPolicyIODownload(boHaiCrawlerDownloadRequest, headers);
|
|
|
|
|
+ if (!CollectionUtils.isEmpty(response.getFiles())) {
|
|
|
downloadPolicyResultVo.setJyUrl(response.getFiles().get(0).getAddress());
|
|
downloadPolicyResultVo.setJyUrl(response.getFiles().get(0).getAddress());
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
@@ -878,11 +464,11 @@ public class ZiJinCrawlerRequestImpl implements QuotationCrawlerBaseService {
|
|
|
public OrderStatusResultVo queryOrderState(OrderStatusVo orderStatusVo) {
|
|
public OrderStatusResultVo queryOrderState(OrderStatusVo orderStatusVo) {
|
|
|
try {
|
|
try {
|
|
|
AttributionInformationVo attributionInformationVo = orderStatusVo.getOrder().getAttributionInformationVo();
|
|
AttributionInformationVo attributionInformationVo = orderStatusVo.getOrder().getAttributionInformationVo();
|
|
|
- HttpHeaders headers = boHaiCrawlerQuoteProcessService.getHeaders(attributionInformationVo.getUsername(), attributionInformationVo.getPassword());
|
|
|
|
|
- ZiJinCrawlerOrder boHaiCrawlerOrder = boHaiCrawlerOrderService.getById(orderStatusVo.getOrder().getOrdersNo());
|
|
|
|
|
|
|
+ HttpHeaders headers = ziJinCrawlerQuoteProcessService.getHeaders(attributionInformationVo.getUsername(), attributionInformationVo.getPassword());
|
|
|
|
|
+ ZiJinCrawlerOrder boHaiCrawlerOrder = ziJinCrawlerOrderService.getById(orderStatusVo.getOrder().getOrdersNo());
|
|
|
|
|
|
|
|
ZiJinCrawlerQueryOrderStatusRequest boHaiCrawlerQueryOrderStatusRequest = buildOrderStatusRequest(boHaiCrawlerOrder);
|
|
ZiJinCrawlerQueryOrderStatusRequest boHaiCrawlerQueryOrderStatusRequest = buildOrderStatusRequest(boHaiCrawlerOrder);
|
|
|
- ZiJinCrawlerQueryOrderStatusResponse boHaiCrawlerQueryOrderStatusResponse = boHaiCrawlerRequestComponent.queryOrderStatus(boHaiCrawlerQueryOrderStatusRequest, headers);
|
|
|
|
|
|
|
+ ZiJinCrawlerQueryOrderStatusResponse boHaiCrawlerQueryOrderStatusResponse = ziJinCrawlerRequestComponent.queryOrderStatus(boHaiCrawlerQueryOrderStatusRequest, headers);
|
|
|
log.info("查询订单状态响应:{}", JSON.toJSONString(boHaiCrawlerQueryOrderStatusResponse));
|
|
log.info("查询订单状态响应:{}", JSON.toJSONString(boHaiCrawlerQueryOrderStatusResponse));
|
|
|
//获取订单状态
|
|
//获取订单状态
|
|
|
InsOrderStatusEnum insOrderStatusEnum = determineOrderStatus(boHaiCrawlerQueryOrderStatusResponse);
|
|
InsOrderStatusEnum insOrderStatusEnum = determineOrderStatus(boHaiCrawlerQueryOrderStatusResponse);
|
|
@@ -898,6 +484,7 @@ public class ZiJinCrawlerRequestImpl implements QuotationCrawlerBaseService {
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
* 确定订单状态
|
|
* 确定订单状态
|
|
|
|
|
+ *
|
|
|
* @param response
|
|
* @param response
|
|
|
* @return InsOrderStatusEnum
|
|
* @return InsOrderStatusEnum
|
|
|
*/
|
|
*/
|
|
@@ -1022,7 +609,7 @@ public class ZiJinCrawlerRequestImpl implements QuotationCrawlerBaseService {
|
|
|
boHaiCrawlerVehicleConfirmationReqeust1.setBody(bodyDTO);
|
|
boHaiCrawlerVehicleConfirmationReqeust1.setBody(bodyDTO);
|
|
|
|
|
|
|
|
//调用车辆确认接口
|
|
//调用车辆确认接口
|
|
|
- ZiJinCrawlerVehicleConfirmationResponse2 boHaiCrawlerVehicleConfirmationResponse = boHaiCrawlerRequestComponent.vehicleConfirmation(boHaiCrawlerVehicleConfirmationReqeust1, headers);
|
|
|
|
|
|
|
+ ZiJinCrawlerVehicleConfirmationResponse2 boHaiCrawlerVehicleConfirmationResponse = ziJinCrawlerRequestComponent.vehicleConfirmation(boHaiCrawlerVehicleConfirmationReqeust1, headers);
|
|
|
log.info("boHaiCrawlerVehicleConfirmationResponse参数的值:{}", JSON.toJSONString(boHaiCrawlerVehicleConfirmationResponse));
|
|
log.info("boHaiCrawlerVehicleConfirmationResponse参数的值:{}", JSON.toJSONString(boHaiCrawlerVehicleConfirmationResponse));
|
|
|
|
|
|
|
|
Map<String, Object> map = new HashMap<>();
|
|
Map<String, Object> map = new HashMap<>();
|
|
@@ -1141,9 +728,10 @@ public class ZiJinCrawlerRequestImpl implements QuotationCrawlerBaseService {
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
* 创建车辆信息(用于核保)
|
|
* 创建车辆信息(用于核保)
|
|
|
|
|
+ *
|
|
|
* @return CarInfo
|
|
* @return CarInfo
|
|
|
*/
|
|
*/
|
|
|
- private ZiJinCrawlerUnderwritingRequest2.CarInfo createCarInfo(){
|
|
|
|
|
|
|
+ private ZiJinCrawlerUnderwritingRequest2.CarInfo createCarInfo() {
|
|
|
ZiJinCrawlerUnderwritingRequest2.CarInfo carInfo = new ZiJinCrawlerUnderwritingRequest2.CarInfo();
|
|
ZiJinCrawlerUnderwritingRequest2.CarInfo carInfo = new ZiJinCrawlerUnderwritingRequest2.CarInfo();
|
|
|
|
|
|
|
|
// 创建车辆详细信息
|
|
// 创建车辆详细信息
|
|
@@ -2086,7 +1674,7 @@ public class ZiJinCrawlerRequestImpl implements QuotationCrawlerBaseService {
|
|
|
/**
|
|
/**
|
|
|
* 构建订单状态查询请求对象
|
|
* 构建订单状态查询请求对象
|
|
|
*
|
|
*
|
|
|
- * @param boHaiCrawlerOrder 渤海爬虫订单
|
|
|
|
|
|
|
+ * @param boHaiCrawlerOrder 渤海爬虫订单
|
|
|
* @return ZiJinCrawlerQueryOrderStatusRequest
|
|
* @return ZiJinCrawlerQueryOrderStatusRequest
|
|
|
*/
|
|
*/
|
|
|
private ZiJinCrawlerQueryOrderStatusRequest buildOrderStatusRequest(ZiJinCrawlerOrder boHaiCrawlerOrder) {
|
|
private ZiJinCrawlerQueryOrderStatusRequest buildOrderStatusRequest(ZiJinCrawlerOrder boHaiCrawlerOrder) {
|