|
|
@@ -121,10 +121,7 @@ public class ChengTaiOrderApiServiceImpl implements ChengTaiOrderApiService {
|
|
|
QueryCarActualValueResponse carActualValueResponse = chengTaiRequestApiComponents.queryActualValue(carActualValueRequest,httpHeaders);
|
|
|
|
|
|
/** 4. 报价 */
|
|
|
- PersonAreaVo personAreaVo = new PersonAreaVo();
|
|
|
- buildRegion(quoteInfoVo,personAreaVo);
|
|
|
- InsurePremiumRequest insurePremiumRequest = new InsurePremiumRequest(quoteInfoVo,carModelListDTO, carActualValueResponse,personAreaVo,parameters,quoteVo);
|
|
|
-
|
|
|
+ InsurePremiumRequest insurePremiumRequest = new InsurePremiumRequest(quoteInfoVo,carModelListDTO, carActualValueResponse,parameters,quoteVo);
|
|
|
// 重复报价
|
|
|
InsurePremiumResponse insurePremiumResponse = this.getResponse(insurePremiumRequest, httpHeaders);
|
|
|
|
|
|
@@ -490,62 +487,75 @@ public class ChengTaiOrderApiServiceImpl implements ChengTaiOrderApiService {
|
|
|
return quoteRespVo;
|
|
|
}
|
|
|
|
|
|
- /**
|
|
|
- * 获取地区编码
|
|
|
- * @param quoteInfoVo
|
|
|
- * @param personAreaVo
|
|
|
- */
|
|
|
- private void buildRegion(BaseQuoteInfoVo quoteInfoVo, PersonAreaVo personAreaVo) {
|
|
|
-
|
|
|
- //车主
|
|
|
- CustomerInfoVo owner = quoteInfoVo.getOwnerInfo();
|
|
|
- //被保人
|
|
|
- CustomerInfoVo insured = quoteInfoVo.getInsuredPersonInfo();
|
|
|
- //投保人
|
|
|
- CustomerInfoVo applicant = quoteInfoVo.getPolicyHolderInfo();
|
|
|
-
|
|
|
- //车主地区信息
|
|
|
- PersonAreaVo ownerPersonAreaVo = sysAreaService.queryByAddressYc(owner.getAddr(), owner.getIdentifyNumber());
|
|
|
- PersonAreaVo insuredPersonAreaVo;
|
|
|
- PersonAreaVo applicantPersonAreaVo;
|
|
|
-
|
|
|
- //车主是否与投保人相同
|
|
|
- if (owner.getIdentifyNumber().equals(insured.getIdentifyNumber())) {
|
|
|
- insuredPersonAreaVo = ownerPersonAreaVo;
|
|
|
- } else {
|
|
|
- //投保人地区信息
|
|
|
- insuredPersonAreaVo = sysAreaService.queryByAddressYc(insured.getAddr(), insured.getIdentifyNumber());
|
|
|
- }
|
|
|
-
|
|
|
- //车主是否与被保人相同
|
|
|
- if (owner.getIdentifyNumber().equals(applicant.getIdentifyNumber())) {
|
|
|
- applicantPersonAreaVo = ownerPersonAreaVo;
|
|
|
- } else { //投保人是否与被保人相同
|
|
|
- if (insured.getIdentifyNumber().equals(applicant.getIdentifyNumber())) {
|
|
|
- applicantPersonAreaVo = insuredPersonAreaVo;
|
|
|
- } else {
|
|
|
- applicantPersonAreaVo = sysAreaService.queryByAddressYc(applicant.getAddr(), applicant.getIdentifyNumber());
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- if (!Objects.isNull(ownerPersonAreaVo)) {
|
|
|
- personAreaVo.setProvinceCode(ownerPersonAreaVo.getProvinceCode());
|
|
|
- personAreaVo.setCityCode(ownerPersonAreaVo.getCityCode());
|
|
|
- personAreaVo.setCountyCode(ownerPersonAreaVo.getCountyCode());
|
|
|
- }
|
|
|
-
|
|
|
- if (!Objects.isNull(insuredPersonAreaVo)) {
|
|
|
- personAreaVo.setProvinceCode(insuredPersonAreaVo.getProvinceCode());
|
|
|
- personAreaVo.setCityCode(insuredPersonAreaVo.getCityCode());
|
|
|
- personAreaVo.setCountyCode(insuredPersonAreaVo.getCountyCode());
|
|
|
- }
|
|
|
-
|
|
|
- if (!Objects.isNull(applicantPersonAreaVo)) {
|
|
|
- personAreaVo.setProvinceCode(applicantPersonAreaVo.getProvinceCode());
|
|
|
- personAreaVo.setCityCode(applicantPersonAreaVo.getCityCode());
|
|
|
- personAreaVo.setCountyCode(applicantPersonAreaVo.getCountyCode());
|
|
|
- }
|
|
|
- }
|
|
|
+// /**
|
|
|
+// * 获取地区编码
|
|
|
+// * @param quoteInfoVo
|
|
|
+// * @param personAreaVo
|
|
|
+// */
|
|
|
+// private void buildRegion(BaseQuoteInfoVo quoteInfoVo, PersonAreaVo personAreaVo) {
|
|
|
+//
|
|
|
+// //车主
|
|
|
+// CustomerInfoVo owner = quoteInfoVo.getOwnerInfo();
|
|
|
+// //被保人
|
|
|
+// CustomerInfoVo insured = quoteInfoVo.getInsuredPersonInfo();
|
|
|
+// //投保人
|
|
|
+// CustomerInfoVo applicant = quoteInfoVo.getPolicyHolderInfo();
|
|
|
+//
|
|
|
+// //车主地区信息
|
|
|
+// PersonAreaVo ownerPersonAreaVo;
|
|
|
+// if("0".equals(owner.getProperty())){
|
|
|
+// ownerPersonAreaVo = sysAreaService.queryByAddressYc(owner.getAddr(), owner.getIdentifyNumber());
|
|
|
+// }else {
|
|
|
+// ownerPersonAreaVo = new PersonAreaVo(owner);
|
|
|
+// }
|
|
|
+// PersonAreaVo insuredPersonAreaVo;
|
|
|
+// PersonAreaVo applicantPersonAreaVo;
|
|
|
+//
|
|
|
+// //车主是否与投保人相同
|
|
|
+// if (owner.getIdentifyNumber().equals(insured.getIdentifyNumber())) {
|
|
|
+// insuredPersonAreaVo = ownerPersonAreaVo;
|
|
|
+// } else {
|
|
|
+// if("0".equals(owner.getProperty())){
|
|
|
+// //投保人地区信息
|
|
|
+// insuredPersonAreaVo = sysAreaService.queryByAddressYc(insured.getAddr(), insured.getIdentifyNumber());
|
|
|
+// }else{
|
|
|
+// insuredPersonAreaVo = new PersonAreaVo(insured);
|
|
|
+// }
|
|
|
+// }
|
|
|
+//
|
|
|
+// //车主是否与被保人相同
|
|
|
+// if (owner.getIdentifyNumber().equals(applicant.getIdentifyNumber())) {
|
|
|
+// applicantPersonAreaVo = ownerPersonAreaVo;
|
|
|
+// } else { //投保人是否与被保人相同
|
|
|
+// if (insured.getIdentifyNumber().equals(applicant.getIdentifyNumber())) {
|
|
|
+// applicantPersonAreaVo = insuredPersonAreaVo;
|
|
|
+// } else {
|
|
|
+// if("0".equals(owner.getProperty())){
|
|
|
+// applicantPersonAreaVo = sysAreaService.queryByAddressYc(applicant.getAddr(), applicant.getIdentifyNumber());
|
|
|
+// }else{
|
|
|
+// applicantPersonAreaVo = new PersonAreaVo(applicant);
|
|
|
+// }
|
|
|
+// }
|
|
|
+// }
|
|
|
+//
|
|
|
+// if (!Objects.isNull(ownerPersonAreaVo)) {
|
|
|
+// personAreaVo.setProvinceCode(ownerPersonAreaVo.getProvinceCode());
|
|
|
+// personAreaVo.setCityCode(ownerPersonAreaVo.getCityCode());
|
|
|
+// personAreaVo.setCountyCode(ownerPersonAreaVo.getCountyCode());
|
|
|
+// }
|
|
|
+//
|
|
|
+// if (!Objects.isNull(insuredPersonAreaVo)) {
|
|
|
+// personAreaVo.setProvinceCode(insuredPersonAreaVo.getProvinceCode());
|
|
|
+// personAreaVo.setCityCode(insuredPersonAreaVo.getCityCode());
|
|
|
+// personAreaVo.setCountyCode(insuredPersonAreaVo.getCountyCode());
|
|
|
+// }
|
|
|
+//
|
|
|
+// if (!Objects.isNull(applicantPersonAreaVo)) {
|
|
|
+// personAreaVo.setProvinceCode(applicantPersonAreaVo.getProvinceCode());
|
|
|
+// personAreaVo.setCityCode(applicantPersonAreaVo.getCityCode());
|
|
|
+// personAreaVo.setCountyCode(applicantPersonAreaVo.getCountyCode());
|
|
|
+// }
|
|
|
+// }
|
|
|
|
|
|
@Override
|
|
|
public HttpResult<Object> submitImages(String companyId) throws Exception {
|
|
|
@@ -602,10 +612,22 @@ public class ChengTaiOrderApiServiceImpl implements ChengTaiOrderApiService {
|
|
|
ptlAgreementAttribution);
|
|
|
HttpHeaders httpHeaders = chengTaiRequestApiComponents.getHttpHeaders(parameters,ChengTaiRequestApiComponents.RECURSIVE_HIERARCHY);
|
|
|
// 2 提交核保
|
|
|
- JSONObject applyInfo = insOrders.getApplyinfo();
|
|
|
- JSONObject insureinfo = insOrders.getInsureinfo();
|
|
|
- PersonAreaVo applyPersonAreaVo = sysAreaService.queryByAddressYc(applyInfo.getString("addr"), applyInfo.getString("identifyNumber"));
|
|
|
- PersonAreaVo insurePersonAreaVo = sysAreaService.queryByAddressYc(insureinfo.getString("addr"), insureinfo.getString("identifyNumber"));
|
|
|
+ CustomerInfoVo applyInfo = JSON.toJavaObject(insOrders.getApplyinfo(),CustomerInfoVo.class);
|
|
|
+ CustomerInfoVo insureInfo = JSON.toJavaObject(insOrders.getInsureinfo(),CustomerInfoVo.class);
|
|
|
+ String applyProperty = applyInfo.getProperty();
|
|
|
+ String insureProperty = insureInfo.getProperty();
|
|
|
+ PersonAreaVo applyPersonAreaVo;
|
|
|
+ PersonAreaVo insurePersonAreaVo;
|
|
|
+ if ("0".equals(applyProperty)) {
|
|
|
+ applyPersonAreaVo = new PersonAreaVo(applyInfo);
|
|
|
+ }else{
|
|
|
+ applyPersonAreaVo = sysAreaService.queryByAddressYc(applyInfo.getAddr(), applyInfo.getIdentifyNumber());
|
|
|
+ }
|
|
|
+ if ("0".equals(insureProperty)) {
|
|
|
+ insurePersonAreaVo = new PersonAreaVo(insureInfo);
|
|
|
+ }else{
|
|
|
+ insurePersonAreaVo = sysAreaService.queryByAddressYc(insureInfo.getAddr(), insureInfo.getIdentifyNumber());
|
|
|
+ }
|
|
|
|
|
|
List<SubmitVerifyRequest.EngageListDTO> engageDTO = new ArrayList<>();
|
|
|
// 获取特约
|