|
@@ -5,13 +5,17 @@ import com.fasterxml.jackson.core.JsonProcessingException;
|
|
|
import com.fasterxml.jackson.databind.ObjectMapper;
|
|
import com.fasterxml.jackson.databind.ObjectMapper;
|
|
|
import com.jzg.commons.constants.ProductsType;
|
|
import com.jzg.commons.constants.ProductsType;
|
|
|
import com.jzg.commons.constants.dict.InsOrderStatusEnum;
|
|
import com.jzg.commons.constants.dict.InsOrderStatusEnum;
|
|
|
|
|
+import com.jzg.commons.core.page.HttpResult;
|
|
|
|
|
+import com.jzg.commons.entity.po.jyxSetting;
|
|
|
import com.jzg.commons.entity.quote.vo.AttributionInformationVo;
|
|
import com.jzg.commons.entity.quote.vo.AttributionInformationVo;
|
|
|
import com.jzg.commons.entity.quote.vo.CarInfoVo;
|
|
import com.jzg.commons.entity.quote.vo.CarInfoVo;
|
|
|
import com.jzg.commons.entity.quote.vo.QuoteVo;
|
|
import com.jzg.commons.entity.quote.vo.QuoteVo;
|
|
|
import com.jzg.commons.entity.quote.vo.aggregated.*;
|
|
import com.jzg.commons.entity.quote.vo.aggregated.*;
|
|
|
|
|
+import com.jzg.commons.entity.vo.JyxConfigVo;
|
|
|
import com.jzg.commons.exception.SystemException;
|
|
import com.jzg.commons.exception.SystemException;
|
|
|
import com.jzg.commons.util.StringUtils;
|
|
import com.jzg.commons.util.StringUtils;
|
|
|
import com.jzg.quotation.commons.annotation.QuoteCrawlerService;
|
|
import com.jzg.quotation.commons.annotation.QuoteCrawlerService;
|
|
|
|
|
+import com.jzg.quotation.commons.client.PlatformClient;
|
|
|
import com.jzg.quotation.commons.constant.InsuranceCode;
|
|
import com.jzg.quotation.commons.constant.InsuranceCode;
|
|
|
import com.jzg.commons.entity.quote.vo.base.LoginBase;
|
|
import com.jzg.commons.entity.quote.vo.base.LoginBase;
|
|
|
import com.jzg.commons.entity.quote.vo.base.OrderBase;
|
|
import com.jzg.commons.entity.quote.vo.base.OrderBase;
|
|
@@ -70,6 +74,7 @@ import java.security.cert.X509Certificate;
|
|
|
import java.time.LocalDateTime;
|
|
import java.time.LocalDateTime;
|
|
|
import java.time.format.DateTimeFormatter;
|
|
import java.time.format.DateTimeFormatter;
|
|
|
import java.util.*;
|
|
import java.util.*;
|
|
|
|
|
+import java.util.concurrent.atomic.AtomicReference;
|
|
|
import java.util.regex.Matcher;
|
|
import java.util.regex.Matcher;
|
|
|
import java.util.regex.Pattern;
|
|
import java.util.regex.Pattern;
|
|
|
|
|
|
|
@@ -91,6 +96,8 @@ public class HuaTaiCrawlerRequestImpl implements HuaTaiCrawlerRequest {
|
|
|
|
|
|
|
|
private final HtCrawlerOrderService htCrawlerOrderService;
|
|
private final HtCrawlerOrderService htCrawlerOrderService;
|
|
|
|
|
|
|
|
|
|
+ private final PlatformClient platformClient;
|
|
|
|
|
+
|
|
|
@Value("${huatai.api.username}")
|
|
@Value("${huatai.api.username}")
|
|
|
private String username;
|
|
private String username;
|
|
|
|
|
|
|
@@ -100,8 +107,6 @@ public class HuaTaiCrawlerRequestImpl implements HuaTaiCrawlerRequest {
|
|
|
@Value("${huatai.api.comcode}")
|
|
@Value("${huatai.api.comcode}")
|
|
|
private String comcode;
|
|
private String comcode;
|
|
|
|
|
|
|
|
- private String basePartJSON = "";
|
|
|
|
|
-
|
|
|
|
|
// 特殊账号列表
|
|
// 特殊账号列表
|
|
|
private final List<String> specialUsers = Arrays.asList(
|
|
private final List<String> specialUsers = Arrays.asList(
|
|
|
"EA27000180", "EA27000401", "EA27000098", "EA27000076",
|
|
"EA27000180", "EA27000401", "EA27000098", "EA27000076",
|
|
@@ -109,7 +114,7 @@ public class HuaTaiCrawlerRequestImpl implements HuaTaiCrawlerRequest {
|
|
|
"EA27000381", "EA27000394", "XN9279003"
|
|
"EA27000381", "EA27000394", "XN9279003"
|
|
|
);
|
|
);
|
|
|
|
|
|
|
|
- private final ObjectMapper objectMapper = new ObjectMapper();
|
|
|
|
|
|
|
+ private static final ObjectMapper objectMapper = new ObjectMapper();
|
|
|
|
|
|
|
|
private Map<String, Object> gsInfo = new HashMap<>();
|
|
private Map<String, Object> gsInfo = new HashMap<>();
|
|
|
|
|
|
|
@@ -433,6 +438,8 @@ public class HuaTaiCrawlerRequestImpl implements HuaTaiCrawlerRequest {
|
|
|
@NotNull
|
|
@NotNull
|
|
|
private Result2 getResult2(QuoteVo quoteVo, int retryCount, int maxRetries, boolean success, Result result, String quotationNo, LoginDTO loginDTO, Map<String, Object> gsInfo, String cookie, HtCrawlerQuoteResponse.DataDTO quoteResponseData, AttributionInformationVo attributionInformationVo) {
|
|
private Result2 getResult2(QuoteVo quoteVo, int retryCount, int maxRetries, boolean success, Result result, String quotationNo, LoginDTO loginDTO, Map<String, Object> gsInfo, String cookie, HtCrawlerQuoteResponse.DataDTO quoteResponseData, AttributionInformationVo attributionInformationVo) {
|
|
|
HttpHeaders headers2;
|
|
HttpHeaders headers2;
|
|
|
|
|
+ String basePartJSON = "";
|
|
|
|
|
+ String personalInsuredJSONString = "";
|
|
|
String fcPrice = "";
|
|
String fcPrice = "";
|
|
|
while (retryCount < maxRetries && !success) {
|
|
while (retryCount < maxRetries && !success) {
|
|
|
try {
|
|
try {
|
|
@@ -464,11 +471,97 @@ public class HuaTaiCrawlerRequestImpl implements HuaTaiCrawlerRequest {
|
|
|
String mealid = "";
|
|
String mealid = "";
|
|
|
if (mealidMatcher.find()) {
|
|
if (mealidMatcher.find()) {
|
|
|
mealid = mealidMatcher.group(1);
|
|
mealid = mealidMatcher.group(1);
|
|
|
- System.out.println("mealid::"+mealid);
|
|
|
|
|
|
|
+ System.out.println("mealid::" + mealid);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
//报价第二步
|
|
//报价第二步
|
|
|
- HtCrawlerQuoteRequest htCrawlerQuoteRequest = new HtCrawlerQuoteRequest(quoteVo, mealid, basePartJSON);
|
|
|
|
|
|
|
+ //如果有驾意险
|
|
|
|
|
+ List<Map<String, Object>> personalInsuredJSON = new ArrayList<>();
|
|
|
|
|
+ List<Map<String, Object>> perinsuredList = new ArrayList<>();
|
|
|
|
|
+ if (quoteVo.getAccidentalDrivings() != null && !quoteVo.getAccidentalDrivings().isEmpty()) {
|
|
|
|
|
+ AtomicReference<jyxSetting> setting = new AtomicReference<>(new jyxSetting());
|
|
|
|
|
+ AtomicReference<JyxConfigVo> jyxConfigVo = new AtomicReference<>(new JyxConfigVo());
|
|
|
|
|
+ quoteVo.getAccidentalDrivings().forEach(drivingDTO -> {
|
|
|
|
|
+ // 查询jyx_config表,拿到总保额和总保费
|
|
|
|
|
+ HttpResult<JyxConfigVo> jyxConfigVoHttpResult = platformClient.jyxConfigGetById(drivingDTO.getId());
|
|
|
|
|
+ jyxConfigVo.set(jyxConfigVoHttpResult.getData());
|
|
|
|
|
+ setting.set(jyxConfigVo.get().getSettingList().stream()
|
|
|
|
|
+ .filter(s -> s.getSeats() == Integer.parseInt(quoteVo.getCarInfoVo().getSeatCount()))
|
|
|
|
|
+ .findFirst()
|
|
|
|
|
+ .orElse(null));
|
|
|
|
|
+ String productCode = jyxConfigVo.get().getParentProductCode();
|
|
|
|
|
+ Map<String, Object> insuredInfo = new HashMap<>();
|
|
|
|
|
+ //insuredInfo.put("allQuantity", "");
|
|
|
|
|
+ //insuredInfo.put("planName", "");
|
|
|
|
|
+ insuredInfo.put("productcode", StringUtils.isEmpty(productCode) ? "E007" : productCode);
|
|
|
|
|
+ insuredInfo.put("mark", "1");
|
|
|
|
|
+ insuredInfo.put("insuredname", quoteVo.getInsuredPersonInfo().getName());
|
|
|
|
|
+ insuredInfo.put("certitype", "01");
|
|
|
|
|
+ insuredInfo.put("certicode", quoteVo.getInsuredPersonInfo().getIdentifyNumber());
|
|
|
|
|
+ insuredInfo.put("age", quoteVo.getInsuredPersonInfo().getBirthday().substring(0, 10));//quoteVo.getInsuredPersonInfo().getAge()
|
|
|
|
|
+ insuredInfo.put("gender", quoteVo.getInsuredPersonInfo().getGender());
|
|
|
|
|
+ insuredInfo.put("perProWithCarStartDate", "");
|
|
|
|
|
+ insuredInfo.put("perProWithCarEndDate", "");
|
|
|
|
|
+ insuredInfo.put("relation", quoteVo.getOwnersInfo().getName().equals(quoteVo.getInsuredPersonInfo().getName()) ? "00" : "99");
|
|
|
|
|
+ insuredInfo.put("job", "");
|
|
|
|
|
+ insuredInfo.put("parentcode", "");
|
|
|
|
|
+ insuredInfo.put("parentname", "");
|
|
|
|
|
+ insuredInfo.put("parametercode", "");
|
|
|
|
|
+ insuredInfo.put("parametername", "");
|
|
|
|
|
+ insuredInfo.put("codecode", "");
|
|
|
|
|
+ insuredInfo.put("codecname", "");
|
|
|
|
|
+ insuredInfo.put("risktype", "");
|
|
|
|
|
+ insuredInfo.put("jobtype", "");
|
|
|
|
|
+ insuredInfo.put("customerno", "");
|
|
|
|
|
+ insuredInfo.put("workname", "");
|
|
|
|
|
+ insuredInfo.put("workphone", "");
|
|
|
|
|
+ insuredInfo.put("yearmoney", "");
|
|
|
|
|
+ insuredInfo.put("workaddress", "");
|
|
|
|
|
+ insuredInfo.put("otherphone", "");
|
|
|
|
|
+ insuredInfo.put("otheraddress", "");
|
|
|
|
|
+ insuredInfo.put("mobile", "");
|
|
|
|
|
+ insuredInfo.put("urgentname", "");
|
|
|
|
|
+ insuredInfo.put("urgentmobile", "");
|
|
|
|
|
+ insuredInfo.put("nationality", "CHN");
|
|
|
|
|
+
|
|
|
|
|
+ perinsuredList.add(insuredInfo);
|
|
|
|
|
+ });
|
|
|
|
|
+ Map<String, Object> accidentalDriving = new HashMap<>();
|
|
|
|
|
+ accidentalDriving.put("butouflag", "");
|
|
|
|
|
+ accidentalDriving.put("amount", setting.get().getCoverage() == null ? "" : setting.get().getCoverage().toString().replace(".00", ""));
|
|
|
|
|
+ accidentalDriving.put("car_limitloadperson", StringUtils.isBlank(String.valueOf(setting.get().getSeats())) ? "" : setting.get().getSeats());
|
|
|
|
|
+ accidentalDriving.put("isInsuredPassenger", "");
|
|
|
|
|
+ accidentalDriving.put("productcode", jyxConfigVo.get().getParentProductCode());
|
|
|
|
|
+ accidentalDriving.put("productname", "");//"“百万驾乘”意外伤害保险"
|
|
|
|
|
+ accidentalDriving.put("mealcode", jyxConfigVo.get().getProductCode());//jyxConfigVo.get().getProductCode()
|
|
|
|
|
+ accidentalDriving.put("mealname", "");//jyxConfigVo.get().getProductName() //"经济款"
|
|
|
|
|
+ accidentalDriving.put("startdate", quoteVo.getCiRiskInfoVo().getStartDate());
|
|
|
|
|
+ accidentalDriving.put("enddate", quoteVo.getCiRiskInfoVo().getStartDate().replace("2026", "2027"));//quoteVo.getCiRiskInfoVo().getEndDate()
|
|
|
|
|
+ accidentalDriving.put("num", "1");
|
|
|
|
|
+ accidentalDriving.put("premium", setting.get().getPremium() == null ? "" : setting.get().getPremium().toString().replace(".00", ".0"));
|
|
|
|
|
+ accidentalDriving.put("formationJudiciary", "");
|
|
|
|
|
+ accidentalDriving.put("argueJudiciary", "");
|
|
|
|
|
+ accidentalDriving.put("newCarSalesProvince", "");
|
|
|
|
|
+ accidentalDriving.put("newCarSalesCity", "");
|
|
|
|
|
+ accidentalDriving.put("newCarSalesDistrict", "");
|
|
|
|
|
+ accidentalDriving.put("buildYear", "");
|
|
|
|
|
+ accidentalDriving.put("xiangxiAddress", "");
|
|
|
|
|
+ accidentalDriving.put("postalCode", "");
|
|
|
|
|
+ accidentalDriving.put("bulidTypeCode", "");
|
|
|
|
|
+ accidentalDriving.put("bulidTypeQiTaMes", "");
|
|
|
|
|
+ accidentalDriving.put("provinceName", "");
|
|
|
|
|
+ accidentalDriving.put("cityName", "");
|
|
|
|
|
+ accidentalDriving.put("regionName", "");
|
|
|
|
|
+ accidentalDriving.put("isInsuredSizesFlag", "0");
|
|
|
|
|
+ accidentalDriving.put("perinsuredList", perinsuredList);
|
|
|
|
|
+ accidentalDriving.put("car_limitloadperson", quoteVo.getCarInfoVo().getSeatCount());
|
|
|
|
|
+ accidentalDriving.put("startdate", quoteVo.getCiRiskInfoVo().getStartDate());
|
|
|
|
|
+ accidentalDriving.put("enddate", quoteVo.getCiRiskInfoVo().getEndDate());
|
|
|
|
|
+ personalInsuredJSON.add(accidentalDriving);
|
|
|
|
|
+
|
|
|
|
|
+ personalInsuredJSONString = JSONObject.toJSONString(personalInsuredJSON);
|
|
|
|
|
+ }
|
|
|
|
|
+ HtCrawlerQuoteRequest htCrawlerQuoteRequest = new HtCrawlerQuoteRequest(quoteVo, mealid, basePartJSON, personalInsuredJSONString);
|
|
|
headers2 = new HttpHeaders();
|
|
headers2 = new HttpHeaders();
|
|
|
headers2.add(HtRequestConstant.COOKIE, cookie);
|
|
headers2.add(HtRequestConstant.COOKIE, cookie);
|
|
|
headers2.add("Accept", "*/*");
|
|
headers2.add("Accept", "*/*");
|
|
@@ -483,39 +576,38 @@ public class HuaTaiCrawlerRequestImpl implements HuaTaiCrawlerRequest {
|
|
|
headers2.add("X-Requested-With", "XMLHttpRequest");
|
|
headers2.add("X-Requested-With", "XMLHttpRequest");
|
|
|
|
|
|
|
|
String decryptData = htCrawlerRequestComponent.quote(htCrawlerQuoteRequest, headers2);
|
|
String decryptData = htCrawlerRequestComponent.quote(htCrawlerQuoteRequest, headers2);
|
|
|
- //System.out.println("decryptData::HtCrawlerQuoteResponse::"+decryptData);
|
|
|
|
|
- if(decryptData.contains("errrorFlag") && decryptData.contains("carChange")) {//请修改新车购置价
|
|
|
|
|
|
|
+ if (decryptData.contains("errrorFlag") && decryptData.contains("carChange")) {//请修改新车购置价
|
|
|
//重新获取车型
|
|
//重新获取车型
|
|
|
//throw new RuntimeException("请修改新车购置价/重新获取车型");
|
|
//throw new RuntimeException("请修改新车购置价/重新获取车型");
|
|
|
retryCount = maxRetries + 1;
|
|
retryCount = maxRetries + 1;
|
|
|
HtCrawlerQuoteResponse.DataErrDTO dataErr = JSONObject.parseObject(decryptData, HtCrawlerQuoteResponse.DataErrDTO.class);
|
|
HtCrawlerQuoteResponse.DataErrDTO dataErr = JSONObject.parseObject(decryptData, HtCrawlerQuoteResponse.DataErrDTO.class);
|
|
|
- throw new RuntimeException("报价失败:"+dataErr.getErroeInfo().substring(dataErr.getErroeInfo().indexOf("中国")));
|
|
|
|
|
|
|
+ throw new RuntimeException("报价失败:" + dataErr.getErroeInfo().substring(dataErr.getErroeInfo().indexOf("中国")));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- if(decryptData.contains("erroeInfo") && decryptData.contains("投保查询校验信息不存在或已经校验成功")) {
|
|
|
|
|
|
|
+ if (decryptData.contains("erroeInfo") && decryptData.contains("投保查询校验信息不存在或已经校验成功")) {
|
|
|
//投保查询校验信息不存在或已经校验成功
|
|
//投保查询校验信息不存在或已经校验成功
|
|
|
//throw new RuntimeException("投保查询校验信息不存在或已经校验成功");
|
|
//throw new RuntimeException("投保查询校验信息不存在或已经校验成功");
|
|
|
retryCount = maxRetries + 1;
|
|
retryCount = maxRetries + 1;
|
|
|
HtCrawlerQuoteResponse.DataErrDTO dataErr = JSONObject.parseObject(decryptData, HtCrawlerQuoteResponse.DataErrDTO.class);
|
|
HtCrawlerQuoteResponse.DataErrDTO dataErr = JSONObject.parseObject(decryptData, HtCrawlerQuoteResponse.DataErrDTO.class);
|
|
|
- throw new RuntimeException("报价失败:"+dataErr.getErroeInfo().substring(dataErr.getErroeInfo().indexOf("中国")));
|
|
|
|
|
|
|
+ throw new RuntimeException("报价失败:" + dataErr.getErroeInfo().substring(dataErr.getErroeInfo().indexOf("中国")));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- if(decryptData.contains("erroeInfo") && decryptData.contains("起保日期必须在当前日期的30天范围内")) {
|
|
|
|
|
|
|
+ if (decryptData.contains("erroeInfo") && decryptData.contains("起保日期必须在当前日期的30天范围内")) {
|
|
|
//投保查询校验信息不存在或已经校验成功
|
|
//投保查询校验信息不存在或已经校验成功
|
|
|
//throw new RuntimeException("起保日期必须在当前日期的30天范围内");
|
|
//throw new RuntimeException("起保日期必须在当前日期的30天范围内");
|
|
|
retryCount = maxRetries + 1;
|
|
retryCount = maxRetries + 1;
|
|
|
HtCrawlerQuoteResponse.DataErrDTO dataErr = JSONObject.parseObject(decryptData, HtCrawlerQuoteResponse.DataErrDTO.class);
|
|
HtCrawlerQuoteResponse.DataErrDTO dataErr = JSONObject.parseObject(decryptData, HtCrawlerQuoteResponse.DataErrDTO.class);
|
|
|
- throw new RuntimeException("报价失败:"+dataErr.getErroeInfo().substring(dataErr.getErroeInfo().indexOf("中国")));
|
|
|
|
|
|
|
+ throw new RuntimeException("报价失败:" + dataErr.getErroeInfo().substring(dataErr.getErroeInfo().indexOf("中国")));
|
|
|
}
|
|
}
|
|
|
//晋AB8H22存在有效交强险保单,请核实保期进入续保期后再进行投保。
|
|
//晋AB8H22存在有效交强险保单,请核实保期进入续保期后再进行投保。
|
|
|
//{"erroeInfo":"投保业务:投保业务:中国银保信交强险平台友情提示:号牌号码“晋AB8H22”的保单发生重复投保,与其重复投保的本公司的保单信息如下:车架号 LGWEF4A54HF017616;发动机号 1725032719;地区 山西。","erroeType":"01","errrorFlag":"true"}
|
|
//{"erroeInfo":"投保业务:投保业务:中国银保信交强险平台友情提示:号牌号码“晋AB8H22”的保单发生重复投保,与其重复投保的本公司的保单信息如下:车架号 LGWEF4A54HF017616;发动机号 1725032719;地区 山西。","erroeType":"01","errrorFlag":"true"}
|
|
|
- if(decryptData.contains("erroeInfo") && decryptData.contains("发生重复投保") && !decryptData.contains("终保日期")) {
|
|
|
|
|
|
|
+ if (decryptData.contains("erroeInfo") && decryptData.contains("发生重复投保") && !decryptData.contains("终保日期")) {
|
|
|
retryCount = maxRetries + 1;
|
|
retryCount = maxRetries + 1;
|
|
|
HtCrawlerQuoteResponse.DataErrDTO dataErr = JSONObject.parseObject(decryptData, HtCrawlerQuoteResponse.DataErrDTO.class);
|
|
HtCrawlerQuoteResponse.DataErrDTO dataErr = JSONObject.parseObject(decryptData, HtCrawlerQuoteResponse.DataErrDTO.class);
|
|
|
- throw new RuntimeException("报价失败:"+dataErr.getErroeInfo().substring(dataErr.getErroeInfo().indexOf("中国")));
|
|
|
|
|
|
|
+ throw new RuntimeException("报价失败:" + dataErr.getErroeInfo().substring(dataErr.getErroeInfo().indexOf("中国")));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- if((decryptData.contains("erroeInfo") && decryptData.contains("发生重复投保") && decryptData.contains("终保日期")) || decryptData.contains("录入的校验码有误")) {
|
|
|
|
|
|
|
+ if ((decryptData.contains("erroeInfo") && decryptData.contains("发生重复投保") && decryptData.contains("终保日期")) || decryptData.contains("录入的校验码有误")) {
|
|
|
HtCrawlerQuoteResponse.DataErrDTO dataErrDTO = JSONObject.parseObject(decryptData, HtCrawlerQuoteResponse.DataErrDTO.class);
|
|
HtCrawlerQuoteResponse.DataErrDTO dataErrDTO = JSONObject.parseObject(decryptData, HtCrawlerQuoteResponse.DataErrDTO.class);
|
|
|
//{
|
|
//{
|
|
|
// "erroeInfo" : "投保业务:投保业务:中国银保信交强险平台友情提示:号牌号码“晋AQ93G8”的保单发生重复投保,与其重复投保的其它公司的保单信息如下:投保确认码 02HBIC140025061888945034991892;保单号 H070503080120250028429;起保日期 2025-06-03 18:49;终保日期 2026-06-03 18:49;号牌号码 晋AQ93G8;号牌种类 02;车架号 LSVCH6A43DN070172;发动机号 U01490;地区 山西。",
|
|
// "erroeInfo" : "投保业务:投保业务:中国银保信交强险平台友情提示:号牌号码“晋AQ93G8”的保单发生重复投保,与其重复投保的其它公司的保单信息如下:投保确认码 02HBIC140025061888945034991892;保单号 H070503080120250028429;起保日期 2025-06-03 18:49;终保日期 2026-06-03 18:49;号牌号码 晋AQ93G8;号牌种类 02;车架号 LSVCH6A43DN070172;发动机号 U01490;地区 山西。",
|
|
@@ -528,7 +620,7 @@ public class HuaTaiCrawlerRequestImpl implements HuaTaiCrawlerRequest {
|
|
|
|
|
|
|
|
if (matcher.find()) {
|
|
if (matcher.find()) {
|
|
|
String endDate = matcher.group(1).trim();
|
|
String endDate = matcher.group(1).trim();
|
|
|
- String startDate = endDate+":00";
|
|
|
|
|
|
|
+ String startDate = endDate + ":00";
|
|
|
quoteVo.getCiRiskInfoVo().setStartDate(startDate);
|
|
quoteVo.getCiRiskInfoVo().setStartDate(startDate);
|
|
|
try {
|
|
try {
|
|
|
LocalDateTime dateTime = LocalDateTime.parse(
|
|
LocalDateTime dateTime = LocalDateTime.parse(
|
|
@@ -549,102 +641,51 @@ public class HuaTaiCrawlerRequestImpl implements HuaTaiCrawlerRequest {
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- if(decryptData.contains("erroeInfo")) {
|
|
|
|
|
|
|
+ if (decryptData.contains("erroeInfo")) {
|
|
|
//投保查询校验信息不存在或已经校验成功
|
|
//投保查询校验信息不存在或已经校验成功
|
|
|
//throw new RuntimeException("投保查询校验信息不存在或已经校验成功");
|
|
//throw new RuntimeException("投保查询校验信息不存在或已经校验成功");
|
|
|
- HtCrawlerQuoteResponse.DataErrDTO dataErr = JSONObject.parseObject(decryptData, HtCrawlerQuoteResponse.DataErrDTO.class);
|
|
|
|
|
- throw new RuntimeException("报价失败:"+dataErr.getErroeInfo().substring(dataErr.getErroeInfo().indexOf("中国")));
|
|
|
|
|
|
|
+ Map<String, Object> dataErr = JSONObject.parseObject(decryptData, Map.class);
|
|
|
|
|
+ throw new RuntimeException("报价失败:" + dataErr.get("erroeInfo").toString());
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- quoteResponseData = getDataDTO(quoteVo, decryptData, mealid, headers2);
|
|
|
|
|
|
|
+ quoteResponseData = getDataDTO(quoteVo, decryptData, mealid, headers2, basePartJSON, personalInsuredJSONString);
|
|
|
|
|
|
|
|
- if(quoteResponseData.getApplicationdto() != null) {
|
|
|
|
|
|
|
+ if (quoteResponseData.getApplicationdto() != null) {
|
|
|
success = true;
|
|
success = true;
|
|
|
|
|
|
|
|
// 调用非车险保费接口
|
|
// 调用非车险保费接口
|
|
|
- //HttpHeaders fcHeaders = new HttpHeaders();
|
|
|
|
|
- //fcHeaders.add(HtRequestConstant.COOKIE, cookie);
|
|
|
|
|
- //fcHeaders.add("Accept", "*/*");
|
|
|
|
|
- //fcHeaders.add("Accept-Language", "zh-CN,zh;q=0.9");
|
|
|
|
|
- //fcHeaders.add("Connection", "keep-alive");
|
|
|
|
|
- //fcHeaders.add("Content-Type", "application/x-www-form-urlencoded; charset=UTF-8");
|
|
|
|
|
- //fcHeaders.add("Origin", "https://cspxp.pc.ehuatai.com");
|
|
|
|
|
- //fcHeaders.add("Referer", "https://cspxp.pc.ehuatai.com/htcsp/VehicleInfoEntryAction.do?cmd=saveOneStept");
|
|
|
|
|
- //fcHeaders.add("User-Agent", "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/138.0.0.0 Safari/537.36");
|
|
|
|
|
- //fcHeaders.add("X-Requested-With", "XMLHttpRequest");
|
|
|
|
|
-//
|
|
|
|
|
- //MultiValueMap<String, String> fcData = new LinkedMultiValueMap<>();
|
|
|
|
|
-//
|
|
|
|
|
- //List<Map<String, Object>> personalInsuredJSON = new ArrayList<>();
|
|
|
|
|
- //List<Map<String, Object>> perinsuredList = new ArrayList<>();
|
|
|
|
|
- ////String productcode = accidentalDriving.get("productcode") != null ? accidentalDriving.get("productcode").toString() : "";
|
|
|
|
|
-//
|
|
|
|
|
- //Map<String, Object> insuredInfo = new HashMap<>();
|
|
|
|
|
- //insuredInfo.put("allQuantity", "");
|
|
|
|
|
- //insuredInfo.put("planName", "");
|
|
|
|
|
- //insuredInfo.put("productcode", "E007");//StringUtils.isEmpty(productcode) ? "E007" : productcode
|
|
|
|
|
- //insuredInfo.put("mark", "1");
|
|
|
|
|
- //insuredInfo.put("insuredname", quoteVo.getInsuredPersonInfo().getName());
|
|
|
|
|
- //insuredInfo.put("certitype", "01");
|
|
|
|
|
- //insuredInfo.put("certicode", quoteVo.getInsuredPersonInfo().getIdentifyNumber());
|
|
|
|
|
- //insuredInfo.put("age", quoteVo.getInsuredPersonInfo().getAge());
|
|
|
|
|
- //insuredInfo.put("gender", quoteVo.getInsuredPersonInfo().getGender());
|
|
|
|
|
- //insuredInfo.put("perProWithCarStartDate", "");
|
|
|
|
|
- //insuredInfo.put("perProWithCarEndDate", "");
|
|
|
|
|
- //insuredInfo.put("relation", quoteVo.getOwnersInfo().getName().equals(quoteVo.getInsuredPersonInfo().getIdentifyNumber()) ? "00" : "99");
|
|
|
|
|
- //insuredInfo.put("job", "");
|
|
|
|
|
- //insuredInfo.put("parentcode", "");
|
|
|
|
|
- //insuredInfo.put("parentname", "");
|
|
|
|
|
- //insuredInfo.put("parametercode", "");
|
|
|
|
|
- //insuredInfo.put("parametername", "");
|
|
|
|
|
- //insuredInfo.put("codecode", "");
|
|
|
|
|
- //insuredInfo.put("codecname", "");
|
|
|
|
|
- //insuredInfo.put("risktype", "");
|
|
|
|
|
- //insuredInfo.put("jobtype", "");
|
|
|
|
|
- //insuredInfo.put("customerno", "");
|
|
|
|
|
- //insuredInfo.put("workname", "");
|
|
|
|
|
- //insuredInfo.put("workphone", "");
|
|
|
|
|
- //insuredInfo.put("yearmoney", "");
|
|
|
|
|
- //insuredInfo.put("workaddress", "");
|
|
|
|
|
- //insuredInfo.put("otherphone", "");
|
|
|
|
|
- //insuredInfo.put("otheraddress", "");
|
|
|
|
|
- //insuredInfo.put("mobile", "");
|
|
|
|
|
- //insuredInfo.put("urgentname", "");
|
|
|
|
|
- //insuredInfo.put("urgentmobile", "");
|
|
|
|
|
- //insuredInfo.put("nationality", "CHN");
|
|
|
|
|
-//
|
|
|
|
|
- //perinsuredList.add(insuredInfo);
|
|
|
|
|
- //Map<String, Object> accidentalDriving = new HashMap<>();
|
|
|
|
|
- //accidentalDriving.put("perinsuredList", perinsuredList);
|
|
|
|
|
- //accidentalDriving.put("car_limitloadperson", quoteVo.getCarInfoVo().getSeatCount());
|
|
|
|
|
- //accidentalDriving.put("startdate", quoteVo.getCiRiskInfoVo().getStartDate());
|
|
|
|
|
- //accidentalDriving.put("enddate", quoteVo.getCiRiskInfoVo().getEndDate());
|
|
|
|
|
- //personalInsuredJSON.add(accidentalDriving);
|
|
|
|
|
-//
|
|
|
|
|
- //String personalInsuredJSONStr = JSONObject.toJSONString(personalInsuredJSON);
|
|
|
|
|
- //fcData.add("personalInsuredJSON", personalInsuredJSONStr);
|
|
|
|
|
- //fcData.add("noCarProductMes", "");
|
|
|
|
|
- //fcData.add("quotationNo", quotationNo);
|
|
|
|
|
- //fcData.add("comCode", attributionInformationVo.getConfigInfo().get("comCode").toString());
|
|
|
|
|
- //fcData.add("handToCount43T3_903", "");
|
|
|
|
|
- //fcData.add("isCheckFlag", "1");
|
|
|
|
|
-//
|
|
|
|
|
- //HttpEntity<MultiValueMap<String, String>> fcRequestEntity = new HttpEntity<>(fcData, fcHeaders);
|
|
|
|
|
-//
|
|
|
|
|
- //ResponseEntity<String> fcResponse = getRestTemplate().postForEntity(
|
|
|
|
|
- // "https://cspxp.pc.ehuatai.com/htcsp/QuotedPriceAction.do?cmd=getNoCarPreimum",
|
|
|
|
|
- // fcRequestEntity,
|
|
|
|
|
- // String.class
|
|
|
|
|
- //);
|
|
|
|
|
-//
|
|
|
|
|
- //JSONObject fcResponseJson = JSONObject.parseObject(fcResponse.getBody());
|
|
|
|
|
- //System.out.println("fcResponseJson"+JSONObject.toJSONString(fcResponseJson));
|
|
|
|
|
- //fcPrice = fcResponseJson.getString("premium");
|
|
|
|
|
-//
|
|
|
|
|
- //if (fcPrice == null || fcPrice.isEmpty()) {
|
|
|
|
|
- // String fcMessage = fcResponseJson.getString("errormes");
|
|
|
|
|
- // System.out.println("非车险保费获取失败: " + fcMessage);
|
|
|
|
|
- //}
|
|
|
|
|
|
|
+ if (quoteVo.getAccidentalDrivings() != null && quoteVo.getAccidentalDrivings().size() > 0) {
|
|
|
|
|
+
|
|
|
|
|
+ HttpHeaders fcHeaders = new HttpHeaders();
|
|
|
|
|
+ fcHeaders.add(HtRequestConstant.COOKIE, cookie);
|
|
|
|
|
+ fcHeaders.add("Accept", "*/*");
|
|
|
|
|
+ fcHeaders.add("Accept-Language", "zh-CN,zh;q=0.9");
|
|
|
|
|
+ fcHeaders.add("Connection", "keep-alive");
|
|
|
|
|
+ fcHeaders.add("Content-Type", "application/x-www-form-urlencoded; charset=UTF-8");
|
|
|
|
|
+ fcHeaders.add("Origin", "https://cspxp.pc.ehuatai.com");
|
|
|
|
|
+ fcHeaders.add("Referer", "https://cspxp.pc.ehuatai.com/htcsp/VehicleInfoEntryAction.do?cmd=saveOneStept");
|
|
|
|
|
+ fcHeaders.add("User-Agent", "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/138.0.0.0 Safari/537.36");
|
|
|
|
|
+ fcHeaders.add("X-Requested-With", "XMLHttpRequest");
|
|
|
|
|
+
|
|
|
|
|
+ MultiValueMap<String, String> fcData = new LinkedMultiValueMap<>();
|
|
|
|
|
+ fcData.add("noCarProductMes", personalInsuredJSONString);
|
|
|
|
|
+ fcData.add("quotationNo", quotationNo);
|
|
|
|
|
+ fcData.add("comCode", attributionInformationVo.getConfigInfo().get("comCode").toString());
|
|
|
|
|
+ fcData.add("handToCount43T3_903", "");
|
|
|
|
|
+ fcData.add("isCheckFlag", "1");
|
|
|
|
|
+
|
|
|
|
|
+ HttpEntity<MultiValueMap<String, String>> fcRequestEntity = new HttpEntity<>(fcData, fcHeaders);
|
|
|
|
|
+
|
|
|
|
|
+ ResponseEntity<String> fcResponse = getRestTemplate().postForEntity(
|
|
|
|
|
+ "https://cspxp.pc.ehuatai.com/htcsp/QuotedPriceAction.do?cmd=getNoCarPreimum",
|
|
|
|
|
+ fcRequestEntity,
|
|
|
|
|
+ String.class
|
|
|
|
|
+ );
|
|
|
|
|
+ System.out.println("fcResponse.getBody()::" + fcResponse.getBody());
|
|
|
|
|
+ Map<String, Object> res = objectMapper.readValue(fcResponse.getBody(), HashMap.class);
|
|
|
|
|
+
|
|
|
|
|
+ fcPrice = res.get("premium") == null ? "" : res.get("premium").toString();
|
|
|
|
|
+ }
|
|
|
} else {
|
|
} else {
|
|
|
retryCount++;
|
|
retryCount++;
|
|
|
System.out.println("quoteResponseData.getApplicationdto() 为 null,第 " + retryCount + " 次重试...");
|
|
System.out.println("quoteResponseData.getApplicationdto() 为 null,第 " + retryCount + " 次重试...");
|
|
@@ -694,7 +735,7 @@ public class HuaTaiCrawlerRequestImpl implements HuaTaiCrawlerRequest {
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@NotNull
|
|
@NotNull
|
|
|
- private HtCrawlerQuoteResponse.DataDTO getDataDTO(QuoteVo quoteVo, String decryptData, String mealid, HttpHeaders headers2) throws Exception {
|
|
|
|
|
|
|
+ private HtCrawlerQuoteResponse.DataDTO getDataDTO(QuoteVo quoteVo, String decryptData, String mealid, HttpHeaders headers2, String basePartJSON, String personalInsuredJSONString) throws Exception {
|
|
|
HtCrawlerQuoteResponse.DataDTO quoteResponseData;
|
|
HtCrawlerQuoteResponse.DataDTO quoteResponseData;
|
|
|
HtCrawlerQuoteRequest htCrawlerQuoteRequest;
|
|
HtCrawlerQuoteRequest htCrawlerQuoteRequest;
|
|
|
quoteResponseData = JSONObject.parseObject(decryptData, HtCrawlerQuoteResponse.DataDTO.class);
|
|
quoteResponseData = JSONObject.parseObject(decryptData, HtCrawlerQuoteResponse.DataDTO.class);
|
|
@@ -706,7 +747,7 @@ public class HuaTaiCrawlerRequestImpl implements HuaTaiCrawlerRequest {
|
|
|
String riskfalg = "0".equals(querrysequenceno.substring(0, 1)) ? "0" : "1";//.equals(querrysequenceno) ? "0" : "1"
|
|
String riskfalg = "0".equals(querrysequenceno.substring(0, 1)) ? "0" : "1";//.equals(querrysequenceno) ? "0" : "1"
|
|
|
|
|
|
|
|
basePartJSON = "[{'riskfalg':'"+riskfalg+"','checktype':2,'querysequenceno':'"+querrysequenceno+"','checkcode':'"+autocheckcode+"','answer':''}]";
|
|
basePartJSON = "[{'riskfalg':'"+riskfalg+"','checktype':2,'querysequenceno':'"+querrysequenceno+"','checkcode':'"+autocheckcode+"','answer':''}]";
|
|
|
- htCrawlerQuoteRequest = new HtCrawlerQuoteRequest(quoteVo, mealid, basePartJSON);
|
|
|
|
|
|
|
+ htCrawlerQuoteRequest = new HtCrawlerQuoteRequest(quoteVo, mealid, basePartJSON, personalInsuredJSONString);
|
|
|
decryptData = htCrawlerRequestComponent.quote(htCrawlerQuoteRequest, headers2);
|
|
decryptData = htCrawlerRequestComponent.quote(htCrawlerQuoteRequest, headers2);
|
|
|
System.out.println("quoteResponseData:1:"+JSONObject.toJSONString(decryptData));
|
|
System.out.println("quoteResponseData:1:"+JSONObject.toJSONString(decryptData));
|
|
|
quoteResponseData = JSONObject.parseObject(decryptData, HtCrawlerQuoteResponse.DataDTO.class);
|
|
quoteResponseData = JSONObject.parseObject(decryptData, HtCrawlerQuoteResponse.DataDTO.class);
|
|
@@ -722,9 +763,9 @@ public class HuaTaiCrawlerRequestImpl implements HuaTaiCrawlerRequest {
|
|
|
HtCrawlerQuoteResponse.DataDTO.BasePartDTOListDTO.BasePartDTO basePartDTO1 = quoteResponseData.getBasepartdtolist().getBasepartdto().get(1);
|
|
HtCrawlerQuoteResponse.DataDTO.BasePartDTOListDTO.BasePartDTO basePartDTO1 = quoteResponseData.getBasepartdtolist().getBasepartdto().get(1);
|
|
|
String querrysequenceno1 = basePartDTO1.getQuerrysequenceno();
|
|
String querrysequenceno1 = basePartDTO1.getQuerrysequenceno();
|
|
|
String autocheckcode1 = basePartDTO1.getAutocheckcode();
|
|
String autocheckcode1 = basePartDTO1.getAutocheckcode();
|
|
|
- String basePartJSON = "[{'riskfalg':'0','checktype':2,'querysequenceno':'"+querrysequenceno1+"','checkcode':'"+autocheckcode1+"','answer':''}," +
|
|
|
|
|
|
|
+ basePartJSON = "[{'riskfalg':'0','checktype':2,'querysequenceno':'"+querrysequenceno1+"','checkcode':'"+autocheckcode1+"','answer':''}," +
|
|
|
"{'riskfalg':'1','checktype':2,'querysequenceno':'"+querrysequenceno+"','checkcode':'"+autocheckcode+"','answer':''}]";
|
|
"{'riskfalg':'1','checktype':2,'querysequenceno':'"+querrysequenceno+"','checkcode':'"+autocheckcode+"','answer':''}]";
|
|
|
- htCrawlerQuoteRequest = new HtCrawlerQuoteRequest(quoteVo, mealid, basePartJSON);
|
|
|
|
|
|
|
+ htCrawlerQuoteRequest = new HtCrawlerQuoteRequest(quoteVo, mealid, basePartJSON, personalInsuredJSONString);
|
|
|
decryptData = htCrawlerRequestComponent.quote(htCrawlerQuoteRequest, headers2);
|
|
decryptData = htCrawlerRequestComponent.quote(htCrawlerQuoteRequest, headers2);
|
|
|
System.out.println("quoteResponseData:2:"+JSONObject.toJSONString(decryptData));
|
|
System.out.println("quoteResponseData:2:"+JSONObject.toJSONString(decryptData));
|
|
|
quoteResponseData = JSONObject.parseObject(decryptData, HtCrawlerQuoteResponse.DataDTO.class);
|
|
quoteResponseData = JSONObject.parseObject(decryptData, HtCrawlerQuoteResponse.DataDTO.class);
|
|
@@ -739,10 +780,10 @@ public class HuaTaiCrawlerRequestImpl implements HuaTaiCrawlerRequest {
|
|
|
HtCrawlerQuoteResponse.DataDTO.BasePartDTOListDTO.BasePartDTO basePartDTO2 = quoteResponseData.getBasepartdtolist().getBasepartdto().get(1);
|
|
HtCrawlerQuoteResponse.DataDTO.BasePartDTOListDTO.BasePartDTO basePartDTO2 = quoteResponseData.getBasepartdtolist().getBasepartdto().get(1);
|
|
|
String querrysequenceno2 = basePartDTO2.getQuerrysequenceno();
|
|
String querrysequenceno2 = basePartDTO2.getQuerrysequenceno();
|
|
|
String autocheckcode2 = basePartDTO2.getAutocheckcode();
|
|
String autocheckcode2 = basePartDTO2.getAutocheckcode();
|
|
|
- String basePartJSON = "[{'riskfalg':'0','checktype':2,'querysequenceno':'"+querrysequenceno1+"','checkcode':'"+autocheckcode1+"','answer':''}," +
|
|
|
|
|
|
|
+ basePartJSON = "[{'riskfalg':'0','checktype':2,'querysequenceno':'"+querrysequenceno1+"','checkcode':'"+autocheckcode1+"','answer':''}," +
|
|
|
"{'riskfalg':'1','checktype':2,'querysequenceno':'"+querrysequenceno+"','checkcode':'"+autocheckcode+"','answer':''}," +
|
|
"{'riskfalg':'1','checktype':2,'querysequenceno':'"+querrysequenceno+"','checkcode':'"+autocheckcode+"','answer':''}," +
|
|
|
"{'riskfalg':'2','checktype':2,'querysequenceno':'"+querrysequenceno2+"','checkcode':'"+autocheckcode2+"','answer':''}]";
|
|
"{'riskfalg':'2','checktype':2,'querysequenceno':'"+querrysequenceno2+"','checkcode':'"+autocheckcode2+"','answer':''}]";
|
|
|
- htCrawlerQuoteRequest = new HtCrawlerQuoteRequest(quoteVo, mealid, basePartJSON);
|
|
|
|
|
|
|
+ htCrawlerQuoteRequest = new HtCrawlerQuoteRequest(quoteVo, mealid, basePartJSON, personalInsuredJSONString);
|
|
|
decryptData = htCrawlerRequestComponent.quote(htCrawlerQuoteRequest, headers2);
|
|
decryptData = htCrawlerRequestComponent.quote(htCrawlerQuoteRequest, headers2);
|
|
|
System.out.println("quoteResponseData:3:"+JSONObject.toJSONString(decryptData));
|
|
System.out.println("quoteResponseData:3:"+JSONObject.toJSONString(decryptData));
|
|
|
quoteResponseData = JSONObject.parseObject(decryptData, HtCrawlerQuoteResponse.DataDTO.class);
|
|
quoteResponseData = JSONObject.parseObject(decryptData, HtCrawlerQuoteResponse.DataDTO.class);
|
|
@@ -1353,6 +1394,11 @@ public class HuaTaiCrawlerRequestImpl implements HuaTaiCrawlerRequest {
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
public static void main(String[] args) throws Exception {
|
|
public static void main(String[] args) throws Exception {
|
|
|
|
|
+
|
|
|
|
|
+ Map<String, Object> map = new HashMap<>();
|
|
|
|
|
+ map.put("accessToken", "fhEhAev4XHQyX7jQddYAURPArSOq5RSaE/nNtCu7mXC+APlSBeIzPHX3TJJULnROwnHkUhYy/M1PsXldVq0ZhMPs9pCB3Um1V3xcjVacYMer6k59s3I/np35FCAg7p/f6V0GPTX2kA0ZW0qZGE0xbiJtlxSwJ4ORNC0E/o0K6dY=");
|
|
|
|
|
+ map.put("data", "OqQ0kxg3UWV18BXBVcNrAsdB2CCMMO39VgAq7YQGnLpb9A9Gppj9GxjG4c9VNdX5M9zRYYWWscj5KYWEIWWkeAkzkt8oWkmI/VYuMikExadzN1IpMrdIKIkhJRd4R7UD");
|
|
|
|
|
+ decrypt(map);
|
|
|
// String token="Wr6ZGWsDqfdccgGXUBkCzMgySSw/ORJj6ZJfBqhEmmz6ku//ZQaYpUDN6/95kOYFolfIGogncftA/k4PeRKtMe5RvifZgesN6HZFm4tZNssod/XQR4lESSSeJN67i3kTda2BYkMJDVCbNMp3nUkuYoxtqthkWKoBaA1wk5fYkdk=";
|
|
// String token="Wr6ZGWsDqfdccgGXUBkCzMgySSw/ORJj6ZJfBqhEmmz6ku//ZQaYpUDN6/95kOYFolfIGogncftA/k4PeRKtMe5RvifZgesN6HZFm4tZNssod/XQR4lESSSeJN67i3kTda2BYkMJDVCbNMp3nUkuYoxtqthkWKoBaA1wk5fYkdk=";
|
|
|
// String data="vdWlTgo4OLFgkDJoTjBy3nMWXugJwXB/QA777snMrLMy9ruEqWXYCwDq0HBizp/dbnrU8A2whRpJLXhDrkcS1omgdDUPnhu7EoI06wV267Dtw9bJc1JUky6O5DdRRGioq5isZeXjQbFr2YhbIaxa33G30JdgH365wL963lSSr97WMFRij7elYm9HxGrnqjJ3LBcQxlsOj9Xdi+wHSEZuH/C7xO8qOVWWLaAS78uPjbyfmsfl3dXsAGTldxQ1dl8q6BKTr38qfRQdAcoKFNsEid8Gt01nzG3NmwvfAL0xQu7mzbqpdywla6JFGmtxrdmF2ImfNBvRp7cAf4g7A1UhJDOYNZO2dNC6Irhn2sDM5vRYEfvcG03O1+Zaq6AxSazAI/whs772/IUsKiYlsAt/DE02afl6K7pZBXloAEmIoj9/CWAyOfFNBSnyEPFd3Qf9O9eFFiy+B2snJ7e4izaBDadMsB9ByglraMvyzhcPL3fmmFdfv8wM66gv6Ch8nARXU7GlKNiM35aP+627QPc5UMy7HkIB89/TTqamMMJgqgU=";
|
|
// String data="vdWlTgo4OLFgkDJoTjBy3nMWXugJwXB/QA777snMrLMy9ruEqWXYCwDq0HBizp/dbnrU8A2whRpJLXhDrkcS1omgdDUPnhu7EoI06wV267Dtw9bJc1JUky6O5DdRRGioq5isZeXjQbFr2YhbIaxa33G30JdgH365wL963lSSr97WMFRij7elYm9HxGrnqjJ3LBcQxlsOj9Xdi+wHSEZuH/C7xO8qOVWWLaAS78uPjbyfmsfl3dXsAGTldxQ1dl8q6BKTr38qfRQdAcoKFNsEid8Gt01nzG3NmwvfAL0xQu7mzbqpdywla6JFGmtxrdmF2ImfNBvRp7cAf4g7A1UhJDOYNZO2dNC6Irhn2sDM5vRYEfvcG03O1+Zaq6AxSazAI/whs772/IUsKiYlsAt/DE02afl6K7pZBXloAEmIoj9/CWAyOfFNBSnyEPFd3Qf9O9eFFiy+B2snJ7e4izaBDadMsB9ByglraMvyzhcPL3fmmFdfv8wM66gv6Ch8nARXU7GlKNiM35aP+627QPc5UMy7HkIB89/TTqamMMJgqgU=";
|
|
|
|
|
|
|
@@ -1437,7 +1483,7 @@ public class HuaTaiCrawlerRequestImpl implements HuaTaiCrawlerRequest {
|
|
|
return makeInputData;
|
|
return makeInputData;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- public Map<String, Object> decrypt(Map<String, Object> x) throws Exception {
|
|
|
|
|
|
|
+ public static Map<String, Object> decrypt(Map<String, Object> x) throws Exception {
|
|
|
String accessToken = (String) x.get("accessToken");
|
|
String accessToken = (String) x.get("accessToken");
|
|
|
String data = (String) x.get("data");
|
|
String data = (String) x.get("data");
|
|
|
String aesKey = CryptoUtil.rsaDecrypt(accessToken);
|
|
String aesKey = CryptoUtil.rsaDecrypt(accessToken);
|