Răsfoiți Sursa

中煤企业车

Qchen 1 an în urmă
părinte
comite
aa3f4695b5

+ 2 - 0
src/main/java/com/ydtech/modules/order/entity/api/huatai/request/HuaTaiSubmitRequest.java

@@ -24,6 +24,7 @@ import org.joda.time.DateTime;
 import java.io.Serializable;
 import java.util.ArrayList;
 import java.util.Arrays;
+import java.util.Collections;
 import java.util.List;
 import java.util.stream.Collectors;
 
@@ -199,6 +200,7 @@ public class HuaTaiSubmitRequest extends HuaTaiBaseRequest {
                 this.expiryDate = insAreaCompany.getSyEndDate();
             }
             this.riskCode = InsuranceTypeCorrespondence.getHuaTaiRisk().get(riskInfoVo.getRiskCode());
+            this.remark = "自核通过";
         }
     }
 

+ 45 - 13
src/main/java/com/ydtech/modules/order/entity/api/zhongmei/request/QuotedPriceRequest.java

@@ -167,7 +167,9 @@ public class QuotedPriceRequest extends BaseRequest {
                 this.province = zmConfigureParameters.getProvince();
                 this.city = zmConfigureParameters.getCity();
                 this.district = zmConfigureParameters.getDistrict();
-                this.accountUser = zmConfigureParameters.getAccountUser();
+                if (zmConfigureParameters.getAccountUser() != null) {
+                    this.accountUser = zmConfigureParameters.getAccountUser();
+                }
             }
 
         }
@@ -530,19 +532,49 @@ public class QuotedPriceRequest extends BaseRequest {
         @JsonProperty("identifyValidEndDate")
         private String identifyValidEndDate;
 
+        // 注册日期(法人必传)
+        @JsonProperty("regisDate")
+        private String regisDate;
+
+        // 营业执照单位全称
+        @JsonProperty("businessLicense")
+        private String businessLicense;
+
+        // 纳税人识别号或社会信用代码
+        @JsonProperty("taxperNumber")
+        private String taxperNumber;
+
         public CustomerDTO(CustomerInfoVo customerInfoVo, String role) {
-            this.name = customerInfoVo.getName();
-            this.identifyType = "01";
-            this.identifyNumber = customerInfoVo.getIdentifyNumber();
-            this.addr = customerInfoVo.getAddr();
-            this.mobile = customerInfoVo.getMobile();
-            this.emailPolicy = customerInfoVo.getEmail();
-            this.type = "1";
-            this.role = role;
-            this.invocieType = "026";
-            this.jobRisk = "1";
-            this.identifyValidDate = customerInfoVo.getIdentifyValidDate() + " " + TimeConstants.START_TIME;
-            this.identifyValidEndDate = customerInfoVo.getIdentifyValidEndDate() + " " + TimeConstants.END_TIME;
+            if (customerInfoVo.getProperty() != null && customerInfoVo.getProperty().equals("1")) {
+                this.name = customerInfoVo.getName();
+                this.type = "1";
+                this.identifyType = "01";
+                this.identifyNumber = customerInfoVo.getIdentifyNumber();
+                this.role = role;
+                this.mobile = customerInfoVo.getMobile();
+                this.addr = customerInfoVo.getAddr();
+                this.emailPolicy = customerInfoVo.getEmail();
+                this.identifyValidDate = customerInfoVo.getIdentifyValidDate() + " " + TimeConstants.START_TIME;
+                this.identifyValidEndDate = customerInfoVo.getIdentifyValidEndDate() + " " + TimeConstants.END_TIME;
+                this.invocieType = "026";
+                this.jobRisk = "1";
+            }else if (customerInfoVo.getProperty() != null && customerInfoVo.getProperty().equals("0")) {
+                this.name = customerInfoVo.getName();
+                this.type = "2";
+                this.identifyType = "4";
+                this.role = role;
+                this.identifyNumber = customerInfoVo.getOrganizationCode();
+                this.mobile = customerInfoVo.getMobile();
+                this.addr = customerInfoVo.getAddr();
+                this.emailPolicy = customerInfoVo.getEmail();
+                this.identifyValidDate = customerInfoVo.getIdentifyValidDate() + " " + TimeConstants.START_TIME;
+                this.identifyValidEndDate = customerInfoVo.getIdentifyValidEndDate() + " " + TimeConstants.END_TIME;
+                this.invocieType = "026";
+                this.regisDate = customerInfoVo.getIdentifyValidDate() + " " + TimeConstants.START_TIME;
+                this.businessLicense = customerInfoVo.getName();
+                this.taxperNumber = customerInfoVo.getOrganizationCode();
+            }
+
         }
 
         public List<CustomerDTO> getCustomers(CustomerInfoVo ownerInfo, CustomerInfoVo policyHolderInfo, CustomerInfoVo insuredPersonInfo) {

+ 6 - 6
src/main/java/com/ydtech/modules/order/service/impl/ZhongMeiOrderApiServiceImpl.java

@@ -273,7 +273,7 @@ public class ZhongMeiOrderApiServiceImpl implements ZhongMeiOrderApiService {
 
     @Override
     public HttpResult<Object> audit(String companyId) {
-        InsAreaCompany insAreaCompany = insAreaCompanyService.getByInsOrderNo(companyId);
+        InsAreaCompany insAreaCompany = insAreaCompanyService.getByIdIsExist(companyId);
         // 1. 协议id获取配置实体
         ZmConfigureParameters zmConfigureParameters = configureParametersComponents.toEntity(ZmConfigureParameters.class,
                 insAreaCompany.getAgreementId());
@@ -282,7 +282,7 @@ public class ZhongMeiOrderApiServiceImpl implements ZhongMeiOrderApiService {
         JSONObject ownerinfo = insOrders.getApplyinfo();
         CustomerInfoVo customerInfoVo = ownerinfo.toJavaObject(CustomerInfoVo.class);
         // 2. 提交核保
-        SubmitResponse response = submitForUnderwriting(insAreaCompany.getId(), insOrders.getFrameno(), customerInfoVo,
+        SubmitResponse response = submitForUnderwriting(insAreaCompany.getInsOrderNo(), insOrders.getFrameno(), customerInfoVo,
                 zmConfigureParameters);
         // 3. 人工核保
         if (SubmitStatus.S_3.getCode().equals(response.getSubmitStatus())) {
@@ -313,14 +313,14 @@ public class ZhongMeiOrderApiServiceImpl implements ZhongMeiOrderApiService {
 
     @Override
     public HttpResult<Object> submitImage(String companyId) {
-        InsAreaCompany insAreaCompany = insAreaCompanyService.getByInsOrderNo(companyId);
+        InsAreaCompany insAreaCompany = insAreaCompanyService.getByIdIsExist(companyId);
         // 1. 协议id获取配置实体
         ZmConfigureParameters zmConfigureParameters = configureParametersComponents.toEntity(ZmConfigureParameters.class,
                 insAreaCompany.getAgreementId());
 
         InsOrders insOrders = insOrdersService.getById(insAreaCompany.getOrderno());
         // 2. 投保单号(总)
-        String insOrderNo = insAreaCompany.getId();
+        String insOrderNo = insAreaCompany.getInsOrderNo();
 
         List<InsTaskImagesBase64> insTaskImagesBase64s = insTaskImagesService.findByOrderNo(insOrders.getOrderno(), insAreaCompany.getId());
 
@@ -393,7 +393,7 @@ public class ZhongMeiOrderApiServiceImpl implements ZhongMeiOrderApiService {
 
     @Override
     public HttpResult<Object> paymentEnquiry(String companyId) {
-        InsAreaCompany insAreaCompany = insAreaCompanyService.getByInsOrderNo(companyId);
+        InsAreaCompany insAreaCompany = insAreaCompanyService.getByIdIsExist(companyId);
 
         // 1. 协议id获取配置实体
         ZmConfigureParameters zmConfigureParameters = configureParametersComponents.toEntity(ZmConfigureParameters.class,
@@ -661,7 +661,7 @@ public class ZhongMeiOrderApiServiceImpl implements ZhongMeiOrderApiService {
 
     @Override
     public HttpResult<Object> auditStatusQuery(String companyId) {
-        InsAreaCompany insAreaCompany = insAreaCompanyService.getByInsOrderNo(companyId);
+        InsAreaCompany insAreaCompany = insAreaCompanyService.getByIdIsExist(companyId);
         // 1. 协议id获取配置实体
         ZmConfigureParameters zmConfigureParameters = configureParametersComponents.toEntity(ZmConfigureParameters.class,
                 insAreaCompany.getAgreementId());