|
|
@@ -3,7 +3,6 @@ package com.ydtech.modules.order.service.impl;
|
|
|
import cn.hutool.core.util.ArrayUtil;
|
|
|
import com.alibaba.fastjson.JSON;
|
|
|
import com.alibaba.fastjson.JSONObject;
|
|
|
-import com.ydtech.components.ZhongmeiRequestApiComponents;
|
|
|
import com.ydtech.components.ZhongmeiRequestComponents;
|
|
|
import com.ydtech.constants.enums.InsOrderStatus;
|
|
|
import com.ydtech.core.page.HttpResult;
|
|
|
@@ -14,16 +13,20 @@ import com.ydtech.modules.ins.model.request.Response;
|
|
|
import com.ydtech.modules.ins.model.vo.*;
|
|
|
import com.ydtech.modules.ins.model.ya.CarModelDTO;
|
|
|
import com.ydtech.modules.ins.model.zm.ZmCarModel;
|
|
|
+import com.ydtech.modules.order.components.ConfigureParametersComponents;
|
|
|
+import com.ydtech.modules.order.components.ZhongmeiRequestApiComponents;
|
|
|
import com.ydtech.modules.order.convert.SimpleStadarCarDTOConvert;
|
|
|
import com.ydtech.modules.order.entity.InsAreaCompany;
|
|
|
import com.ydtech.modules.order.entity.InsOrders;
|
|
|
import com.ydtech.modules.order.entity.TaxArrears;
|
|
|
+import com.ydtech.modules.order.entity.api.zm.BaseRequestHead;
|
|
|
import com.ydtech.modules.order.entity.api.zm.constants.InsuranceTypeCorrespondence;
|
|
|
import com.ydtech.modules.order.entity.api.zm.constants.enums.AuditStatusEnum;
|
|
|
import com.ydtech.modules.order.entity.api.zm.constants.enums.DocumentTypeEnum;
|
|
|
import com.ydtech.modules.order.entity.api.zm.constants.enums.PaymentStatusEnum;
|
|
|
import com.ydtech.modules.order.entity.api.zm.request.*;
|
|
|
import com.ydtech.modules.order.entity.api.zm.response.*;
|
|
|
+import com.ydtech.modules.order.entity.config.ZmConfigureParameters;
|
|
|
import com.ydtech.modules.order.entity.po.InsTaskImagesBase64;
|
|
|
import com.ydtech.modules.order.entity.vo.AccidentalDrivingVo;
|
|
|
import com.ydtech.modules.order.entity.vo.BaseQuoteInfoVo;
|
|
|
@@ -33,6 +36,8 @@ import com.ydtech.modules.order.service.InsAreaCompanyService;
|
|
|
import com.ydtech.modules.order.service.InsOrdersService;
|
|
|
import com.ydtech.modules.order.service.InsTaskImagesService;
|
|
|
import com.ydtech.modules.order.service.ZhongMeiOrderApiService;
|
|
|
+import com.ydtech.modules.protocol.entity.po.PtlAgreementAttribution;
|
|
|
+import com.ydtech.modules.protocol.service.PtlAgreementAttributionService;
|
|
|
import com.ydtech.utils.CalculateUtils;
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
|
@@ -67,8 +72,11 @@ public class ZhongMeiOrderApiServiceImpl implements ZhongMeiOrderApiService {
|
|
|
|
|
|
private final StringRedisTemplate redisTemplate;
|
|
|
|
|
|
+ private final PtlAgreementAttributionService ptlAgreementAttributionService;
|
|
|
|
|
|
- public ZhongMeiOrderApiServiceImpl(InsOrdersService insOrdersService, InsAreaCompanyService insAreaCompanyService, InsTaskImagesService insTaskImagesService, ZhongmeiRequestApiComponents zhongmeiRequestApiComponents, EsmInsCompanyService esmInsCompanyService, ZhongmeiRequestComponents zhongmeiRequestComponents, StringRedisTemplate redisTemplate) {
|
|
|
+ private final ConfigureParametersComponents configureParametersComponents;
|
|
|
+
|
|
|
+ public ZhongMeiOrderApiServiceImpl(InsOrdersService insOrdersService, InsAreaCompanyService insAreaCompanyService, InsTaskImagesService insTaskImagesService, ZhongmeiRequestApiComponents zhongmeiRequestApiComponents, EsmInsCompanyService esmInsCompanyService, ZhongmeiRequestComponents zhongmeiRequestComponents, StringRedisTemplate redisTemplate, ConfigureParametersComponents configureParametersComponents, PtlAgreementAttributionService ptlAgreementAttributionService) {
|
|
|
this.insOrdersService = insOrdersService;
|
|
|
this.insAreaCompanyService = insAreaCompanyService;
|
|
|
this.insTaskImagesService = insTaskImagesService;
|
|
|
@@ -76,6 +84,9 @@ public class ZhongMeiOrderApiServiceImpl implements ZhongMeiOrderApiService {
|
|
|
this.esmInsCompanyService = esmInsCompanyService;
|
|
|
this.zhongmeiRequestComponents = zhongmeiRequestComponents;
|
|
|
this.redisTemplate = redisTemplate;
|
|
|
+
|
|
|
+ this.configureParametersComponents = configureParametersComponents;
|
|
|
+ this.ptlAgreementAttributionService = ptlAgreementAttributionService;
|
|
|
}
|
|
|
|
|
|
private void modelInquiry(String modelName, List<ModelsQueryResponse.SimpleStadarCarDTO> simpleStadarCarDTOS) {
|
|
|
@@ -102,7 +113,8 @@ public class ZhongMeiOrderApiServiceImpl implements ZhongMeiOrderApiService {
|
|
|
public HttpResult<List<CarModelDTO>> modelsQuery(String modelName) {
|
|
|
ModelsQueryRequest modelsQueryResponse = new ModelsQueryRequest();
|
|
|
modelsQueryResponse.setModelName(modelName);
|
|
|
- List<ModelsQueryResponse.SimpleStadarCarDTO> car = zhongmeiRequestApiComponents.modelQuery(modelsQueryResponse, ModelsQueryResponse.class);
|
|
|
+// List<ModelsQueryResponse.SimpleStadarCarDTO> car = zhongmeiRequestApiComponents.modelQuery(modelsQueryResponse, ModelsQueryResponse.class);
|
|
|
+ List<ModelsQueryResponse.SimpleStadarCarDTO> car = new ArrayList<>();
|
|
|
modelInquiry(modelName, car);
|
|
|
|
|
|
List<CarModelDTO> map = SimpleStadarCarDTOConvert.INSTANCE.map(car);
|
|
|
@@ -111,17 +123,27 @@ public class ZhongMeiOrderApiServiceImpl implements ZhongMeiOrderApiService {
|
|
|
|
|
|
@Override
|
|
|
public HttpResult<QuoteRespVo> quote(BaseQuoteInfoVo quoteInfo, BaseQuoteVo<AccidentalDrivingVo> zmQuoteVo) {
|
|
|
- EsmInsCompany esmInsCompany = esmInsCompanyService.isOpen(zmQuoteVo.getCompanyId());
|
|
|
+ // 1. 协议id获取配置实体
|
|
|
+ String agreementId = zmQuoteVo.getAgreementId();
|
|
|
+ // 账号信息
|
|
|
+ PtlAgreementAttribution ptlAgreementAttribution = ptlAgreementAttributionService.getById(agreementId);
|
|
|
+
|
|
|
+ ZmConfigureParameters zmConfigureParameters = new ZmConfigureParameters();
|
|
|
+ configureParametersComponents.toEntity(zmConfigureParameters, agreementId);
|
|
|
+ BaseRequestHead baseRequestHead = new BaseRequestHead(zmConfigureParameters);
|
|
|
+ EsmInsCompany esmInsCompany = esmInsCompanyService.getById(zmQuoteVo.getCompanyId());
|
|
|
+
|
|
|
CarInfoVo carInfo = quoteInfo.getCarInfo();
|
|
|
- // 1. 查询车型
|
|
|
+ // 2. 查询车型
|
|
|
ModelsQueryRequest modelsQueryResponse = new ModelsQueryRequest();
|
|
|
modelsQueryResponse.setModelName(carInfo.getModelcname());
|
|
|
+ modelsQueryResponse.setHead(baseRequestHead);
|
|
|
List<ModelsQueryResponse.SimpleStadarCarDTO> simpleStadarCarDTOS = zhongmeiRequestApiComponents.modelQuery(modelsQueryResponse, ModelsQueryResponse.class);
|
|
|
|
|
|
- // 1.1 使用爬虫接口调用车型
|
|
|
+ // 2.1 使用爬虫接口调用车型
|
|
|
modelInquiry(carInfo.getModelcname(), simpleStadarCarDTOS);
|
|
|
|
|
|
- // 1.2 过滤车型
|
|
|
+ // 2.2 过滤车型
|
|
|
List<ModelsQueryResponse.SimpleStadarCarDTO> stadarCarDTOS = new ArrayList<>();
|
|
|
|
|
|
if (!StringUtils.isEmpty(carInfo.getCaryear())) {
|
|
|
@@ -136,56 +158,68 @@ public class ZhongMeiOrderApiServiceImpl implements ZhongMeiOrderApiService {
|
|
|
.filter(car -> carInfo.getPurchasePrice().equals(String.valueOf(car.getPurchasePrice())))
|
|
|
.collect(Collectors.toList());
|
|
|
|
|
|
+ if (simpleStadarCarDTOS.isEmpty()) {
|
|
|
+ simpleStadarCarDTOS = stadarCarDTOS;
|
|
|
+ }
|
|
|
+
|
|
|
ModelsQueryResponse.SimpleStadarCarDTO simpleStadarCarDTO = simpleStadarCarDTOS.get(0);
|
|
|
- // 组装参数
|
|
|
- QuotedPriceRequest quotedPriceRequest = new QuotedPriceRequest(quoteInfo, simpleStadarCarDTO, zmQuoteVo.getAccidentalDrivingVo());
|
|
|
- QuotedPriceResponse quotedPriceResponse = zhongmeiRequestApiComponents.quotedPrice(quotedPriceRequest, QuotedPriceResponse.class);
|
|
|
+ // 2.3 组装参数
|
|
|
+ QuotedPriceRequest quotedPriceRequest = new QuotedPriceRequest(quoteInfo, simpleStadarCarDTO, zmQuoteVo.getAccidentalDrivingVo(), zmConfigureParameters);
|
|
|
+ quotedPriceRequest.setHead(baseRequestHead);
|
|
|
|
|
|
+ QuotedPriceResponse quotedPriceResponse = zhongmeiRequestApiComponents.quotedPrice(quotedPriceRequest, QuotedPriceResponse.class);
|
|
|
QuoteRespVo quoteRespVo = getQuoteRespVo(quotedPriceResponse, quoteInfo);
|
|
|
- // 2. 第一次提交核保 并且获取投保单号
|
|
|
- SubmitResponse response = submitForUnderwriting(quotedPriceResponse.getOrderNo(), carInfo.getFrameNo(), quoteInfo.getPolicyHolderInfo());
|
|
|
+ // 3. 第一次提交核保 并且获取投保单号
|
|
|
+ SubmitResponse response = submitForUnderwriting(quotedPriceResponse.getOrderNo(), carInfo.getFrameNo(), quoteInfo.getPolicyHolderInfo(), zmConfigureParameters);
|
|
|
|
|
|
- // 3. 将错误的核保信息存入redis
|
|
|
+ // 4. 将错误的核保信息存入redis
|
|
|
if (StringUtils.isEmpty(response.getProposalNo())) {
|
|
|
redisTemplate.opsForValue().set(ZM_AUDIT_RETURN_MESSAGE + quoteRespVo.getCompanyId(), response.getHead().getReturnMessage(), ZM_AUDIT_RETURN_MESSAGE_TIME, TimeUnit.MINUTES);
|
|
|
}
|
|
|
- return responseOrder(quotedPriceResponse, quoteRespVo, esmInsCompany, response);
|
|
|
+ return responseOrder(quotedPriceResponse, quoteRespVo, esmInsCompany, response, agreementId, ptlAgreementAttribution.getApiType());
|
|
|
}
|
|
|
|
|
|
|
|
|
@Override
|
|
|
public HttpResult<Object> audit(String companyId) {
|
|
|
InsAreaCompany insAreaCompany = insAreaCompanyService.getByIdIsExist(companyId);
|
|
|
+ // 1. 协议id获取配置实体
|
|
|
+ ZmConfigureParameters zmConfigureParameters = new ZmConfigureParameters();
|
|
|
+ configureParametersComponents.toEntity(zmConfigureParameters, insAreaCompany.getAgreementId());
|
|
|
+
|
|
|
InsOrders insOrders = insOrdersService.getById(insAreaCompany.getOrderno());
|
|
|
JSONObject ownerinfo = insOrders.getApplyinfo();
|
|
|
CustomerInfoVo customerInfoVo = JSON.toJavaObject(ownerinfo, CustomerInfoVo.class);
|
|
|
- // 1. 第二次 提交核保
|
|
|
- SubmitResponse response = submitForUnderwriting(insAreaCompany.getId(), insOrders.getFrameno(), customerInfoVo);
|
|
|
- // 2. 人工核保
|
|
|
+ // 2. 第二次 提交核保
|
|
|
+ SubmitResponse response = submitForUnderwriting(insAreaCompany.getId(), insOrders.getFrameno(), customerInfoVo, zmConfigureParameters);
|
|
|
+ // 3. 人工核保
|
|
|
if (response.getHead().getReturnMessage().contains(InsuranceTypeCorrespondence.MANUAL_UNDERWRITING)) {
|
|
|
insAreaCompany.setOrderstatus(InsOrderStatus.S_1.getCode());
|
|
|
return HttpResult.error(response.getHead().getReturnMessage());
|
|
|
}
|
|
|
zhongmeiRequestApiComponents.validationResults(response);
|
|
|
- // 投保单号
|
|
|
+ // 4. 投保单号
|
|
|
insAreaCompany.setPaymentLink(response.getPayUrl());
|
|
|
insAreaCompany.setJqapplyno(response.getForceProposalNo());
|
|
|
insAreaCompany.setSyapplyno(response.getBizProposalNo());
|
|
|
insAreaCompany.setJyapplyno(response.getAccidentProposalNo());
|
|
|
insAreaCompany.setInsOrderNo(response.getProposalNo());
|
|
|
insAreaCompany.setOrderstatus(InsOrderStatus.S_2.getCode());
|
|
|
- insAreaCompanyService.updateById(insAreaCompany);
|
|
|
- insOrdersService.updateByOrderStatus(insAreaCompany.getOrderno(), insAreaCompany.getOrderstatus());
|
|
|
+ insAreaCompanyService.updateCompanyAndOrders(insAreaCompany);
|
|
|
return HttpResult.ok("核保成功");
|
|
|
}
|
|
|
|
|
|
@Override
|
|
|
public HttpResult<Object> submitImage(String companyId) {
|
|
|
InsAreaCompany insAreaCompany = insAreaCompanyService.getByIdIsExist(companyId);
|
|
|
+ // 1. 协议id获取配置实体
|
|
|
+ ZmConfigureParameters zmConfigureParameters = new ZmConfigureParameters();
|
|
|
+ configureParametersComponents.toEntity(zmConfigureParameters, insAreaCompany.getAgreementId());
|
|
|
+
|
|
|
InsOrders insOrders = insOrdersService.getById(insAreaCompany.getOrderno());
|
|
|
- // 投保单号(总)
|
|
|
+ // 2. 投保单号(总)
|
|
|
String insOrderNo = insAreaCompany.getInsOrderNo();
|
|
|
- // 没有投保单号
|
|
|
+ // 3. 没有投保单号
|
|
|
if (StringUtils.isEmpty(insOrderNo)) {
|
|
|
String s = redisTemplate.opsForValue().get(ZM_AUDIT_RETURN_MESSAGE + companyId);
|
|
|
if (StringUtils.isEmpty(s)) {
|
|
|
@@ -200,6 +234,7 @@ public class ZhongMeiOrderApiServiceImpl implements ZhongMeiOrderApiService {
|
|
|
throw new SystemException("请检查影像是否上传了");
|
|
|
}
|
|
|
UploadImageRequest request = new UploadImageRequest(insTaskImagesBase64s, insOrderNo);
|
|
|
+ request.setHead(new BaseRequestHead(zmConfigureParameters));
|
|
|
zhongmeiRequestApiComponents.uploadImage(request, UploadImageResponse.class);
|
|
|
return HttpResult.ok("上传文件成功");
|
|
|
}
|
|
|
@@ -218,8 +253,7 @@ public class ZhongMeiOrderApiServiceImpl implements ZhongMeiOrderApiService {
|
|
|
insAreaCompany.setSypolicyno(coverageRequest.getBizPolicyNo());
|
|
|
insAreaCompany.setJypolicyno(coverageRequest.getAccidentPolicyNo());
|
|
|
insAreaCompany.setOrderstatus(InsOrderStatus.S_3.getCode());
|
|
|
- insOrdersService.updateByOrderStatus(insAreaCompany.getOrderno(), insAreaCompany.getOrderstatus());
|
|
|
- insAreaCompanyService.updateById(insAreaCompany);
|
|
|
+ insAreaCompanyService.updateCompanyAndOrders(insAreaCompany);
|
|
|
}
|
|
|
return null;
|
|
|
}
|
|
|
@@ -240,31 +274,38 @@ public class ZhongMeiOrderApiServiceImpl implements ZhongMeiOrderApiService {
|
|
|
} else {
|
|
|
insAreaCompany.setOrderstatus(InsOrderStatus.S_4.getCode());
|
|
|
}
|
|
|
- insOrdersService.updateByOrderStatus(insAreaCompany.getOrderno(), insAreaCompany.getOrderstatus());
|
|
|
- insAreaCompanyService.updateById(insAreaCompany);
|
|
|
+ insAreaCompanyService.updateCompanyAndOrders(insAreaCompany);
|
|
|
return null;
|
|
|
}
|
|
|
|
|
|
@Override
|
|
|
public HttpResult paymentEnquiry(String companyId) {
|
|
|
InsAreaCompany insAreaCompany = insAreaCompanyService.getByInsOrderNo(companyId);
|
|
|
+
|
|
|
+ // 1. 协议id获取配置实体
|
|
|
+ ZmConfigureParameters zmConfigureParameters = new ZmConfigureParameters();
|
|
|
+ configureParametersComponents.toEntity(zmConfigureParameters, insAreaCompany.getAgreementId());
|
|
|
if (insAreaCompany.getOrderstatus().equals(InsOrderStatus.S_3.getCode())) {
|
|
|
return HttpResult.ok(InsOrderStatus.S_3.getDesc());
|
|
|
}
|
|
|
+
|
|
|
+ // 2. 组装请求体
|
|
|
OrderStatusRequest orderStatusRequest = new OrderStatusRequest();
|
|
|
orderStatusRequest.setOrderNo(insAreaCompany.getId());
|
|
|
orderStatusRequest.setSubProposalNo(insAreaCompany.getInsOrderNo());
|
|
|
+ orderStatusRequest.setHead(new BaseRequestHead(zmConfigureParameters));
|
|
|
+
|
|
|
OrderStatusResponse orderStatusResponse = zhongmeiRequestApiComponents.orderStatus(orderStatusRequest, OrderStatusResponse.class);
|
|
|
String status = orderStatusResponse.getStatus();
|
|
|
|
|
|
- // 承保成功修改状态
|
|
|
+ // 3. 承保成功修改状态
|
|
|
if (status.equals(String.valueOf(PaymentStatusEnum.P_2.getCode()))) {
|
|
|
insAreaCompany.setJqpolicyno(orderStatusResponse.getSubContractNoJ());
|
|
|
insAreaCompany.setSypolicyno(orderStatusResponse.getSubContractNoS());
|
|
|
insAreaCompany.setJypolicyno(orderStatusResponse.getAccidentNo());
|
|
|
insAreaCompany.setOrderstatus(InsOrderStatus.S_3.getCode());
|
|
|
- insOrdersService.updateByOrderStatus(insAreaCompany.getOrderno(), insAreaCompany.getOrderstatus());
|
|
|
- insAreaCompanyService.updateById(insAreaCompany);
|
|
|
+ insAreaCompanyService.updateCompanyAndOrders(insAreaCompany);
|
|
|
+
|
|
|
return HttpResult.ok(PaymentStatusEnum.P_2.getMeaning());
|
|
|
}
|
|
|
|
|
|
@@ -274,6 +315,10 @@ public class ZhongMeiOrderApiServiceImpl implements ZhongMeiOrderApiService {
|
|
|
@Override
|
|
|
public HttpResult getPolicyPrint(PolicyPrintVo policyPrintVo) {
|
|
|
InsAreaCompany insAreaCompany = insAreaCompanyService.getByIdIsExist(policyPrintVo.getCompanyId());
|
|
|
+ // 1. 协议id获取配置实体
|
|
|
+ ZmConfigureParameters zmConfigureParameters = new ZmConfigureParameters();
|
|
|
+ configureParametersComponents.toEntity(zmConfigureParameters, insAreaCompany.getAgreementId());
|
|
|
+
|
|
|
String policyNo;
|
|
|
String code = DocumentTypeEnum.code(policyPrintVo.getType());
|
|
|
String riskCode = policyPrintVo.getRiskCode();
|
|
|
@@ -284,33 +329,41 @@ public class ZhongMeiOrderApiServiceImpl implements ZhongMeiOrderApiService {
|
|
|
} else {
|
|
|
throw new SystemException("险种代码不存在");
|
|
|
}
|
|
|
+
|
|
|
+ // 2. 组装请求体
|
|
|
InsurancePolicyPrintRequest request = new InsurancePolicyPrintRequest();
|
|
|
request.setRiskCode(InsuranceTypeCorrespondence.getRisk().get(riskCode));
|
|
|
request.setPolicyNo(policyNo);
|
|
|
request.setDocumentType(code);
|
|
|
+ request.setHead(new BaseRequestHead(zmConfigureParameters));
|
|
|
InsurancePolicyPrintResponse response = zhongmeiRequestApiComponents.insurancePolicyPrint(request, InsurancePolicyPrintResponse.class);
|
|
|
return HttpResult.ok("下载成功", response.getDownloadUrl());
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
- * @param orderNo 中煤订单号
|
|
|
- * @param frameNo 车架号
|
|
|
- * @param customerInfoVo 车辆信息
|
|
|
+ * @param orderNo 中煤订单号
|
|
|
+ * @param frameNo 车架号
|
|
|
+ * @param customerInfoVo 车辆信息
|
|
|
+ * @param zmConfigureParameters 中煤配置参数
|
|
|
* @return 核保请求参数
|
|
|
*/
|
|
|
- public SubmitResponse submitForUnderwriting(String orderNo, String frameNo, CustomerInfoVo customerInfoVo) {
|
|
|
+ public SubmitResponse submitForUnderwriting(String orderNo, String frameNo, CustomerInfoVo customerInfoVo, ZmConfigureParameters zmConfigureParameters) {
|
|
|
SubmitRequest submitRequest = new SubmitRequest();
|
|
|
submitRequest.setOrderNo(orderNo);
|
|
|
submitRequest.setVin(frameNo);
|
|
|
SubmitRequest.DeliveryInfoDTO deliveryInfoDTO = new SubmitRequest.DeliveryInfoDTO(
|
|
|
customerInfoVo.getName(),
|
|
|
customerInfoVo.getMobile(),
|
|
|
- "140000",
|
|
|
- "140400",
|
|
|
- "140423",
|
|
|
+ // 省
|
|
|
+ zmConfigureParameters.getProvince(),
|
|
|
+ // 市
|
|
|
+ zmConfigureParameters.getCity(),
|
|
|
+ // 县
|
|
|
+ zmConfigureParameters.getDistrict(),
|
|
|
customerInfoVo.getAddr()
|
|
|
);
|
|
|
submitRequest.setDeliveryInfo(deliveryInfoDTO);
|
|
|
+ submitRequest.setHead(new BaseRequestHead(zmConfigureParameters));
|
|
|
return zhongmeiRequestApiComponents.submit(submitRequest, SubmitResponse.class);
|
|
|
}
|
|
|
|
|
|
@@ -391,12 +444,18 @@ public class ZhongMeiOrderApiServiceImpl implements ZhongMeiOrderApiService {
|
|
|
return quoteRespVo;
|
|
|
}
|
|
|
|
|
|
- public HttpResult<QuoteRespVo> responseOrder(QuotedPriceResponse quotedPriceResponse, QuoteRespVo quoteRespVo, EsmInsCompany esmInsCompanies, SubmitResponse submitResponse) {
|
|
|
+ public HttpResult<QuoteRespVo> responseOrder(QuotedPriceResponse quotedPriceResponse, QuoteRespVo quoteRespVo, EsmInsCompany esmInsCompanies, SubmitResponse submitResponse, String agreementId, Integer apiType) {
|
|
|
//保存订单信息
|
|
|
String orderNo = quoteRespVo.getOrderno();
|
|
|
InsAreaCompany insAreaCompany = new InsAreaCompany();
|
|
|
+
|
|
|
insAreaCompany.setId(quotedPriceResponse.getOrderNo());
|
|
|
insAreaCompany.setOrderno(orderNo);
|
|
|
+
|
|
|
+ // 协议id
|
|
|
+ insAreaCompany.setAgreementId(agreementId);
|
|
|
+ insAreaCompany.setApiType(apiType);
|
|
|
+
|
|
|
insAreaCompany.setReptxt(JSON.parseObject(JSON.toJSONString(quotedPriceResponse)));
|
|
|
insAreaCompany.setJqpremium(BigDecimal.valueOf(quoteRespVo.getJqPremium()));
|
|
|
insAreaCompany.setSypremium(BigDecimal.valueOf(quoteRespVo.getSyPremium()));
|