|
@@ -196,9 +196,9 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
//获苏商已签署文件
|
|
//获苏商已签署文件
|
|
List<SmbContractInfo> smbContractInfos = singContract(contractInfo.getId());
|
|
List<SmbContractInfo> smbContractInfos = singContract(contractInfo.getId());
|
|
for (SmbContractInfo smbContractInfo : smbContractInfos) {
|
|
for (SmbContractInfo smbContractInfo : smbContractInfos) {
|
|
- if(smbContractInfo.getContractType() == 1){
|
|
|
|
|
|
+ if (smbContractInfo.getContractType() == 1) {
|
|
smbContractInfo.setContractTypeName("额度借款合同");
|
|
smbContractInfo.setContractTypeName("额度借款合同");
|
|
- }else if(smbContractInfo.getContractType() == 2){
|
|
|
|
|
|
+ } else if (smbContractInfo.getContractType() == 2) {
|
|
smbContractInfo.setContractTypeName("最高额保证合同");
|
|
smbContractInfo.setContractTypeName("最高额保证合同");
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -655,8 +655,8 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
}
|
|
}
|
|
}
|
|
}
|
|
//苏商资方的需要签署苏商的合同
|
|
//苏商资方的需要签署苏商的合同
|
|
- if(contractTemplate.getTemplateCode().equals(ConstantConversionUtil.SUSHANGGUARANTEECONTRAT) || contractTemplate.getTemplateCode().equals(ConstantConversionUtil.SUSHANGFIRSTCONTRAT)){
|
|
|
|
- if(ConstantUtil.JIANGSU_SUSHANG_BANK.equals(reviewFinancingInfo.getInstitutionName())){
|
|
|
|
|
|
+ if (contractTemplate.getTemplateCode().equals(ConstantConversionUtil.SUSHANGGUARANTEECONTRAT) || contractTemplate.getTemplateCode().equals(ConstantConversionUtil.SUSHANGFIRSTCONTRAT)) {
|
|
|
|
+ if (ConstantUtil.JIANGSU_SUSHANG_BANK.equals(reviewFinancingInfo.getInstitutionName())) {
|
|
ReviewQuotaDisburse reviewQuotaDisburse = reviewQuotaDisburseService.getById(reviewFinancingInfo.getReviewQuotaDisburseId());
|
|
ReviewQuotaDisburse reviewQuotaDisburse = reviewQuotaDisburseService.getById(reviewFinancingInfo.getReviewQuotaDisburseId());
|
|
CFinancingBasicInfo cFinancingBasicInfo = financingBasicInfoService.getById(reviewQuotaDisburse.getFinancingBasicInfoId());
|
|
CFinancingBasicInfo cFinancingBasicInfo = financingBasicInfoService.getById(reviewQuotaDisburse.getFinancingBasicInfoId());
|
|
SupplierInfo supplierInfo = supplierInfoService.getByEnterpriseId(cFinancingBasicInfo.getMainEnterpriseId());
|
|
SupplierInfo supplierInfo = supplierInfoService.getByEnterpriseId(cFinancingBasicInfo.getMainEnterpriseId());
|
|
@@ -664,15 +664,15 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
List<FinancingFromInvestorsHistory> financingFromInvestorsHistories = financingFromInvestorsHistoryService.lambdaQuery().eq(FinancingFromInvestorsHistory::getSupplierInfoId, supplierInfo.getId()).orderByDesc(FinancingFromInvestorsHistory::getId).list();
|
|
List<FinancingFromInvestorsHistory> financingFromInvestorsHistories = financingFromInvestorsHistoryService.lambdaQuery().eq(FinancingFromInvestorsHistory::getSupplierInfoId, supplierInfo.getId()).orderByDesc(FinancingFromInvestorsHistory::getId).list();
|
|
FinancingFromInvestorsHistory financingFromInvestorsHistory = financingFromInvestorsHistories.get(0);
|
|
FinancingFromInvestorsHistory financingFromInvestorsHistory = financingFromInvestorsHistories.get(0);
|
|
FinancingFromInvestorsNotice financingFromInvestorsNotice = financingFromInvestorsNoticeService.lambdaQuery().eq(FinancingFromInvestorsNotice::getFinancingFromInvestorsHistoryId, financingFromInvestorsHistory.getId()).one();
|
|
FinancingFromInvestorsNotice financingFromInvestorsNotice = financingFromInvestorsNoticeService.lambdaQuery().eq(FinancingFromInvestorsNotice::getFinancingFromInvestorsHistoryId, financingFromInvestorsHistory.getId()).one();
|
|
- if(CollectionUtil.isEmpty(financingFromInvestorsHistories) || financingFromInvestorsNotice == null){
|
|
|
|
- throw new BusinessException(CodeUtil.FAIL,"该供应商还未在苏商银行取得授信,请先完成苏商授信!");
|
|
|
|
|
|
+ if (CollectionUtil.isEmpty(financingFromInvestorsHistories) || financingFromInvestorsNotice == null) {
|
|
|
|
+ throw new BusinessException(CodeUtil.FAIL, "该供应商还未在苏商银行取得授信,请先完成苏商授信!");
|
|
}
|
|
}
|
|
- if(financingFromInvestorsNotice.getExpiringDate().compareTo(new Date()) == -1){
|
|
|
|
- throw new BusinessException(CodeUtil.FAIL,"该供应商在苏商银行的授信已过期,请先完成苏商续授信!");
|
|
|
|
|
|
+ if (financingFromInvestorsNotice.getExpiringDate().compareTo(new Date()) == -1) {
|
|
|
|
+ throw new BusinessException(CodeUtil.FAIL, "该供应商在苏商银行的授信已过期,请先完成苏商续授信!");
|
|
}
|
|
}
|
|
smbContractInfos = smbContractInfos.stream()
|
|
smbContractInfos = smbContractInfos.stream()
|
|
.filter(r -> r.getGmtCreate().before(financingFromInvestorsNotice.getExpiringDate()) && r.getSignStatus()).collect(Collectors.toList());
|
|
.filter(r -> r.getGmtCreate().before(financingFromInvestorsNotice.getExpiringDate()) && r.getSignStatus()).collect(Collectors.toList());
|
|
- if(CollectionUtil.isEmpty(smbContractInfos)){
|
|
|
|
|
|
+ if (CollectionUtil.isEmpty(smbContractInfos)) {
|
|
Dictionary dictionaryNew = new Dictionary();
|
|
Dictionary dictionaryNew = new Dictionary();
|
|
dictionaryNew.setCode(contractTemplate.getTemplateCode());
|
|
dictionaryNew.setCode(contractTemplate.getTemplateCode());
|
|
dictionaryNew.setName(contractTemplate.getName());
|
|
dictionaryNew.setName(contractTemplate.getName());
|
|
@@ -827,7 +827,7 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
//修改融资申请当前阶段
|
|
//修改融资申请当前阶段
|
|
financingBasicInfo.setCurrentStage(FinancingCurrentStageEnum.REVIEW_QUOTA_DISBURSE.getCode());
|
|
financingBasicInfo.setCurrentStage(FinancingCurrentStageEnum.REVIEW_QUOTA_DISBURSE.getCode());
|
|
financingBasicInfoService.updateById(financingBasicInfo);
|
|
financingBasicInfoService.updateById(financingBasicInfo);
|
|
- } else if (contractInfo.getConclusion().equals(ConstantConversionUtil.APPROVAL_RESULT_VETO)){
|
|
|
|
|
|
+ } else if (contractInfo.getConclusion().equals(ConstantConversionUtil.APPROVAL_RESULT_VETO)) {
|
|
//修改融资申请当前阶段和状态
|
|
//修改融资申请当前阶段和状态
|
|
financingBasicInfo.setFinancingStatus(ProjectInitiationStatusDict.ChildEnum.TERMINATED.getCode());
|
|
financingBasicInfo.setFinancingStatus(ProjectInitiationStatusDict.ChildEnum.TERMINATED.getCode());
|
|
financingBasicInfo.setCurrentStage("");
|
|
financingBasicInfo.setCurrentStage("");
|
|
@@ -954,9 +954,9 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
autoElectronicSignHis(contractInfoHis);
|
|
autoElectronicSignHis(contractInfoHis);
|
|
List<SmbContractInfo> smbContractInfos = singContract(contractInfoHis.getContractInfoId());
|
|
List<SmbContractInfo> smbContractInfos = singContract(contractInfoHis.getContractInfoId());
|
|
for (SmbContractInfo smbContractInfo : smbContractInfos) {
|
|
for (SmbContractInfo smbContractInfo : smbContractInfos) {
|
|
- if(smbContractInfo.getContractType() == 1){
|
|
|
|
|
|
+ if (smbContractInfo.getContractType() == 1) {
|
|
smbContractInfo.setContractTypeName("额度借款合同");
|
|
smbContractInfo.setContractTypeName("额度借款合同");
|
|
- }else if(smbContractInfo.getContractType() == 2){
|
|
|
|
|
|
+ } else if (smbContractInfo.getContractType() == 2) {
|
|
smbContractInfo.setContractTypeName("最高额保证合同");
|
|
smbContractInfo.setContractTypeName("最高额保证合同");
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -1009,7 +1009,7 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
List<SmbContractInfo> smbContractInfos = new ArrayList<>();
|
|
List<SmbContractInfo> smbContractInfos = new ArrayList<>();
|
|
ContractInfo contractInfo = contractInfoService.getById(contractInfoId);
|
|
ContractInfo contractInfo = contractInfoService.getById(contractInfoId);
|
|
ReviewFinancingInfo reviewFinancingInfo = reviewFinancingInfoService.lambdaQuery().eq(ReviewFinancingInfo::getReviewQuotaDisburseId, contractInfo.getReviewQuotaDisburseId()).one();
|
|
ReviewFinancingInfo reviewFinancingInfo = reviewFinancingInfoService.lambdaQuery().eq(ReviewFinancingInfo::getReviewQuotaDisburseId, contractInfo.getReviewQuotaDisburseId()).one();
|
|
- if(ConstantUtil.JIANGSU_SUSHANG_BANK.equals(reviewFinancingInfo.getInstitutionName())){
|
|
|
|
|
|
+ if (ConstantUtil.JIANGSU_SUSHANG_BANK.equals(reviewFinancingInfo.getInstitutionName())) {
|
|
ReviewQuotaDisburse reviewQuotaDisburse = reviewQuotaDisburseService.getById(reviewFinancingInfo.getReviewQuotaDisburseId());
|
|
ReviewQuotaDisburse reviewQuotaDisburse = reviewQuotaDisburseService.getById(reviewFinancingInfo.getReviewQuotaDisburseId());
|
|
CFinancingBasicInfo cFinancingBasicInfo = financingBasicInfoService.getById(reviewQuotaDisburse.getFinancingBasicInfoId());
|
|
CFinancingBasicInfo cFinancingBasicInfo = financingBasicInfoService.getById(reviewQuotaDisburse.getFinancingBasicInfoId());
|
|
SupplierInfo supplierInfo = supplierInfoService.getByEnterpriseId(cFinancingBasicInfo.getMainEnterpriseId());
|
|
SupplierInfo supplierInfo = supplierInfoService.getByEnterpriseId(cFinancingBasicInfo.getMainEnterpriseId());
|
|
@@ -1020,7 +1020,7 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
FinancingFromInvestorsNotice financingFromInvestorsNotice = financingFromInvestorsNoticeService.lambdaQuery().eq(FinancingFromInvestorsNotice::getFinancingFromInvestorsHistoryId, financingFromInvestorsHistory.getId()).one();
|
|
FinancingFromInvestorsNotice financingFromInvestorsNotice = financingFromInvestorsNoticeService.lambdaQuery().eq(FinancingFromInvestorsNotice::getFinancingFromInvestorsHistoryId, financingFromInvestorsHistory.getId()).one();
|
|
smbContractInfos = smbContractInfos.stream().filter(r -> r.getGmtCreate().before(financingFromInvestorsNotice.getExpiringDate())).collect(Collectors.toList());
|
|
smbContractInfos = smbContractInfos.stream().filter(r -> r.getGmtCreate().before(financingFromInvestorsNotice.getExpiringDate())).collect(Collectors.toList());
|
|
//该供应商存在签署过的苏商银行的合同的话就不需要再次签署
|
|
//该供应商存在签署过的苏商银行的合同的话就不需要再次签署
|
|
- if(CollectionUtil.isEmpty(smbContractInfos)){
|
|
|
|
|
|
+ if (CollectionUtil.isEmpty(smbContractInfos)) {
|
|
smbContractInfos = new ArrayList<>();
|
|
smbContractInfos = new ArrayList<>();
|
|
//主合同
|
|
//主合同
|
|
SmbContractInfo smbContractInfoMaster = new SmbContractInfo();
|
|
SmbContractInfo smbContractInfoMaster = new SmbContractInfo();
|
|
@@ -1045,18 +1045,18 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
smbContractInfoService.save(smbContractInfoGua);
|
|
smbContractInfoService.save(smbContractInfoGua);
|
|
smbContractInfos.add(smbContractInfoGua);
|
|
smbContractInfos.add(smbContractInfoGua);
|
|
|
|
|
|
- }else {
|
|
|
|
|
|
+ } else {
|
|
for (SmbContractInfo smbContractInfo : smbContractInfos) {
|
|
for (SmbContractInfo smbContractInfo : smbContractInfos) {
|
|
- if(smbContractInfo.getContractElectronicInfoId() != null){
|
|
|
|
|
|
+ if (smbContractInfo.getContractElectronicInfoId() != null) {
|
|
ContractElectronicInfo electronicInfo = contractElectronicInfoService.getById(smbContractInfo.getContractElectronicInfoId());
|
|
ContractElectronicInfo electronicInfo = contractElectronicInfoService.getById(smbContractInfo.getContractElectronicInfoId());
|
|
List<ContractElectronicCustomerInfo> list = contractElectronicCustomerInfoService.lambdaQuery().eq(ContractElectronicCustomerInfo::getContractElectronicInfoId, electronicInfo.getId()).list();
|
|
List<ContractElectronicCustomerInfo> list = contractElectronicCustomerInfoService.lambdaQuery().eq(ContractElectronicCustomerInfo::getContractElectronicInfoId, electronicInfo.getId()).list();
|
|
- if(CollectionUtil.isNotEmpty(list)){
|
|
|
|
|
|
+ if (CollectionUtil.isNotEmpty(list)) {
|
|
AttachmentDto attachmentDto = AttachmentDto.builder()
|
|
AttachmentDto attachmentDto = AttachmentDto.builder()
|
|
.setChildEnum(FileModuleDict.ChildEnum.SMB_SING_FILE)
|
|
.setChildEnum(FileModuleDict.ChildEnum.SMB_SING_FILE)
|
|
.setEntityId(smbContractInfo.getId())
|
|
.setEntityId(smbContractInfo.getId())
|
|
.build();
|
|
.build();
|
|
List<FileStorage> files = sysAttachmentRefService.getFiles(attachmentDto);
|
|
List<FileStorage> files = sysAttachmentRefService.getFiles(attachmentDto);
|
|
- if(CollectionUtil.isNotEmpty(files)){
|
|
|
|
|
|
+ if (CollectionUtil.isNotEmpty(files)) {
|
|
FileStorage storage = files.get(0);
|
|
FileStorage storage = files.get(0);
|
|
smbContractInfo.setFileStorage(storage);
|
|
smbContractInfo.setFileStorage(storage);
|
|
}
|
|
}
|
|
@@ -1139,7 +1139,7 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
if (CollectionUtil.isNotEmpty(contractElectronicInfoList)) {
|
|
if (CollectionUtil.isNotEmpty(contractElectronicInfoList)) {
|
|
for (ContractElectronicInfo contractElectronicInfo : contractElectronicInfoList) {
|
|
for (ContractElectronicInfo contractElectronicInfo : contractElectronicInfoList) {
|
|
SmbContractInfo smbContractInfo = smbContractInfoService.lambdaQuery().eq(SmbContractInfo::getContractElectronicInfoId, contractElectronicInfo.getId()).one();
|
|
SmbContractInfo smbContractInfo = smbContractInfoService.lambdaQuery().eq(SmbContractInfo::getContractElectronicInfoId, contractElectronicInfo.getId()).one();
|
|
- if(smbContractInfo == null){
|
|
|
|
|
|
+ if (smbContractInfo == null) {
|
|
contractElectronicCustomerInfoService.remove(new QueryWrapper<ContractElectronicCustomerInfo>()
|
|
contractElectronicCustomerInfoService.remove(new QueryWrapper<ContractElectronicCustomerInfo>()
|
|
.eq("contract_electronic_info_id", contractElectronicInfo.getId()));
|
|
.eq("contract_electronic_info_id", contractElectronicInfo.getId()));
|
|
contractElectronicInfoService.removeById(contractElectronicInfo.getId());
|
|
contractElectronicInfoService.removeById(contractElectronicInfo.getId());
|
|
@@ -1166,7 +1166,7 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
type.equals(ConstantConversionUtil.FACTORING_CONTRACT_NUMBER_GUARANTEE_PERSON) ||
|
|
type.equals(ConstantConversionUtil.FACTORING_CONTRACT_NUMBER_GUARANTEE_PERSON) ||
|
|
type.equals(ConstantConversionUtil.GENERAL_GUARANTEE_COMPANY_M2) || type.equals(ConstantConversionUtil.GENERAL_GUARANTEE_PERSONAL_M2) ||
|
|
type.equals(ConstantConversionUtil.GENERAL_GUARANTEE_COMPANY_M2) || type.equals(ConstantConversionUtil.GENERAL_GUARANTEE_PERSONAL_M2) ||
|
|
type.equals(ConstantConversionUtil.SUSHANGGUARANTEECONTRAT) || type.equals(ConstantConversionUtil.SUSHANGFIRSTCONTRAT)) {
|
|
type.equals(ConstantConversionUtil.SUSHANGGUARANTEECONTRAT) || type.equals(ConstantConversionUtil.SUSHANGFIRSTCONTRAT)) {
|
|
- doNotAutoSign(contractInfo, templateName, contractElectronicCustomerInfos, file, contractInfoHis,type);
|
|
|
|
|
|
+ doNotAutoSign(contractInfo, templateName, contractElectronicCustomerInfos, file, contractInfoHis, type);
|
|
} else {
|
|
} else {
|
|
doAutoSign(contractInfo, autoSignKeyword, templateName, contractElectronicCustomerInfos, file, contractInfoHis);
|
|
doAutoSign(contractInfo, autoSignKeyword, templateName, contractElectronicCustomerInfos, file, contractInfoHis);
|
|
}
|
|
}
|
|
@@ -1209,17 +1209,17 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
contractElectronicCustomerInfoHisService.save(contractElectronicCustomerInfoHis);
|
|
contractElectronicCustomerInfoHisService.save(contractElectronicCustomerInfoHis);
|
|
}
|
|
}
|
|
ProjectInformation projectInformation = projectInformationService.lambdaQuery().eq(ProjectInformation::getBusinessNumber, contractInfo.getBusinessNo()).one();
|
|
ProjectInformation projectInformation = projectInformationService.lambdaQuery().eq(ProjectInformation::getBusinessNumber, contractInfo.getBusinessNo()).one();
|
|
- if(type.equals(ConstantConversionUtil.SUSHANGGUARANTEECONTRAT)){
|
|
|
|
|
|
+ if (type.equals(ConstantConversionUtil.SUSHANGGUARANTEECONTRAT)) {
|
|
SmbContractInfo smbContractInfo = smbContractInfoService.lambdaQuery()
|
|
SmbContractInfo smbContractInfo = smbContractInfoService.lambdaQuery()
|
|
.eq(SmbContractInfo::getSupplierId, projectInformation.getcSupplierInfoId())
|
|
.eq(SmbContractInfo::getSupplierId, projectInformation.getcSupplierInfoId())
|
|
- .eq(SmbContractInfo::getContractType,2L).one();
|
|
|
|
|
|
+ .eq(SmbContractInfo::getContractType, 2L).one();
|
|
smbContractInfo.setContractElectronicInfoId(contractElectronicInfo.getId());
|
|
smbContractInfo.setContractElectronicInfoId(contractElectronicInfo.getId());
|
|
smbContractInfoService.updateById(smbContractInfo);
|
|
smbContractInfoService.updateById(smbContractInfo);
|
|
}
|
|
}
|
|
- if(type.equals(ConstantConversionUtil.SUSHANGFIRSTCONTRAT)){
|
|
|
|
|
|
+ if (type.equals(ConstantConversionUtil.SUSHANGFIRSTCONTRAT)) {
|
|
SmbContractInfo smbContractInfo = smbContractInfoService.lambdaQuery()
|
|
SmbContractInfo smbContractInfo = smbContractInfoService.lambdaQuery()
|
|
.eq(SmbContractInfo::getSupplierId, projectInformation.getcSupplierInfoId())
|
|
.eq(SmbContractInfo::getSupplierId, projectInformation.getcSupplierInfoId())
|
|
- .eq(SmbContractInfo::getContractType,1L).one();
|
|
|
|
|
|
+ .eq(SmbContractInfo::getContractType, 1L).one();
|
|
smbContractInfo.setContractElectronicInfoId(contractElectronicInfo.getId());
|
|
smbContractInfo.setContractElectronicInfoId(contractElectronicInfo.getId());
|
|
smbContractInfoService.updateById(smbContractInfo);
|
|
smbContractInfoService.updateById(smbContractInfo);
|
|
}
|
|
}
|
|
@@ -1645,7 +1645,9 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
electronicSignaturePersonal.setSocialCreditCode(rltRepay.getArlpCertNum());
|
|
electronicSignaturePersonal.setSocialCreditCode(rltRepay.getArlpCertNum());
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setMobile(rltRepay.getResponsiblePhone());
|
|
electronicSignaturePersonal.setMobile(rltRepay.getResponsiblePhone());
|
|
- sysCustomer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
|
|
+ if (sysCustomer != null) {
|
|
|
|
+ sysCustomer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
+ }
|
|
electronicSignaturePersonalService.updateById(electronicSignaturePersonal);
|
|
electronicSignaturePersonalService.updateById(electronicSignaturePersonal);
|
|
}
|
|
}
|
|
if (sysCustomer != null && sysCustomer.getFddCustomerId() != null) {
|
|
if (sysCustomer != null && sysCustomer.getFddCustomerId() != null) {
|
|
@@ -1660,8 +1662,8 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
electronicSignaturePersonal.setSocialCreditCode(rltRepay.getArlpCertNum());
|
|
electronicSignaturePersonal.setSocialCreditCode(rltRepay.getArlpCertNum());
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setMobile(rltRepay.getResponsiblePhone());
|
|
electronicSignaturePersonal.setMobile(rltRepay.getResponsiblePhone());
|
|
- customer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
}
|
|
}
|
|
|
|
+ customer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
customer.setAccountType("1");
|
|
customer.setAccountType("1");
|
|
sysCustomerService.add(customer);
|
|
sysCustomerService.add(customer);
|
|
ContractElectronicCustomerInfo contractElectronicCustomerInfo = new ContractElectronicCustomerInfo("yf", customer.getFddCustomerId());
|
|
ContractElectronicCustomerInfo contractElectronicCustomerInfo = new ContractElectronicCustomerInfo("yf", customer.getFddCustomerId());
|
|
@@ -1702,7 +1704,9 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
electronicSignaturePersonal.setSocialCreditCode(rltRepay.getArlpCertNum());
|
|
electronicSignaturePersonal.setSocialCreditCode(rltRepay.getArlpCertNum());
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setMobile(rltRepay.getResponsiblePhone());
|
|
electronicSignaturePersonal.setMobile(rltRepay.getResponsiblePhone());
|
|
- sysCustomer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
|
|
+ if (sysCustomer != null) {
|
|
|
|
+ sysCustomer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
+ }
|
|
electronicSignaturePersonalService.updateById(electronicSignaturePersonal);
|
|
electronicSignaturePersonalService.updateById(electronicSignaturePersonal);
|
|
}
|
|
}
|
|
if (sysCustomer != null && sysCustomer.getFddCustomerId() != null) {
|
|
if (sysCustomer != null && sysCustomer.getFddCustomerId() != null) {
|
|
@@ -1717,8 +1721,8 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
electronicSignaturePersonal.setSocialCreditCode(rltRepay.getArlpCertNum());
|
|
electronicSignaturePersonal.setSocialCreditCode(rltRepay.getArlpCertNum());
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setMobile(rltRepay.getResponsiblePhone());
|
|
electronicSignaturePersonal.setMobile(rltRepay.getResponsiblePhone());
|
|
- customer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
}
|
|
}
|
|
|
|
+ customer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
customer.setAccountType("1");
|
|
customer.setAccountType("1");
|
|
sysCustomerService.add(customer);
|
|
sysCustomerService.add(customer);
|
|
ContractElectronicCustomerInfo contractElectronicCustomerInfo = new ContractElectronicCustomerInfo("gut", customer.getFddCustomerId());
|
|
ContractElectronicCustomerInfo contractElectronicCustomerInfo = new ContractElectronicCustomerInfo("gut", customer.getFddCustomerId());
|
|
@@ -1738,7 +1742,9 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
electronicSignaturePersonal.setSocialCreditCode(rltRepay.getSpouseIdCard());
|
|
electronicSignaturePersonal.setSocialCreditCode(rltRepay.getSpouseIdCard());
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setMobile(rltRepay.getResponsiblePhone());
|
|
electronicSignaturePersonal.setMobile(rltRepay.getResponsiblePhone());
|
|
- sysCustomer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
|
|
+ if (sysCustomer != null) {
|
|
|
|
+ sysCustomer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
+ }
|
|
electronicSignaturePersonalService.updateById(electronicSignaturePersonal);
|
|
electronicSignaturePersonalService.updateById(electronicSignaturePersonal);
|
|
}
|
|
}
|
|
if (sysCustomer != null && sysCustomer.getFddCustomerId() != null) {
|
|
if (sysCustomer != null && sysCustomer.getFddCustomerId() != null) {
|
|
@@ -1752,10 +1758,9 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
electronicSignaturePersonal.setName(rltRepay.getSpouseName());
|
|
electronicSignaturePersonal.setName(rltRepay.getSpouseName());
|
|
electronicSignaturePersonal.setSocialCreditCode(rltRepay.getSpouseIdCard());
|
|
electronicSignaturePersonal.setSocialCreditCode(rltRepay.getSpouseIdCard());
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
-
|
|
|
|
electronicSignaturePersonal.setMobile(rltRepay.getResponsiblePhone());
|
|
electronicSignaturePersonal.setMobile(rltRepay.getResponsiblePhone());
|
|
- customer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
}
|
|
}
|
|
|
|
+ customer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
customer.setAccountType("1");
|
|
customer.setAccountType("1");
|
|
sysCustomerService.add(customer);
|
|
sysCustomerService.add(customer);
|
|
ContractElectronicCustomerInfo contractElectronicCustomerInfo = new ContractElectronicCustomerInfo("gut", customer.getFddCustomerId());
|
|
ContractElectronicCustomerInfo contractElectronicCustomerInfo = new ContractElectronicCustomerInfo("gut", customer.getFddCustomerId());
|
|
@@ -1794,7 +1799,9 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
electronicSignaturePersonal.setSocialCreditCode(rltRepay.getArlpCertNum());
|
|
electronicSignaturePersonal.setSocialCreditCode(rltRepay.getArlpCertNum());
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setMobile(rltRepay.getResponsiblePhone());
|
|
electronicSignaturePersonal.setMobile(rltRepay.getResponsiblePhone());
|
|
- sysCustomer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
|
|
+ if (sysCustomer != null) {
|
|
|
|
+ sysCustomer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
+ }
|
|
electronicSignaturePersonalService.updateById(electronicSignaturePersonal);
|
|
electronicSignaturePersonalService.updateById(electronicSignaturePersonal);
|
|
}
|
|
}
|
|
if (sysCustomer != null && sysCustomer.getFddCustomerId() != null) {
|
|
if (sysCustomer != null && sysCustomer.getFddCustomerId() != null) {
|
|
@@ -1809,8 +1816,8 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
electronicSignaturePersonal.setSocialCreditCode(rltRepay.getArlpCertNum());
|
|
electronicSignaturePersonal.setSocialCreditCode(rltRepay.getArlpCertNum());
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setMobile(rltRepay.getResponsiblePhone());
|
|
electronicSignaturePersonal.setMobile(rltRepay.getResponsiblePhone());
|
|
- customer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
}
|
|
}
|
|
|
|
+ customer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
customer.setAccountType("1");
|
|
customer.setAccountType("1");
|
|
sysCustomerService.add(customer);
|
|
sysCustomerService.add(customer);
|
|
ContractElectronicCustomerInfo contractElectronicCustomerInfo = new ContractElectronicCustomerInfo("gut", customer.getFddCustomerId());
|
|
ContractElectronicCustomerInfo contractElectronicCustomerInfo = new ContractElectronicCustomerInfo("gut", customer.getFddCustomerId());
|
|
@@ -1849,7 +1856,9 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
electronicSignaturePersonal.setSocialCreditCode(chattelMortgage.getMortgagorCertNum());
|
|
electronicSignaturePersonal.setSocialCreditCode(chattelMortgage.getMortgagorCertNum());
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setMobile(chattelMortgage.getContactNumber());
|
|
electronicSignaturePersonal.setMobile(chattelMortgage.getContactNumber());
|
|
- sysCustomer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
|
|
+ if (sysCustomer != null) {
|
|
|
|
+ sysCustomer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
+ }
|
|
electronicSignaturePersonalService.updateById(electronicSignaturePersonal);
|
|
electronicSignaturePersonalService.updateById(electronicSignaturePersonal);
|
|
}
|
|
}
|
|
if (sysCustomer != null && sysCustomer.getFddCustomerId() != null) {
|
|
if (sysCustomer != null && sysCustomer.getFddCustomerId() != null) {
|
|
@@ -1864,8 +1873,8 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
electronicSignaturePersonal.setSocialCreditCode(chattelMortgage.getMortgagorCertNum());
|
|
electronicSignaturePersonal.setSocialCreditCode(chattelMortgage.getMortgagorCertNum());
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setMobile(chattelMortgage.getContactNumber());
|
|
electronicSignaturePersonal.setMobile(chattelMortgage.getContactNumber());
|
|
- customer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
}
|
|
}
|
|
|
|
+ customer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
customer.setAccountType("1");
|
|
customer.setAccountType("1");
|
|
sysCustomerService.add(customer);
|
|
sysCustomerService.add(customer);
|
|
ContractElectronicCustomerInfo contractElectronicCustomerInfo = new ContractElectronicCustomerInfo("mtg", customer.getFddCustomerId());
|
|
ContractElectronicCustomerInfo contractElectronicCustomerInfo = new ContractElectronicCustomerInfo("mtg", customer.getFddCustomerId());
|
|
@@ -1904,7 +1913,9 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
electronicSignaturePersonal.setSocialCreditCode(pledgeInfo.getMortgagorCertNum());
|
|
electronicSignaturePersonal.setSocialCreditCode(pledgeInfo.getMortgagorCertNum());
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setMobile(pledgeInfo.getContactNumber());
|
|
electronicSignaturePersonal.setMobile(pledgeInfo.getContactNumber());
|
|
- sysCustomer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
|
|
+ if (sysCustomer != null) {
|
|
|
|
+ sysCustomer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
+ }
|
|
electronicSignaturePersonalService.updateById(electronicSignaturePersonal);
|
|
electronicSignaturePersonalService.updateById(electronicSignaturePersonal);
|
|
}
|
|
}
|
|
if (sysCustomer != null && sysCustomer.getFddCustomerId() != null) {
|
|
if (sysCustomer != null && sysCustomer.getFddCustomerId() != null) {
|
|
@@ -1919,8 +1930,8 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
electronicSignaturePersonal.setSocialCreditCode(pledgeInfo.getMortgagorCertNum());
|
|
electronicSignaturePersonal.setSocialCreditCode(pledgeInfo.getMortgagorCertNum());
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setMobile(pledgeInfo.getContactNumber());
|
|
electronicSignaturePersonal.setMobile(pledgeInfo.getContactNumber());
|
|
- customer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
}
|
|
}
|
|
|
|
+ customer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
customer.setAccountType("1");
|
|
customer.setAccountType("1");
|
|
sysCustomerService.add(customer);
|
|
sysCustomerService.add(customer);
|
|
ContractElectronicCustomerInfo contractElectronicCustomerInfo = new ContractElectronicCustomerInfo("pd", customer.getFddCustomerId());
|
|
ContractElectronicCustomerInfo contractElectronicCustomerInfo = new ContractElectronicCustomerInfo("pd", customer.getFddCustomerId());
|
|
@@ -2098,7 +2109,7 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
contractElectronicCustomerInfos.add(contractElectronicCustomerInfo);
|
|
contractElectronicCustomerInfos.add(contractElectronicCustomerInfo);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
- }else if(templateCode.equals(ConstantConversionUtil.SUSHANGFIRSTCONTRAT)){
|
|
|
|
|
|
+ } else if (templateCode.equals(ConstantConversionUtil.SUSHANGFIRSTCONTRAT)) {
|
|
ProjectInformation projectInformation = projectInformationService.lambdaQuery().eq(ProjectInformation::getBusinessNumber, contractInfo.getBusinessNo()).one();
|
|
ProjectInformation projectInformation = projectInformationService.lambdaQuery().eq(ProjectInformation::getBusinessNumber, contractInfo.getBusinessNo()).one();
|
|
SupplierInfo supplierInfo = supplierInfoService.get(projectInformation.getcSupplierInfoId());
|
|
SupplierInfo supplierInfo = supplierInfoService.get(projectInformation.getcSupplierInfoId());
|
|
Enterprise enterprise = enterpriseService.getById(supplierInfo.getcEnterpriseId());
|
|
Enterprise enterprise = enterpriseService.getById(supplierInfo.getcEnterpriseId());
|
|
@@ -2116,7 +2127,7 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
contractElectronicCustomerInfo.setSysCustomerId(customer.getId());
|
|
contractElectronicCustomerInfo.setSysCustomerId(customer.getId());
|
|
contractElectronicCustomerInfos.add(contractElectronicCustomerInfo);
|
|
contractElectronicCustomerInfos.add(contractElectronicCustomerInfo);
|
|
}
|
|
}
|
|
- }else if(templateCode.equals(ConstantConversionUtil.SUSHANGGUARANTEECONTRAT)){
|
|
|
|
|
|
+ } else if (templateCode.equals(ConstantConversionUtil.SUSHANGGUARANTEECONTRAT)) {
|
|
ProjectInformation projectInformation = projectInformationService.lambdaQuery().eq(ProjectInformation::getBusinessNumber, contractInfo.getBusinessNo()).one();
|
|
ProjectInformation projectInformation = projectInformationService.lambdaQuery().eq(ProjectInformation::getBusinessNumber, contractInfo.getBusinessNo()).one();
|
|
List<FinancingFromInvestorsHistory> financingFromInvestorsHistories = financingFromInvestorsHistoryService.lambdaQuery().eq(FinancingFromInvestorsHistory::getSupplierInfoId, projectInformation.getcSupplierInfoId()).orderByDesc(FinancingFromInvestorsHistory::getId).list();
|
|
List<FinancingFromInvestorsHistory> financingFromInvestorsHistories = financingFromInvestorsHistoryService.lambdaQuery().eq(FinancingFromInvestorsHistory::getSupplierInfoId, projectInformation.getcSupplierInfoId()).orderByDesc(FinancingFromInvestorsHistory::getId).list();
|
|
FinancingFromInvestorsHistory financingFromInvestorsHistory = financingFromInvestorsHistories.get(0);
|
|
FinancingFromInvestorsHistory financingFromInvestorsHistory = financingFromInvestorsHistories.get(0);
|
|
@@ -2131,7 +2142,7 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
electronicSignaturePersonal.setSocialCreditCode(financingFromInvestorsPerson.getSocialCreditCode());
|
|
electronicSignaturePersonal.setSocialCreditCode(financingFromInvestorsPerson.getSocialCreditCode());
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setMobile(financingFromInvestorsPerson.getPhoneNumber());
|
|
electronicSignaturePersonal.setMobile(financingFromInvestorsPerson.getPhoneNumber());
|
|
- if(sysCustomer != null){
|
|
|
|
|
|
+ if (sysCustomer != null) {
|
|
sysCustomer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
sysCustomer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
}
|
|
}
|
|
electronicSignaturePersonalService.updateById(electronicSignaturePersonal);
|
|
electronicSignaturePersonalService.updateById(electronicSignaturePersonal);
|
|
@@ -2149,7 +2160,7 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setMobile(financingFromInvestorsPerson.getPhoneNumber());
|
|
electronicSignaturePersonal.setMobile(financingFromInvestorsPerson.getPhoneNumber());
|
|
customer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
customer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
- }else {
|
|
|
|
|
|
+ } else {
|
|
customer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
customer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
}
|
|
}
|
|
customer.setAccountType("1");
|
|
customer.setAccountType("1");
|
|
@@ -2241,7 +2252,9 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
electronicSignaturePersonal.setSocialCreditCode(uploadContractSignatory.getSocialCreditCode());
|
|
electronicSignaturePersonal.setSocialCreditCode(uploadContractSignatory.getSocialCreditCode());
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setMobile(uploadContractSignatory.getContactNumber());
|
|
electronicSignaturePersonal.setMobile(uploadContractSignatory.getContactNumber());
|
|
- sysCustomer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
|
|
+ if (sysCustomer != null) {
|
|
|
|
+ sysCustomer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
+ }
|
|
electronicSignaturePersonalService.updateById(electronicSignaturePersonal);
|
|
electronicSignaturePersonalService.updateById(electronicSignaturePersonal);
|
|
}
|
|
}
|
|
if (sysCustomer != null && sysCustomer.getFddCustomerId() != null) {
|
|
if (sysCustomer != null && sysCustomer.getFddCustomerId() != null) {
|
|
@@ -2256,8 +2269,8 @@ public class ContractMakingServiceImpl implements ContractMakingService {
|
|
electronicSignaturePersonal.setSocialCreditCode(uploadContractSignatory.getSocialCreditCode());
|
|
electronicSignaturePersonal.setSocialCreditCode(uploadContractSignatory.getSocialCreditCode());
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setCardType("idCard");
|
|
electronicSignaturePersonal.setMobile(uploadContractSignatory.getContactNumber());
|
|
electronicSignaturePersonal.setMobile(uploadContractSignatory.getContactNumber());
|
|
- customer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
|
|
}
|
|
}
|
|
|
|
+ customer.setElectronicSignaturePersonal(electronicSignaturePersonal);
|
|
customer.setAccountType("1");
|
|
customer.setAccountType("1");
|
|
customer = sysCustomerService.add(customer);
|
|
customer = sysCustomerService.add(customer);
|
|
|
|
|