|
|
@@ -204,7 +204,7 @@ public class HuaNongCrawlerQuotedPriceRequestRequest implements HuaNongHeadReque
|
|
|
this.ocrFlag = "";
|
|
|
this.contractHome = Collections.emptyList();
|
|
|
this.contractGlass = Collections.emptyList();
|
|
|
- this.contractAccident = new ArrayList<>();
|
|
|
+ this.contractAccident = ContractAccidentDTO.build(quoteVo);
|
|
|
this.BListData = buildBListDataList();
|
|
|
this.D3ListData = buildD3ListDataList();
|
|
|
this.D4ListData = buildD4ListDataList();
|
|
|
@@ -1235,6 +1235,10 @@ public class HuaNongCrawlerQuotedPriceRequestRequest implements HuaNongHeadReque
|
|
|
public static class ContractAccidentDTO {
|
|
|
@JsonProperty("accident")
|
|
|
private List<Object> accident;
|
|
|
+ @JsonProperty("adjust")
|
|
|
+ private List<Object> adjust;
|
|
|
+ @JsonProperty("autoPriceApqMainList")
|
|
|
+ private List<Object> autoPriceApqMainList;
|
|
|
@JsonProperty("contractMain")
|
|
|
private ContractMainDTO contractMain;
|
|
|
@JsonProperty("coverage")
|
|
|
@@ -1243,6 +1247,10 @@ public class HuaNongCrawlerQuotedPriceRequestRequest implements HuaNongHeadReque
|
|
|
private PlatFormMessageDTO platFormMessage;
|
|
|
@JsonProperty("choosed")
|
|
|
private Boolean choosed;
|
|
|
+ @JsonProperty("engage")
|
|
|
+ private List<Object> engage;
|
|
|
+ @JsonProperty("loocked")
|
|
|
+ private Boolean loocked;
|
|
|
|
|
|
@NoArgsConstructor
|
|
|
@Data
|
|
|
@@ -1250,11 +1258,11 @@ public class HuaNongCrawlerQuotedPriceRequestRequest implements HuaNongHeadReque
|
|
|
@JsonProperty("contractNo")
|
|
|
private String contractNo;
|
|
|
@JsonProperty("expenseRate")
|
|
|
- private Integer expenseRate;
|
|
|
+ private String expenseRate;
|
|
|
@JsonProperty("productionDate")
|
|
|
private String productionDate;
|
|
|
@JsonProperty("performanceRate")
|
|
|
- private Integer performanceRate;
|
|
|
+ private String performanceRate;
|
|
|
@JsonProperty("costType")
|
|
|
private String costType;
|
|
|
@JsonProperty("choosed")
|
|
|
@@ -1449,6 +1457,48 @@ public class HuaNongCrawlerQuotedPriceRequestRequest implements HuaNongHeadReque
|
|
|
private String value;
|
|
|
}
|
|
|
}
|
|
|
+ private static List<ContractAccidentDTO> build(QuoteVo quoteVo) {
|
|
|
+ List<ContractAccidentDTO> contractAccident = new ArrayList<>();
|
|
|
+ if (quoteVo.getAccidentalDrivings() != null) {
|
|
|
+ quoteVo.getAccidentalDrivings().forEach(accident -> {
|
|
|
+ ContractAccidentDTO contractAccidentDTO = new ContractAccidentDTO();
|
|
|
+ contractAccidentDTO.setAccident(new ArrayList<>());
|
|
|
+ contractAccidentDTO.setAdjust(new ArrayList<>());
|
|
|
+ contractAccidentDTO.setAutoPriceApqMainList(new ArrayList<>());
|
|
|
+ contractAccidentDTO.setChoosed(true);
|
|
|
+ contractAccidentDTO.setContractMain(buildContractMainDTO(accident));
|
|
|
+ contractAccidentDTO.setCoverage(new ArrayList<>());
|
|
|
+ contractAccidentDTO.setEngage(new ArrayList<>());
|
|
|
+ contractAccidentDTO.setLoocked(false);
|
|
|
+ contractAccident.add(contractAccidentDTO);
|
|
|
+ });
|
|
|
+ }
|
|
|
+ return contractAccident;
|
|
|
+ }
|
|
|
+
|
|
|
+ private static ContractMainDTO buildContractMainDTO(AccidentalDrivingVo accidentVo) {
|
|
|
+ ContractMainDTO contractMainDTO = new ContractMainDTO();
|
|
|
+ contractMainDTO.setAllQuantity(String.valueOf(accidentVo.getQuantity()));
|
|
|
+ contractMainDTO.setChoosed(true);
|
|
|
+ contractMainDTO.setDiscount(100);
|
|
|
+ contractMainDTO.setExpenseRate("");
|
|
|
+ contractMainDTO.setExpiryDate("");
|
|
|
+ contractMainDTO.setInsuredObjectCode("7");
|
|
|
+ contractMainDTO.setInsuredObjectName("从车");
|
|
|
+ contractMainDTO.setIsRegistered("0");
|
|
|
+ contractMainDTO.setNvehRiskCode("");
|
|
|
+ contractMainDTO.setNvehRiskName("");
|
|
|
+ contractMainDTO.setNvehRiskType("");
|
|
|
+ contractMainDTO.setParagraph("1");
|
|
|
+ contractMainDTO.setPerformanceRate("");
|
|
|
+ contractMainDTO.setPlanCode(accidentVo.getProductCode());
|
|
|
+ contractMainDTO.setPlanName(accidentVo.getProductName());
|
|
|
+ contractMainDTO.setPlanSubCode("999N");
|
|
|
+ contractMainDTO.setProductionDate(TimeProcessing.nowDateTime());
|
|
|
+ contractMainDTO.setUnitPremium(0);
|
|
|
+ contractMainDTO.setValidDate(TimeProcessing.tomorrowDateTime());
|
|
|
+ return contractMainDTO;
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
@AllArgsConstructor
|