|
|
@@ -5,6 +5,7 @@ import com.ydtech.config.properties.PingAnApiConfigurationProperties;
|
|
|
import com.ydtech.constants.enums.dict.InsOrderStatusEnum;
|
|
|
import com.ydtech.core.page.HttpResult;
|
|
|
import com.ydtech.exception.SystemException;
|
|
|
+import com.ydtech.modules.ins.model.pingan.respose.PingAnQuoteRespVo;
|
|
|
import com.ydtech.modules.ins.model.vo.*;
|
|
|
import com.ydtech.modules.order.components.ConfigureParametersComponents;
|
|
|
import com.ydtech.modules.order.components.pingan.PinganRequestApiComponents;
|
|
|
@@ -27,10 +28,13 @@ import com.ydtech.modules.order.entity.crawler.vo.CrawlerPolicyPrintVo;
|
|
|
import com.ydtech.modules.order.entity.po.InsTaskImagesBase64;
|
|
|
import com.ydtech.modules.order.entity.vo.BaseQuoteInfoVo;
|
|
|
import com.ydtech.modules.order.entity.vo.BaseQuoteVo;
|
|
|
+import com.ydtech.modules.order.entity.vo.InsOrdersEditingVo;
|
|
|
import com.ydtech.modules.order.entity.vo.bohai.BoHaiQuoteAccidentVo;
|
|
|
import com.ydtech.modules.order.entity.vo.bohai.ProductDetailsQueryVo;
|
|
|
import com.ydtech.modules.order.entity.vo.bohai.ProductQueryVo;
|
|
|
+import com.ydtech.modules.order.entity.vo.pingan.PingAnQuoteVo;
|
|
|
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.PingAnOrderApiService;
|
|
|
import com.ydtech.modules.protocol.entity.po.PtlAgreementAttribution;
|
|
|
@@ -65,6 +69,8 @@ public class PingAnOrderApiServiceImpl implements PingAnOrderApiService {
|
|
|
|
|
|
private final InsTaskImagesService insTaskImagesService;
|
|
|
|
|
|
+ private final InsOrdersService insOrdersService;
|
|
|
+
|
|
|
|
|
|
private final PingAnApiConfigurationProperties properties;
|
|
|
/**
|
|
|
@@ -142,7 +148,7 @@ public class PingAnOrderApiServiceImpl implements PingAnOrderApiService {
|
|
|
*
|
|
|
*/
|
|
|
@Override
|
|
|
- public HttpResult<QuoteRespVo> quote(BaseQuoteInfoVo quoteInfo, BaseQuoteVo<List<BoHaiQuoteAccidentVo>> quoteVo) throws Exception {
|
|
|
+ public HttpResult<QuoteRespVo> quote(BaseQuoteInfoVo quoteInfo, PingAnQuoteVo<List<BoHaiQuoteAccidentVo>> quoteVo) throws Exception {
|
|
|
// 协议id获取配置实体
|
|
|
String agreementId = quoteVo.getAgreementId();
|
|
|
// 账号信息
|
|
|
@@ -172,7 +178,10 @@ public class PingAnOrderApiServiceImpl implements PingAnOrderApiService {
|
|
|
CarConfirmResponse carConfirmResponse = pinganRequestApiComponents.carConfirm(carConfirmRequest);
|
|
|
|
|
|
//4.报价 使用车辆确认返回的流程id
|
|
|
- QuoteRequest quoteRequest = new QuoteRequest(parameters, quoteInfo, modelsDto, carConfirmResponse.getFlowid(),"applyBiz",new QuoteRequest.BizQuoteDTO(),"applyForce","accommodationFlag", "applyUnAuto","applyXiaoWei",new ArrayList<QuoteRequest.UnAutoListInfoDTO>(),new ArrayList<QuoteRequest.UnAutoListInfoDTO>(),new ArrayList<QuoteRequest.Amount22XNYChargingPostListDTO>(), new ArrayList<QuoteRequest.Amount23XNYChargingPostListDTO>());
|
|
|
+ CarConfirmResponse.BizQuoteDTO bizQuote = carConfirmResponse.getBizQuote();
|
|
|
+ QuoteRequest.BizQuoteDTO bizQuoteDTO = new QuoteRequest.BizQuoteDTO(bizQuote.getBeginDate());
|
|
|
+
|
|
|
+ QuoteRequest quoteRequest = new QuoteRequest(parameters, quoteInfo, modelsDto, carConfirmResponse.getFlowid(),carConfirmResponse.getIsBizElectronicPolicy(),bizQuoteDTO,carConfirmResponse.getIsForceElectronicPolicy(),quoteVo.getAccommodationFlag(), quoteVo.getApplyUnAuto(),quoteVo.getApplyXiaoWei(),quoteVo.getUnAutoListInfo(),quoteVo.getXiaoWeiListInfo(),quoteVo.getAmount22XNYChargingPostList(), quoteVo.getAmount23XNYChargingPostList());
|
|
|
QuoteResponse quoteResponse=null;
|
|
|
try{
|
|
|
quoteResponse= pinganRequestApiComponents.quote(quoteRequest);
|
|
|
@@ -194,7 +203,7 @@ public class PingAnOrderApiServiceImpl implements PingAnOrderApiService {
|
|
|
PtlAgreementAttribution ptlAgreementAttribution,
|
|
|
SearchPAVehicleListResponse.ModelsDto modelsDto) {
|
|
|
|
|
|
- QuoteRespVo quoteRespVo = new QuoteRespVo();
|
|
|
+ PingAnQuoteRespVo quoteRespVo = new PingAnQuoteRespVo();
|
|
|
// 交强险保费信息
|
|
|
QuoteResponse.ForceQuoteResultDTO forceQuoteResult = response.getForceQuoteResult();
|
|
|
//交强险保费
|
|
|
@@ -258,6 +267,9 @@ public class PingAnOrderApiServiceImpl implements PingAnOrderApiService {
|
|
|
// 小微险保费
|
|
|
QuoteResponse.XwActualPremiumDTO xwActualPremium = response.getXwActualPremium();
|
|
|
//小微险保费
|
|
|
+ quoteRespVo.setAhsUpcActualPremium(ahsUpcActualPremium);
|
|
|
+
|
|
|
+ quoteRespVo.setXwActualPremium(xwActualPremium);
|
|
|
|
|
|
List<RiskInfoVo> riskList = yaQuoteInfoVo.getRiskList();
|
|
|
// 非车险
|
|
|
@@ -415,8 +427,14 @@ public class PingAnOrderApiServiceImpl implements PingAnOrderApiService {
|
|
|
PingAnConfigureParameters parameters = configureParametersComponents.toEntity(PingAnConfigureParameters.class,
|
|
|
ptlAgreementAttribution);
|
|
|
BaseQuoteVo<List<BoHaiQuoteAccidentVo>> quoteVo=new BaseQuoteVo<>();
|
|
|
+
|
|
|
+ //通过订单号查询车辆信息和车主信息
|
|
|
+ InsOrdersEditingVo insOrders = insOrdersService.revise(subOrderNo);
|
|
|
+ //车主信息
|
|
|
+ CustomerInfoVo ownerInfo = insOrders.getOwnerinfo().toJavaObject(CustomerInfoVo.class);
|
|
|
+ CarInfoVo carInfoVo = insOrders.getCarinfo().toJavaObject(CarInfoVo.class);
|
|
|
//调用 电子保单pdf 001
|
|
|
- PolicyPdfRequest policyPdfRequest = new PolicyPdfRequest(parameters,quoteVo,"checkNo","licenseNo","frameNo");
|
|
|
+ PolicyPdfRequest policyPdfRequest = new PolicyPdfRequest(parameters,quoteVo,ownerInfo.getIdentifyNumber(),carInfoVo.getLicenseNo(),carInfoVo.getFrameNo());
|
|
|
PolicyPdfResponse policyPdfResponse=null;
|
|
|
try{
|
|
|
policyPdfResponse= pinganRequestApiComponents.getPolicyPdf(policyPdfRequest);
|
|
|
@@ -595,7 +613,7 @@ public class PingAnOrderApiServiceImpl implements PingAnOrderApiService {
|
|
|
*
|
|
|
*/
|
|
|
@Override
|
|
|
- public HttpResult<Object> getDmvehicleInfo(BaseQuoteVo<List<BoHaiQuoteAccidentVo>> quoteVo,BaseQuoteInfoVo quoteInfo) {
|
|
|
+ public HttpResult<Object> getDmvehicleInfo(PingAnQuoteVo<List<BoHaiQuoteAccidentVo>> quoteVo,BaseQuoteInfoVo quoteInfo) {
|
|
|
// 协议id获取配置实体
|
|
|
String agreementId = quoteVo.getAgreementId();
|
|
|
// 账号信息
|
|
|
@@ -638,7 +656,7 @@ public class PingAnOrderApiServiceImpl implements PingAnOrderApiService {
|
|
|
*
|
|
|
*/
|
|
|
@Override
|
|
|
- public HttpResult<Object> renewalConfirm(BaseQuoteVo<List<BoHaiQuoteAccidentVo>> quoteVo, BaseQuoteInfoVo quoteInfo) {
|
|
|
+ public HttpResult<Object> renewalConfirm(PingAnQuoteVo<List<BoHaiQuoteAccidentVo>> quoteVo, BaseQuoteInfoVo quoteInfo) {
|
|
|
// 协议id获取配置实体
|
|
|
String agreementId = quoteVo.getAgreementId();
|
|
|
// 账号信息
|
|
|
@@ -710,7 +728,7 @@ public class PingAnOrderApiServiceImpl implements PingAnOrderApiService {
|
|
|
*
|
|
|
*/
|
|
|
@Override
|
|
|
- public HttpResult<Object> getDocumentStatusList(BaseQuoteVo<List<BoHaiQuoteAccidentVo>> quoteVo) {
|
|
|
+ public HttpResult<Object> getDocumentStatusList(PingAnQuoteVo<List<BoHaiQuoteAccidentVo>> quoteVo) {
|
|
|
|
|
|
try{
|
|
|
//调用
|
|
|
@@ -747,7 +765,7 @@ public class PingAnOrderApiServiceImpl implements PingAnOrderApiService {
|
|
|
*
|
|
|
*/
|
|
|
@Override
|
|
|
- public HttpResult<Object> repealDocument(BaseQuoteVo<List<BoHaiQuoteAccidentVo>> quoteVo) {
|
|
|
+ public HttpResult<Object> repealDocument(PingAnQuoteVo<List<BoHaiQuoteAccidentVo>> quoteVo) {
|
|
|
try{
|
|
|
//调用
|
|
|
// 协议id获取配置实体
|