Browse Source

客户信息中如果借款人不是实际购车人,其他人员中必须有一个是实际购车人才可以保存。

证明文件:担保人联动考察报告的客户信息的实际购车人。
资产类除了车辆其他必填,可以后续上传不用必须现场照片。填写不完整的可以保存,但不能点击考察意见的通过按钮,需要提醒需要先完善考察信息。
zhanglei
God 2 years ago
parent
commit
9a076179f3
  1. 50
      anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanhomevisitinvestigate/LoanHomevisitInvestigateService.java

50
anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanhomevisitinvestigate/LoanHomevisitInvestigateService.java

@ -398,25 +398,25 @@ public class LoanHomevisitInvestigateService extends MybatisBaseService<LoanHome
if (loanHomevisitInvestigateCustomerDetailsVo == null) {
loanHomeVisitInvestigateInitReportStateVo.setCustomerState(0);
} else {
if (StringUtils.isBlank(loanHomevisitInvestigateCustomerDetailsVo.getBankCardNo())){
if (StringUtils.isBlank(loanHomevisitInvestigateCustomerDetailsVo.getBankCardNo())) {
loanHomeVisitInvestigateInitReportStateVo.setCustomerState(0);
}else {
} else {
loanHomeVisitInvestigateInitReportStateVo.setCustomerState(1);
}
//其他补充信息状态
if ("1".equals(loanHomevisitInvestigateCustomerDetailsVo.getVehRegis())){
if ("1".equals(loanHomevisitInvestigateCustomerDetailsVo.getVehRegis())) {
loanHomeVisitInvestigateInitReportStateVo.setOtherState(1);
}else if ("2".equals(loanHomevisitInvestigateCustomerDetailsVo.getVehRegis())){
if (StringUtils.isBlank(loanHomevisitInvestigateCustomerDetailsVo.getIsSecurity()) || StringUtils.isBlank(loanHomevisitInvestigateCustomerDetailsVo.getAccCompName()) || StringUtils.isBlank(loanHomevisitInvestigateCustomerDetailsVo.getAccCompRegistNum())){
} else if ("2".equals(loanHomevisitInvestigateCustomerDetailsVo.getVehRegis())) {
if (StringUtils.isBlank(loanHomevisitInvestigateCustomerDetailsVo.getIsSecurity()) || StringUtils.isBlank(loanHomevisitInvestigateCustomerDetailsVo.getAccCompName()) || StringUtils.isBlank(loanHomevisitInvestigateCustomerDetailsVo.getAccCompRegistNum())) {
loanHomeVisitInvestigateInitReportStateVo.setOtherState(0);
}else {
} else {
loanHomeVisitInvestigateInitReportStateVo.setOtherState(1);
}
}else {
} else {
loanHomeVisitInvestigateInitReportStateVo.setOtherState(0);
}
//合同路径
if (StringUtils.isNotBlank(loanHomevisitInvestigateCustomerDetailsVo.getContractUrl())){
if (StringUtils.isNotBlank(loanHomevisitInvestigateCustomerDetailsVo.getContractUrl())) {
loanHomeVisitInvestigateInitReportStateVo.setDownloadUrl(docPdfComponent.getPrefixTemplateUrl() + loanHomevisitInvestigateCustomerDetailsVo.getContractUrl());
}
}
@ -536,6 +536,8 @@ public class LoanHomevisitInvestigateService extends MybatisBaseService<LoanHome
//资产类
if (yhkImages == null || yhkImages.size() == 0) {
loanHomeVisitInvestigateInitInformationStateVo.setAssetsInfo(0);
} else if (fcImages == null || fcImages.size() == 0) {
loanHomeVisitInvestigateInitInformationStateVo.setAssetsInfo(0);
} else {
loanHomeVisitInvestigateInitInformationStateVo.setAssetsInfo(1);
}
@ -549,10 +551,10 @@ public class LoanHomevisitInvestigateService extends MybatisBaseService<LoanHome
loanHomeVisitInvestigateInitCustomerVo = new LoanHomeVisitInvestigateInitCustomerVo();
String saleOrderBorrowerSid = "";
LoanHomevisitInvestigate loanHomevisitInvestigate = fetchBySid(sid);
if (loanHomevisitInvestigate == null){
if (loanHomevisitInvestigate == null) {
LoanHomevisitPrep loanHomevisitPrep = loanHomevisitPrepService.fetchBySid(sid);
saleOrderBorrowerSid = loanHomevisitPrep.getSaleOrderBorrowerSid();
}else {
} else {
saleOrderBorrowerSid = loanHomevisitInvestigate.getSaleOrderBorrowerSid();
}
BusSalesOrderBorrowerDetailsVo busSalesOrderBorrowerDetailsVo = busSalesOrderBorrowerFeign.fetchDetailsBySid(saleOrderBorrowerSid).getData();
@ -583,6 +585,20 @@ public class LoanHomevisitInvestigateService extends MybatisBaseService<LoanHome
public ResultBean saveHomeVisitCustomerInfo(LoanHomeVisitInvestigateSaveCustomerDto dto) {
ResultBean rb = ResultBean.fireFail();
List<LoanHomeVisitInvestigateSaveOtherPeoDto> otherPersonnel = dto.getOtherPersonnel();
if (!dto.getActualBuyer()) {
Boolean isExistSjgcr = false;
if (otherPersonnel != null && otherPersonnel.size() > 0) {
for (LoanHomeVisitInvestigateSaveOtherPeoDto loanHomeVisitInvestigateSaveOtherPeoDto : otherPersonnel) {
if ("3".equals(loanHomeVisitInvestigateSaveOtherPeoDto.getPersonnelKey())) {
isExistSjgcr = true;
break;
}
}
}
if (!isExistSjgcr) {
return rb.setMsg("贷款人和其他人员中必须存在实际购车人");
}
}
List<String> bankCardImages = dto.getBankCardImages();
LoanHomevisitInvestigateCustomerDto loanHomevisitInvestigateCustomerDto = new LoanHomevisitInvestigateCustomerDto();
LoanHomevisitInvestigateCustomerDetailsVo loanHomevisitInvestigateCustomerDetailsVo = loanHomevisitInvestigateCustomerService.selByMainSid(dto.getSid());
@ -1014,9 +1030,9 @@ public class LoanHomevisitInvestigateService extends MybatisBaseService<LoanHome
}
}
List<LoanHomeVisitInvestigateInitOtherPeoVo> loanHomeVisitInvestigateInitOtherPeoVos = loanHomevisitInvestigateOtherpeoService.selByMainSid(sid);
if (loanHomeVisitInvestigateInitOtherPeoVos != null && loanHomeVisitInvestigateInitOtherPeoVos.size() > 0){
if (loanHomeVisitInvestigateInitOtherPeoVos != null && loanHomeVisitInvestigateInitOtherPeoVos.size() > 0) {
for (LoanHomeVisitInvestigateInitOtherPeoVo loanHomeVisitInvestigateInitOtherPeoVo : loanHomeVisitInvestigateInitOtherPeoVos) {
if ("1".equals(loanHomeVisitInvestigateInitOtherPeoVo.getPersonnelKey())){
if ("1".equals(loanHomeVisitInvestigateInitOtherPeoVo.getPersonnelKey())) {
//担保人身份证
List<LoanHomevisitInvestigateFileDetailsVo> dbrsfzImages = loanHomevisitInvestigateFileService.selByMainSidAndTypeKey(sid, LoanAttachTypeEnum.DBRSFZ.getAttachType());
List<String> pohkbImage = new ArrayList<>();
@ -1451,12 +1467,12 @@ public class LoanHomevisitInvestigateService extends MybatisBaseService<LoanHome
financeForm25.setValue("关系:" + loanHomevisitInvestigateCustomerDetailsVo.getRelationshipValue());
userInfo.add(financeForm25);
}
if ("1".equals(loanHomevisitInvestigateCustomerDetailsVo.getVehRegis())){
if ("1".equals(loanHomevisitInvestigateCustomerDetailsVo.getVehRegis())) {
FinanceForm financeForm60 = new FinanceForm();
financeForm60.setValue("车辆登记在:客户下");
financeForm60.setSpanSize(2);
otherInfo.add(financeForm60);
}else if ("2".equals(loanHomevisitInvestigateCustomerDetailsVo.getVehRegis())){
} else if ("2".equals(loanHomevisitInvestigateCustomerDetailsVo.getVehRegis())) {
FinanceForm financeForm61 = new FinanceForm();
financeForm61.setValue("车辆登记在:挂靠公司下");
financeForm61.setSpanSize(2);
@ -1467,12 +1483,12 @@ public class LoanHomevisitInvestigateService extends MybatisBaseService<LoanHome
financeForm62.setType(1);
financeForm62.setBold(true);
otherInfo.add(financeForm62);
if ("0".equals(loanHomevisitInvestigateCustomerDetailsVo.getIsSecurity())){
if ("0".equals(loanHomevisitInvestigateCustomerDetailsVo.getIsSecurity())) {
FinanceForm financeForm63 = new FinanceForm();
financeForm63.setValue("挂靠公司是否担保:是");
financeForm63.setSpanSize(2);
otherInfo.add(financeForm63);
}else if ("1".equals(loanHomevisitInvestigateCustomerDetailsVo.getIsSecurity())){
} else if ("1".equals(loanHomevisitInvestigateCustomerDetailsVo.getIsSecurity())) {
FinanceForm financeForm64 = new FinanceForm();
financeForm64.setValue("挂靠公司是否担保:否");
financeForm64.setSpanSize(2);
@ -1836,7 +1852,7 @@ public class LoanHomevisitInvestigateService extends MybatisBaseService<LoanHome
}
public void updateState(String sid, String state) {
baseMapper.updateState(sid,state);
baseMapper.updateState(sid, state);
}
public ResultBean<String> getToDoNum(RiskToDoNumQuery riskToDoNumQuery) {

Loading…
Cancel
Save