diff --git a/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basemanufacturerbank/BaseManufacturerBankMapper.xml b/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basemanufacturerbank/BaseManufacturerBankMapper.xml
index e6a4ca8925..f68b27e71a 100644
--- a/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basemanufacturerbank/BaseManufacturerBankMapper.xml
+++ b/anrui-base/anrui-base-biz/src/main/java/com/yxt/anrui/base/biz/basemanufacturerbank/BaseManufacturerBankMapper.xml
@@ -147,7 +147,6 @@
bmb.paymentAccessNoValue
FROM base_manufacturer_bank bmb
WHERE bmb.sid = #{sid}
- AND bmb.isDelete = 0
+
+
+
+
\ No newline at end of file
diff --git a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/fincollectionconfirmation/FinCollectionConfirmationService.java b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/fincollectionconfirmation/FinCollectionConfirmationService.java
index 53f243498c..f78a1dc0e8 100644
--- a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/fincollectionconfirmation/FinCollectionConfirmationService.java
+++ b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/fincollectionconfirmation/FinCollectionConfirmationService.java
@@ -88,6 +88,8 @@ import com.yxt.anrui.fin.api.kingdee.FinKingDeeFeign;
import com.yxt.anrui.fin.api.kingdee.arreceivable.ARReceivable;
import com.yxt.anrui.fin.api.kingdee.arreceivebill.ARReceivebill;
import com.yxt.anrui.fin.api.kingdee.bdcustomer.BdCustomer;
+import com.yxt.anrui.fin.api.kingdee.capitalcreditresult.CapitalCreditResult;
+import com.yxt.anrui.fin.api.kingdee.capitalcreditresult.CwSystemYT;
import com.yxt.anrui.fin.biz.finbillapplication.FinBillApplicationService;
import com.yxt.anrui.fin.biz.finbilltrailer.FinBillTrailerService;
import com.yxt.anrui.fin.biz.finbillvehicle.FinBillVehicleService;
@@ -99,6 +101,7 @@ import com.yxt.anrui.fin.biz.finvehicleinvoice.FinVehicleInvoiceService;
import com.yxt.anrui.fin.biz.kingdee.FinKingDeeService;
import com.yxt.anrui.fin.biz.kingdee.arreceivebill.ArReceivebillService;
import com.yxt.anrui.fin.biz.kingdee.bdcustomer.BdCustomerService;
+import com.yxt.anrui.fin.biz.kingdee.capitalcreditresult.OtherReceivableBillCreditResultService;
import com.yxt.anrui.fin.biz.kingdee.receivablebill.ReceivableBillService;
import com.yxt.anrui.portal.api.sysorganization.SysOrganizationFeign;
import com.yxt.anrui.portal.api.sysorganization.SysOrganizationVo;
@@ -110,6 +113,7 @@ import com.yxt.anrui.portal.api.sysuser.SysUserVo;
import com.yxt.anrui.riskcenter.api.loandiff.LoanDiffFeign;
import com.yxt.anrui.riskcenter.api.loandiff.LoanDiffsDto;
import com.yxt.anrui.riskcenter.api.loandiffdetails.LoanDiffDetailssDto;
+import com.yxt.anrui.riskcenter.api.loanfinbank.LoanFinBank;
import com.yxt.anrui.riskcenter.api.loanfinotherPolicy.LoanFinOtherPolicy;
import com.yxt.anrui.riskcenter.api.loanfinpolicy.LoanFinPolicy;
import com.yxt.anrui.riskcenter.api.loansolutions.LoanSolutions;
@@ -192,6 +196,8 @@ public class FinCollectionConfirmationService extends MybatisBaseService createQueryWrapper(FinCollectionConfirmationQuery query) {
// todo: 这里根据具体业务调整查询条件
@@ -1746,8 +1752,31 @@ public class FinCollectionConfirmationService extends MybatisBaseService voList = finSelectedReceivablesDetailedService.selectListByVin2(finUncollectedReceivablesDetailed.getContractNo(), finUncollectedReceivablesDetailed.getBusVinSid(), 3);
+ BigDecimal bigDecimalVinAll = voList.stream().map(FinSelectedReceivablesDetailedVo::getSubscriptionMoney).map(BigDecimal::new).reduce(BigDecimal.ZERO, BigDecimal::add);
+ List unList = finUncollectedReceivablesDetailedService.selectListByBusVinSid2(finUncollectedReceivablesDetailed.getBusVinSid());
+ BigDecimal unDecimalVinAll = unList.stream().map(FinUncollectedReceivablesDetailed::getReveivableMoney).map(BigDecimal::new).reduce(BigDecimal.ZERO, BigDecimal::add);
+ if(bigDecimalVinAll.compareTo(unDecimalVinAll) == 0){//认完
+ if(bigAdd.compareTo(decimalAll) != 0){//不相等,推送放款差额确认待办
+ LoanDiffDetailssDto loanDiffDetailssDto = new LoanDiffDetailssDto();
+ loanDiffDetailssDto.setBankSid(loanFinPolicy.getBankSid());
+ loanDiffDetailssDto.setBankName(loanFinPolicy.getBankShortName());
+ loanDiffDetailssDto.setBorrowName(busSalesOrderVehicle.getBorrowName());
+ loanDiffDetailssDto.setBorrowSid(busSalesOrderVehicle.getBorrowerSid());
+ loanDiffDetailssDto.setMakeLoan(new BigDecimal(finUncollectedReceivablesDetailed.getReveivableMoney()));
+ loanDiffDetailssDto.setRealityLoan(finSelectedReceivablesDetailed.getSubscriptionMoney());
+ loanDiffDetailssDto.setDiffLoan(decimalAll);
+ loanDiffDetailssDto.setMakeDiscount(loanSolutions.getFactoryDiscount());
+ loanDiffDetailssDto.setMakeLoanMargin(loanSolutions.getBondAmount());
+ loanDiffDetailssDto.setMakeOtherDiscount(loanSolutionsOtherpolicy.getOtherDiscount());
+ loanDiffDetailssDto.setReceivedPremium(loanSolutionsDetail.getProxyAccidentPremium());
+ loanDiffDetailssDto.setVinNo(busSalesOrderVehicle.getLinkNo());
+ loanDiffDetailssDto.setVinSid(busSalesOrderVehicle.getLinkSid());
+ loanDiffDetailssDto.setBusVinSid(busSalesOrderVehicle.getSid());
+ loanDiffDetailssDtos.add(loanDiffDetailssDto);
+ }
+ }
}else{
if(bigAdd.compareTo(decimalAll) != 0){//不相等,推送放款差额确认待办
LoanDiffDetailssDto loanDiffDetailssDto = new LoanDiffDetailssDto();
@@ -1766,6 +1795,75 @@ public class FinCollectionConfirmationService extends MybatisBaseService 8) {
+ linkNo = vinNo.substring(vinNo.length() - 8);
+ } else {
+ linkNo = busSalesOrderVehicle.getLinkNo();
+ }
+ bdCustomer.setFName(busSalesOrderVehicle.getBorrowName() + linkNo);
+ } else {
+ bdCustomer.setFName(busSalesOrderVehicle.getBorrowName() + busSalesOrderVehicle.getTemporaryNo());
+ }
+ ResultBean resultBean = bdCustomerService.draftBdCustomer(bdCustomer);
+ if (resultBean.getSuccess()) {
+ customerNumber = bdCustomer.getFNumber();
+ }
+ } else {
+ customerNumber = busSalesOrderVehicle.getTemporaryNo();
+ }
+ creditResult.setCommUnit(customerNumber);
+ SysOrganizationVo sysOrganizationVo1 = sysOrganizationFeign.fetchBySid(busSalesOrder.getUseOrgSid()).getData();
+ creditResult.setCollectionOrg(sysOrganizationVo1.getOrgCode());
+ creditResult.setBussDate(DateUtil.formatDate(new Date()));
+ List collectionDetailDtoListOne = new ArrayList<>();
+ SysOrganizationVo sysOrganizationVo2 = sysOrganizationFeign.fetchBySid(busSalesOrder.getOrgSid()).getData();
+ if (loanSolutions.getBondAmount() != null) {//贷款保证金
+ CapitalCreditResult.CapitalCreditResultDetailDto creditResultDetailDto = new CapitalCreditResult.CapitalCreditResultDetailDto();
+ creditResultDetailDto.setDearDept(sysOrganizationVo2.getOrgCode());
+ creditResultDetailDto.setExTaxMoney("-" + loanSolutions.getBondAmount().toString());
+ creditResultDetailDto.setUseTo(CwSystemYT.BOND_AMOUNTS.getType());
+ collectionDetailDtoListOne.add(creditResultDetailDto);
+ }
+ if (loanSolutions.getFactoryDiscount() != null) {//主产品厂家贴息
+ CapitalCreditResult.CapitalCreditResultDetailDto creditResultDetailDto = new CapitalCreditResult.CapitalCreditResultDetailDto();
+ creditResultDetailDto.setDearDept(sysOrganizationVo2.getOrgCode());
+ creditResultDetailDto.setExTaxMoney("-" + loanSolutions.getFactoryDiscount().toString());
+ creditResultDetailDto.setUseTo(CwSystemYT.SANFANG_TIEXI_DIECHEKUAN.getType());
+ collectionDetailDtoListOne.add(creditResultDetailDto);
+ }
+ if (loanSolutionsOtherpolicy.getOtherDiscount() != null) {//实扣其他融厂家贴息
+ CapitalCreditResult.CapitalCreditResultDetailDto creditResultDetailDto = new CapitalCreditResult.CapitalCreditResultDetailDto();
+ creditResultDetailDto.setDearDept(sysOrganizationVo2.getOrgCode());
+ creditResultDetailDto.setExTaxMoney("-" + loanSolutionsOtherpolicy.getOtherDiscount().toString());
+ creditResultDetailDto.setUseTo(CwSystemYT.SANFANG_TIEXI_DIECHEKUAN.getType());
+ collectionDetailDtoListOne.add(creditResultDetailDto);
+ }
+ if (loanSolutionsDetail.getProxyAccidentPremium() != null) {//已收意外险
+ CapitalCreditResult.CapitalCreditResultDetailDto creditResultDetailDto = new CapitalCreditResult.CapitalCreditResultDetailDto();
+ creditResultDetailDto.setDearDept(sysOrganizationVo2.getOrgCode());
+ creditResultDetailDto.setExTaxMoney("-" + loanSolutionsDetail.getProxyAccidentPremium().toString());
+ creditResultDetailDto.setUseTo(CwSystemYT.PROXY_ACCIDENT_PREMIUM.getType());
+ collectionDetailDtoListOne.add(creditResultDetailDto);
+ }
+ creditResult.setResultDetails(collectionDetailDtoListOne);
+ creditResultService.pushOtherReceivableBill(creditResult);
+
}
}
@@ -1856,6 +1954,8 @@ public class FinCollectionConfirmationService extends MybatisBaseService finSelectedReceivablesDetailedVos3_2 = finSelectedReceivablesDetailedService.fetchByAuditState1_1(sid, "加装配置手续费", "2");
finSelectedReceivablesDetailedVos3_2.removeAll(Collections.singleton(null));
+ List finSelectedReceivablesDetailedVos4_1 = finSelectedReceivablesDetailedService.fetchByAuditState1_1(sid, "融资放款", "2");
+ finSelectedReceivablesDetailedVos4_1.removeAll(Collections.singleton(null));
int carSize = 0;
//全款推送车款
if (finSelectedReceivablesDetailedVos1.size() > 0) {
@@ -1980,6 +2080,23 @@ public class FinCollectionConfirmationService extends MybatisBaseService 0) {
+ boolean one = false;
+ if (finSelectedReceivablesDetailedVos1.size() == 0 &&
+ finSelectedReceivablesDetailedVos1_1_1.size() == 0 &&
+ finSelectedReceivablesDetailedVos2.size() == 0 &&
+ finSelectedReceivablesDetailedVos1_1.size() == 0 &&
+ finSelectedReceivablesDetailedVos2_1.size() == 0 &&
+ finSelectedReceivablesDetailedVos1_1_2.size() == 0 &&
+ finSelectedReceivablesDetailedVos3_1.size() == 0 &&
+ finSelectedReceivablesDetailedVos3_2.size() == 0 &&
+ finSelectedReceivablesDetailedVos4_1.size() == 1) {
+ one = true;
+ }
+ carSize = loanDiff(confirmation, arReceivebill, carSize, finSelectedReceivablesDetailedVos4_1, freceivebillentry, one, orgCode);
+ }
+
//简易订单-订金收取
if (finSelectedReceivablesDetailedVos1.isEmpty() &&
finSelectedReceivablesDetailedVos2.isEmpty() &&
@@ -2026,6 +2143,54 @@ public class FinCollectionConfirmationService extends MybatisBaseService finSelectedReceivablesDetailedVos4_1, ARReceivebill.FRECEIVEBILLENTRY freceivebillentry, boolean one, String orgCode) {
+ String sid = confirmation.getSid();
+ List fEntityList = new ArrayList<>();
+ for (int i = 0; i < finSelectedReceivablesDetailedVos4_1.size(); i++) {
+ FinSelectedReceivablesDetailedVo vvvv = finSelectedReceivablesDetailedVos4_1.get(i);
+ //推送客户
+ String customerNo = createCustomerQuery(2, vvvv, orgCode);
+ //往来单位
+ arReceivebill.setFCONTACTUNIT(customerNo);
+ fEntityList = new ArrayList<>();
+ String uncollSid = "";
+ freceivebillentry = new ARReceivebill.FRECEIVEBILLENTRY();
+ //结算方式
+ freceivebillentry.setFSETTLETYPEIDKey(confirmation.getCollectionTypeKey());
+ freceivebillentry.setFSETTLETYPEIDType("customerPayType");
+ //收款金额
+ freceivebillentry.setFRECTOTALAMOUNTFOR(vvvv.getSubscriptionMoney());
+ //登记日期
+ freceivebillentry.setFPOSTDATE(confirmation.getCollectionDate());
+ if (vvvv.getVIN().length() >= 8) {
+ freceivebillentry.setF_PAEZ_Base1(vvvv.getVIN().substring(vvvv.getVIN().length() - 8));
+ }
+ //收款用途
+ freceivebillentry.setFPURPOSEIDKey("001");
+ freceivebillentry.setFPURPOSEIDType("cw_skyt");
+ freceivebillentry.setFACCOUNTID(confirmation.getCollectionBankNum());
+ LoanFinBank loanFinBank = baseMapper.selectFinBnk(vvvv.getContractNo());
+ if(loanFinBank != null){
+ freceivebillentry.setF_PAEZ_Base(loanFinBank.getBankNo());//资方编码
+ }
+ fEntityList.add(freceivebillentry);
+ uncollSid = vvvv.getReceivablesSid();
+ //项目类别key、value
+ arReceivebill.setF_PAEZ_AssistantType("cw_sklb");
+ arReceivebill.setF_PAEZ_AssistantKey("062");
+ arReceivebill.setFRECEIVEBILLENTRY(fEntityList);
+ if (one) {
+ arReceivebill.setFBillNo(confirmation.getBillNo());
+ } else {
+ //单据编号
+ carSize = carSize + 1;
+ arReceivebill.setFBillNo(confirmation.getBillNo() + "-" + carSize);
+ }
+ ResultBean resultBean1 = arReceivebillService.draftArReceivebill(arReceivebill);
+ }
+ return carSize;
+ }
+
//组装客户推送
private BdCustomer createBdCustomer(String useOrgSid, String name, String mobile, String customerSid, String collSid) {
BdCustomer bdCustomer = new BdCustomer();
diff --git a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finselectedreceivablesdetailed/FinSelectedReceivablesDetailedMapper.java b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finselectedreceivablesdetailed/FinSelectedReceivablesDetailedMapper.java
index 0507c8fce8..c84621f71b 100644
--- a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finselectedreceivablesdetailed/FinSelectedReceivablesDetailedMapper.java
+++ b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finselectedreceivablesdetailed/FinSelectedReceivablesDetailedMapper.java
@@ -98,6 +98,7 @@ public interface FinSelectedReceivablesDetailedMapper extends BaseMapper selectListByVin(@Param("contractNo") String contractNo, @Param("busVinSid") String busVinSid, @Param("state") int state);
List selectListByVin1(@Param("contractNo") String contractNo, @Param("busVinSid") String busVinSid, @Param("state") int state);
+ List selectListByVin2(@Param("contractNo") String contractNo, @Param("busVinSid") String busVinSid, @Param("state") int state);
List getList(@Param("list") List sidsList);
diff --git a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finselectedreceivablesdetailed/FinSelectedReceivablesDetailedMapper.xml b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finselectedreceivablesdetailed/FinSelectedReceivablesDetailedMapper.xml
index 5bf8db855b..d19a97a741 100644
--- a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finselectedreceivablesdetailed/FinSelectedReceivablesDetailedMapper.xml
+++ b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finselectedreceivablesdetailed/FinSelectedReceivablesDetailedMapper.xml
@@ -209,6 +209,27 @@
GROUP BY d.`sid`) d
+
+
@@ -338,6 +338,11 @@
select * from fin_uncollected_receivables_detailed where busVinSid = #{busVinSid} and receivablesName = '首付款及费用'
+
+
update fin_uncollected_receivables_detailed set kxState = #{kxState}
where busVinSid in
diff --git a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finuncollectedreceivablesdetailed/FinUncollectedReceivablesDetailedService.java b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finuncollectedreceivablesdetailed/FinUncollectedReceivablesDetailedService.java
index a070507816..bc8d3e601d 100644
--- a/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finuncollectedreceivablesdetailed/FinUncollectedReceivablesDetailedService.java
+++ b/anrui-fin/anrui-fin-biz/src/main/java/com/yxt/anrui/fin/biz/finuncollectedreceivablesdetailed/FinUncollectedReceivablesDetailedService.java
@@ -1021,6 +1021,10 @@ public class FinUncollectedReceivablesDetailedService extends MybatisBaseService
return baseMapper.selectListByBusVinSid1(busVinSid);
}
+ public List selectListByBusVinSid2(String busVinSid) {
+ return baseMapper.selectListByBusVinSid2(busVinSid);
+ }
+
public ResultBean updateKxState(StateQuery stateQuery) {
ResultBean rb = ResultBean.fireFail();
List busVinSid = stateQuery.getBusVinSid();
diff --git a/anrui-riskcenter/anrui-riskcenter-api/src/main/java/com/yxt/anrui/riskcenter/api/loancustomerrecord/app/AppSelectObject.java b/anrui-riskcenter/anrui-riskcenter-api/src/main/java/com/yxt/anrui/riskcenter/api/loancustomerrecord/app/AppSelectObject.java
index b76c6ea3c3..5d106765be 100644
--- a/anrui-riskcenter/anrui-riskcenter-api/src/main/java/com/yxt/anrui/riskcenter/api/loancustomerrecord/app/AppSelectObject.java
+++ b/anrui-riskcenter/anrui-riskcenter-api/src/main/java/com/yxt/anrui/riskcenter/api/loancustomerrecord/app/AppSelectObject.java
@@ -21,4 +21,5 @@ public class AppSelectObject {
private String legalName;
//地址
private String registDetailAddress;
+ private String realAddress;
}
diff --git a/anrui-riskcenter/anrui-riskcenter-api/src/main/java/com/yxt/anrui/riskcenter/api/loanhomevisitinvestigate/LoanHomeVisitInvestigateInitReportStateVo.java b/anrui-riskcenter/anrui-riskcenter-api/src/main/java/com/yxt/anrui/riskcenter/api/loanhomevisitinvestigate/LoanHomeVisitInvestigateInitReportStateVo.java
index d500a68389..8de082dbff 100644
--- a/anrui-riskcenter/anrui-riskcenter-api/src/main/java/com/yxt/anrui/riskcenter/api/loanhomevisitinvestigate/LoanHomeVisitInvestigateInitReportStateVo.java
+++ b/anrui-riskcenter/anrui-riskcenter-api/src/main/java/com/yxt/anrui/riskcenter/api/loanhomevisitinvestigate/LoanHomeVisitInvestigateInitReportStateVo.java
@@ -9,6 +9,8 @@ public class LoanHomeVisitInvestigateInitReportStateVo implements Vo {
@ApiModelProperty("客户信息")
private int customerState;
+ @ApiModelProperty("其他补充信息")
+ private int otherState;
@ApiModelProperty("订单信息")
private int orderState;
@ApiModelProperty("运营经历")
diff --git a/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiff/LoanDiffMapper.java b/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiff/LoanDiffMapper.java
index 49ef8359fd..c3827afde6 100644
--- a/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiff/LoanDiffMapper.java
+++ b/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiff/LoanDiffMapper.java
@@ -4,6 +4,8 @@ import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.Constants;
+import com.yxt.anrui.buscenter.api.bussalesorder.BusSalesOrder;
+import com.yxt.anrui.buscenter.api.bussalesordervehicle.BusSalesOrderVehicle;
import com.yxt.anrui.riskcenter.api.loandiff.LoanDiff;
import com.yxt.anrui.riskcenter.api.loandiff.LoanDiffVo;
import org.apache.ibatis.annotations.Mapper;
@@ -21,4 +23,8 @@ public interface LoanDiffMapper extends BaseMapper {
int updateFlowFiled(Map map);
IPage listPageVo(IPage page, @Param(Constants.WRAPPER)QueryWrapper qw);
+
+ BusSalesOrderVehicle selectByBusVinSid(String busVinSid);
+
+ BusSalesOrder selectByOrderSid(String salesOrderSid);
}
diff --git a/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiff/LoanDiffMapper.xml b/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiff/LoanDiffMapper.xml
index 0156969b1c..b8522cd2a7 100644
--- a/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiff/LoanDiffMapper.xml
+++ b/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiff/LoanDiffMapper.xml
@@ -36,4 +36,12 @@
order by ld.id desc
+
+
+
+
\ No newline at end of file
diff --git a/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiff/LoanDiffService.java b/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiff/LoanDiffService.java
index f4a9ab61a4..eef32154a0 100644
--- a/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiff/LoanDiffService.java
+++ b/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiff/LoanDiffService.java
@@ -6,7 +6,15 @@ import com.alibaba.fastjson.JSON;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.google.common.util.concurrent.ThreadFactoryBuilder;
+import com.yxt.anrui.base.api.basepurchasesystem.BasePurchaseSystemDetailsVo;
+import com.yxt.anrui.base.api.basepurchasesystem.BasePurchaseSystemFeign;
import com.yxt.anrui.base.api.busvehicleapply.BusVehicleApplyVo;
+import com.yxt.anrui.buscenter.api.bussalesorder.BusSalesOrder;
+import com.yxt.anrui.buscenter.api.bussalesordervehicle.BusSalesOrderVehicle;
+import com.yxt.anrui.fin.api.kingdee.FinKingDeeFeign;
+import com.yxt.anrui.fin.api.kingdee.bdcustomer.BdCustomer;
+import com.yxt.anrui.fin.api.kingdee.capitalcreditresult.CapitalCreditResult;
+import com.yxt.anrui.fin.api.kingdee.capitalcreditresult.CwSystemYT;
import com.yxt.anrui.flowable.api.flow.FlowableFeign;
import com.yxt.anrui.flowable.api.flow.UpdateFlowFieldVo;
import com.yxt.anrui.flowable.api.flow2.FlowDelegateQuery;
@@ -16,11 +24,15 @@ import com.yxt.anrui.flowable.api.flowtask.FlowTaskVo;
import com.yxt.anrui.flowable.api.flowtask.LatestTaskVo;
import com.yxt.anrui.flowable.api.utils.ProcDefEnum;
import com.yxt.anrui.flowable.sqloperationsymbol.BusinessVariables;
+import com.yxt.anrui.portal.api.sysorganization.SysOrganizationFeign;
+import com.yxt.anrui.portal.api.sysorganization.SysOrganizationVo;
import com.yxt.anrui.portal.api.sysuser.PrivilegeQuery;
import com.yxt.anrui.portal.api.sysuser.SysUserFeign;
import com.yxt.anrui.riskcenter.api.loandiff.*;
import com.yxt.anrui.riskcenter.api.loandiff.flowable.*;
import com.yxt.anrui.riskcenter.api.loandiffdetails.*;
+import com.yxt.anrui.riskcenter.api.loansolutions.PushVo;
+import com.yxt.anrui.riskcenter.api.loansolutions.app.SolutionsDetailsVo;
import com.yxt.anrui.riskcenter.api.loantemplate.LoanTemplate;
import com.yxt.anrui.riskcenter.api.loantemplate.LoanTemplateQuery;
import com.yxt.anrui.riskcenter.api.loantemplate.LoanTemplateVo;
@@ -42,6 +54,7 @@ import org.apache.tomcat.util.threads.ThreadPoolExecutor;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
+import java.math.BigDecimal;
import java.util.*;
import java.util.concurrent.*;
import java.util.stream.Collectors;
@@ -70,6 +83,12 @@ public class LoanDiffService extends MybatisBaseService list = loanDiffDetailsService.selectDetailsByMainSid(sid);
+ list.removeAll(Collections.singleton(null));
+ if (!list.isEmpty()) {
+ for (int i = 0; i < list.size(); i++) {
+ CapitalCreditResult creditResult = new CapitalCreditResult();
+ LoanDiffDetails loanDiffDetails = list.get(i);
+ String busVinSid = loanDiffDetails.getBusVinSid();
+ BusSalesOrderVehicle busSalesOrderVehicle = baseMapper.selectByBusVinSid(busVinSid);
+ BusSalesOrder busSalesOrder = baseMapper.selectByOrderSid(busSalesOrderVehicle.getSalesOrderSid());
+ String customerNumber = "";
+ //判断财务系统是否有客户
+ Boolean aBoolean = finKingDeeFeign.customerExistState(busSalesOrderVehicle.getTemporaryNo()).getData();
+ String linkNo = "";
+ if (!aBoolean) {
+ BdCustomer bdCustomer = new BdCustomer();
+ bdCustomer.setFNumber(busSalesOrderVehicle.getTemporaryNo());
+ bdCustomer.setFShortName(busSalesOrder.getContractNo());
+ BasePurchaseSystemDetailsVo data = basePurchaseSystemFeign.fetchDetailsByDeptSid(busSalesOrder.getPurchaseSystemSid()).getData();
+ bdCustomer.setTOrgIds(data.getOrgCode());
+ if (StringUtils.isNotBlank(busSalesOrderVehicle.getLinkNo())) {
+ String vinNo = busSalesOrderVehicle.getLinkNo();
+ if (vinNo.length() > 8) {
+ linkNo = vinNo.substring(vinNo.length() - 8);
+ } else {
+ linkNo = busSalesOrderVehicle.getLinkNo();
+ }
+ bdCustomer.setFName(busSalesOrderVehicle.getBorrowName() + linkNo);
+ } else {
+ bdCustomer.setFName(busSalesOrderVehicle.getBorrowName() + busSalesOrderVehicle.getTemporaryNo());
+ }
+ ResultBean resultBean = finKingDeeFeign.draftBdCustomer(bdCustomer);
+ if (resultBean.getSuccess()) {
+ customerNumber = bdCustomer.getFNumber();
+ }
+ } else {
+ customerNumber = busSalesOrderVehicle.getTemporaryNo();
+ }
+ creditResult.setCommUnit(customerNumber);
+ SysOrganizationVo sysOrganizationVo1 = sysOrganizationFeign.fetchBySid(busSalesOrder.getUseOrgSid()).getData();
+ creditResult.setCollectionOrg(sysOrganizationVo1.getOrgCode());
+ creditResult.setBussDate(DateUtil.formatDate(new Date()));
+ List collectionDetailDtoListOne = new ArrayList<>();
+ SysOrganizationVo sysOrganizationVo2 = sysOrganizationFeign.fetchBySid(busSalesOrder.getOrgSid()).getData();
+ if (loanDiffDetails.getRealityLoan() != null) {//实扣贷款保证金
+ CapitalCreditResult.CapitalCreditResultDetailDto creditResultDetailDto = new CapitalCreditResult.CapitalCreditResultDetailDto();
+ creditResultDetailDto.setDearDept(sysOrganizationVo2.getOrgCode());
+ creditResultDetailDto.setExTaxMoney("-" + loanDiffDetails.getRealityLoanMargin().toString());
+ creditResultDetailDto.setUseTo(CwSystemYT.BOND_AMOUNTS.getType());
+ collectionDetailDtoListOne.add(creditResultDetailDto);
+ }
+ if (loanDiffDetails.getRealityDiscount() != null) {//实扣主产品厂家贴息
+ CapitalCreditResult.CapitalCreditResultDetailDto creditResultDetailDto = new CapitalCreditResult.CapitalCreditResultDetailDto();
+ creditResultDetailDto.setDearDept(sysOrganizationVo2.getOrgCode());
+ creditResultDetailDto.setExTaxMoney("-" + loanDiffDetails.getRealityDiscount().toString());
+ creditResultDetailDto.setUseTo(CwSystemYT.SANFANG_TIEXI_DIECHEKUAN.getType());
+ collectionDetailDtoListOne.add(creditResultDetailDto);
+ }
+ if (loanDiffDetails.getRealityOtherDiscount() != null) {//实扣其他融厂家贴息
+ CapitalCreditResult.CapitalCreditResultDetailDto creditResultDetailDto = new CapitalCreditResult.CapitalCreditResultDetailDto();
+ creditResultDetailDto.setDearDept(sysOrganizationVo2.getOrgCode());
+ creditResultDetailDto.setExTaxMoney("-" + loanDiffDetails.getRealityOtherDiscount().toString());
+ creditResultDetailDto.setUseTo(CwSystemYT.SANFANG_TIEXI_DIECHEKUAN.getType());
+ collectionDetailDtoListOne.add(creditResultDetailDto);
+ }
+ if (loanDiffDetails.getReceivedPremium() != null) {//已收意外险
+ CapitalCreditResult.CapitalCreditResultDetailDto creditResultDetailDto = new CapitalCreditResult.CapitalCreditResultDetailDto();
+ creditResultDetailDto.setDearDept(sysOrganizationVo2.getOrgCode());
+ creditResultDetailDto.setExTaxMoney("-" + loanDiffDetails.getReceivedPremium().toString());
+ creditResultDetailDto.setUseTo(CwSystemYT.PROXY_ACCIDENT_PREMIUM.getType());
+ collectionDetailDtoListOne.add(creditResultDetailDto);
+ }
+ if (loanDiffDetails.getDiffPremium() != null) {//意外险差额
+ CapitalCreditResult.CapitalCreditResultDetailDto creditResultDetailDto = new CapitalCreditResult.CapitalCreditResultDetailDto();
+ creditResultDetailDto.setDearDept(sysOrganizationVo2.getOrgCode());
+ creditResultDetailDto.setExTaxMoney(loanDiffDetails.getDiffPremium().toString());
+ creditResultDetailDto.setUseTo(CwSystemYT.PROXY_ACCIDENT_PREMIUM.getType());
+ collectionDetailDtoListOne.add(creditResultDetailDto);
+ }
+ creditResult.setResultDetails(collectionDetailDtoListOne);
+ finKingDeeFeign.pushOtherReceivableBill(creditResult);
+ }
+ }
+ }
+
public ResultBean> getPreviousNodesForReject(DiffApplyNodeQuery query) {
ResultBean> rb = ResultBean.fireFail();
BusinessVariables bv = new BusinessVariables();
@@ -478,7 +583,7 @@ public class LoanDiffService extends MybatisBaseService loanDiffDetailsList = dto.getLoanDiffDetails();
loanDiffDetailsList.removeAll(Collections.singleton(null));
if (!loanDiffDetailsList.isEmpty()) {
@@ -493,9 +598,9 @@ public class LoanDiffService extends MybatisBaseService fileLists = dto.getFilesList();
fileLists.removeAll(Collections.singleton(null));
if (!fileLists.isEmpty()) {
- List files = fileLists.stream().map(v->v.getUrl()).collect(Collectors.toList());
+ List files = fileLists.stream().map(v -> v.getUrl()).collect(Collectors.toList());
files.removeAll(Collections.singleton(null));
- if(!files.isEmpty()){
+ if (!files.isEmpty()) {
String filss = String.join(",", files).replaceAll(fileUploadComponent.getUrlPrefix(), "");
loanDiff.setFiles(filss);
baseMapper.updateById(loanDiff);
diff --git a/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiffdetails/LoanDiffDetailsMapper.java b/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiffdetails/LoanDiffDetailsMapper.java
index 1dd759ee16..e514c33e9f 100644
--- a/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiffdetails/LoanDiffDetailsMapper.java
+++ b/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiffdetails/LoanDiffDetailsMapper.java
@@ -18,4 +18,6 @@ public interface LoanDiffDetailsMapper extends BaseMapper {
List selectByMainSid(String sid);
List selectByMainSid2(String sid);
+
+ List selectDetailsByMainSid(String sid);
}
diff --git a/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiffdetails/LoanDiffDetailsMapper.xml b/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiffdetails/LoanDiffDetailsMapper.xml
index 2799e41daf..89eb11406a 100644
--- a/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiffdetails/LoanDiffDetailsMapper.xml
+++ b/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiffdetails/LoanDiffDetailsMapper.xml
@@ -29,4 +29,8 @@
from anrui_riskcenter.loan_diff_details
where mainSid = #{sid}
+
+
\ No newline at end of file
diff --git a/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiffdetails/LoanDiffDetailsService.java b/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiffdetails/LoanDiffDetailsService.java
index df06b47866..02c2dc8c2a 100644
--- a/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiffdetails/LoanDiffDetailsService.java
+++ b/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loandiffdetails/LoanDiffDetailsService.java
@@ -24,4 +24,8 @@ public class LoanDiffDetailsService extends MybatisBaseService selectByMainSid2(String sid) {
return baseMapper.selectByMainSid2(sid);
}
+
+ public List selectDetailsByMainSid(String sid) {
+ return baseMapper.selectDetailsByMainSid(sid);
+ }
}
diff --git a/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanhomevisitinvestigate/LoanHomevisitInvestigateService.java b/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanhomevisitinvestigate/LoanHomevisitInvestigateService.java
index 80bdc1e186..ce35cecfde 100644
--- a/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanhomevisitinvestigate/LoanHomevisitInvestigateService.java
+++ b/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanhomevisitinvestigate/LoanHomevisitInvestigateService.java
@@ -396,6 +396,12 @@ public class LoanHomevisitInvestigateService extends MybatisBaseService userInfo = new ArrayList<>();
+ List otherInfo = new ArrayList<>();
if (loanHomevisitInvestigateCustomerDetailsVo != null) {
FinanceForm financeForm1 = new FinanceForm();
financeForm1.setValue("借款人");
@@ -1418,6 +1425,58 @@ public class LoanHomevisitInvestigateService extends MybatisBaseService yYInfo = new ArrayList<>();
diff --git a/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanhomevisitprep/LoanHomevisitPrepService.java b/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanhomevisitprep/LoanHomevisitPrepService.java
index 1e4d0dfaac..11a7b32897 100644
--- a/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanhomevisitprep/LoanHomevisitPrepService.java
+++ b/anrui-riskcenter/anrui-riskcenter-biz/src/main/java/com/yxt/anrui/riskcenter/biz/loanhomevisitprep/LoanHomevisitPrepService.java
@@ -360,10 +360,10 @@ public class LoanHomevisitPrepService extends MybatisBaseService filesList = new ArrayList<>();
//贷款人生成车辆买卖合同
- List xcmmContractUrls = commonContractFeign.xcmmContract(printConfirmDto).getData();
+ /* List xcmmContractUrls = commonContractFeign.xcmmContract(printConfirmDto).getData();
for (File xcmmContractUrl : xcmmContractUrls) {
filesList.add(xcmmContractUrl);
- }
+ }*/
if (conSetUpKey.equals("001")) {//一车一合同
for (BusSalesOrderVehicle busSalesOrderVehicle : busSalesOrderVehicles) {
List salesOrderVehicles = new ArrayList<>();
@@ -390,7 +390,7 @@ public class LoanHomevisitPrepService extends MybatisBaseService salesOrderVehicles = new ArrayList<>();
@@ -450,7 +450,7 @@ public class LoanHomevisitPrepService extends MybatisBaseService 0) {
diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehicleenterlibrary/ScmVehicleEnterlibraryService.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehicleenterlibrary/ScmVehicleEnterlibraryService.java
index 09797b954a..4bdc22b34e 100644
--- a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehicleenterlibrary/ScmVehicleEnterlibraryService.java
+++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehicleenterlibrary/ScmVehicleEnterlibraryService.java
@@ -504,6 +504,8 @@ public class ScmVehicleEnterlibraryService extends MybatisBaseService list = new ArrayList<>();
list.add(baseVehicleDto);
baseVehicleFeign.saveOrUpdate(list, OperVehicleState.EventType.WC_SAVEVEH.getCode());
diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loancustomerrecord/SelectObject.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loancustomerrecord/SelectObject.java
index 145bcbca36..a4c459be08 100644
--- a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loancustomerrecord/SelectObject.java
+++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loancustomerrecord/SelectObject.java
@@ -22,5 +22,5 @@ public class SelectObject {
private String legalName;
//地址
private String registDetailAddress;
-
+ private String realAddress;
}
diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loanhomevisitinvestigate/AppLoanHomeVisitInvestigateDetailsVo.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loanhomevisitinvestigate/AppLoanHomeVisitInvestigateDetailsVo.java
index 94486a75a8..ffc1a5ce43 100644
--- a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loanhomevisitinvestigate/AppLoanHomeVisitInvestigateDetailsVo.java
+++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loanhomevisitinvestigate/AppLoanHomeVisitInvestigateDetailsVo.java
@@ -22,6 +22,8 @@ public class AppLoanHomeVisitInvestigateDetailsVo implements Vo {
private List zCInfo;
@ApiModelProperty("订单信息")
private List orderInfo;
+ @ApiModelProperty("其他补充信息")
+ private List otherInfo;
@ApiModelProperty("通过/不通过")
private String agree;
@ApiModelProperty("意见")
diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loanhomevisitinvestigate/AppLoanHomeVisitInvestigateInitOtherVo.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loanhomevisitinvestigate/AppLoanHomeVisitInvestigateInitOtherVo.java
new file mode 100644
index 0000000000..a11d95e7cd
--- /dev/null
+++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loanhomevisitinvestigate/AppLoanHomeVisitInvestigateInitOtherVo.java
@@ -0,0 +1,29 @@
+package com.yxt.anrui.terminal.api.risk.loanhomevisitinvestigate;
+
+import com.yxt.common.core.vo.Vo;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+
+import java.util.List;
+
+@Data
+public class AppLoanHomeVisitInvestigateInitOtherVo implements Vo {
+
+ private String sid;
+ @ApiModelProperty("1客户下 2挂靠公司下")
+ private String isGK;
+ @ApiModelProperty("是否担保(1是0否)")
+ private String isDb;
+ @ApiModelProperty("挂靠公司名称")
+ private String disName;
+ @ApiModelProperty("挂靠公司统一社会信用代码")
+ private String registNum;
+ @ApiModelProperty("挂靠公司负责人")
+ private String contract;
+ @ApiModelProperty("挂靠公司电话")
+ private String mobile2;
+ @ApiModelProperty("注册地址")
+ private String registDetailAddress;
+ @ApiModelProperty("实际经营地址")
+ private String realAddress;
+}
diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loanhomevisitinvestigate/AppLoanHomeVisitInvestigateInitReportStateVo.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loanhomevisitinvestigate/AppLoanHomeVisitInvestigateInitReportStateVo.java
index b585dcb6c4..2d5335cb89 100644
--- a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loanhomevisitinvestigate/AppLoanHomeVisitInvestigateInitReportStateVo.java
+++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loanhomevisitinvestigate/AppLoanHomeVisitInvestigateInitReportStateVo.java
@@ -9,6 +9,8 @@ public class AppLoanHomeVisitInvestigateInitReportStateVo implements Vo {
@ApiModelProperty("客户信息")
private String customerState;
+ @ApiModelProperty("其他补充信息")
+ private String otherState;
@ApiModelProperty("订单信息")
private String orderState;
@ApiModelProperty("运营经历")
diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loanhomevisitinvestigate/AppLoanHomeVisitInvestigateSaveOtherDto.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loanhomevisitinvestigate/AppLoanHomeVisitInvestigateSaveOtherDto.java
new file mode 100644
index 0000000000..58602957b3
--- /dev/null
+++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loanhomevisitinvestigate/AppLoanHomeVisitInvestigateSaveOtherDto.java
@@ -0,0 +1,30 @@
+package com.yxt.anrui.terminal.api.risk.loanhomevisitinvestigate;
+
+import com.yxt.common.core.dto.Dto;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+
+import java.util.ArrayList;
+import java.util.List;
+
+@Data
+public class AppLoanHomeVisitInvestigateSaveOtherDto implements Dto {
+
+ private String sid;
+ @ApiModelProperty("1客户下 2挂靠公司下")
+ private String isGK;
+ @ApiModelProperty("是否担保")
+ private String isDb;
+ @ApiModelProperty("挂靠公司名称")
+ private String disName;
+ @ApiModelProperty("挂靠公司统一社会信用代码")
+ private String registNum;
+ @ApiModelProperty("挂靠公司负责人")
+ private String contract;
+ @ApiModelProperty("挂靠公司电话")
+ private String mobile2;
+ @ApiModelProperty("注册地址")
+ private String registDetailAddress;
+ @ApiModelProperty("实际经营地址")
+ private String realAddress;
+}
diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loanhomevisitinvestigate/LoanHomeVisitInvestigateFeign.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loanhomevisitinvestigate/LoanHomeVisitInvestigateFeign.java
index 6888df6084..3f527c6ea5 100644
--- a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loanhomevisitinvestigate/LoanHomeVisitInvestigateFeign.java
+++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/risk/loanhomevisitinvestigate/LoanHomeVisitInvestigateFeign.java
@@ -74,6 +74,16 @@ public interface LoanHomeVisitInvestigateFeign {
@ResponseBody
public ResultBean saveHomeVisitCustomerInfo(@Valid @RequestBody AppLoanHomeVisitInvestigateSaveCustomerDto dto);
+ @ApiOperation("初始化其他补充信息")
+ @GetMapping("/getHomeVisitOhterInfo")
+ @ResponseBody
+ public ResultBean getHomeVisitOhterInfo(@RequestParam("sid") String sid);
+
+ @ApiOperation("保存其他补充信息")
+ @PostMapping("/saveHomeVisitOherInfo")
+ @ResponseBody
+ public ResultBean saveHomeVisitOherInfo(@Valid @RequestBody AppLoanHomeVisitInvestigateSaveOtherDto dto);
+
@ApiOperation("初始化家访考察订单信息")
@GetMapping("/getHomeVisitOrderInfo")
@ResponseBody
diff --git a/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/risk/loanhomevisitinvestigate/LoanHomeVisitInvestigateRest.java b/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/risk/loanhomevisitinvestigate/LoanHomeVisitInvestigateRest.java
index b7b7be772f..97a657d1f8 100644
--- a/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/risk/loanhomevisitinvestigate/LoanHomeVisitInvestigateRest.java
+++ b/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/risk/loanhomevisitinvestigate/LoanHomeVisitInvestigateRest.java
@@ -89,6 +89,16 @@ public class LoanHomeVisitInvestigateRest implements LoanHomeVisitInvestigateFei
return loanHomeVisitInvestigateService.saveHomeVisitCustomerInfo(dto);
}
+ @Override
+ public ResultBean getHomeVisitOhterInfo(String sid) {
+ return loanHomeVisitInvestigateService.getHomeVisitOhterInfo(sid);
+ }
+
+ @Override
+ public ResultBean saveHomeVisitOherInfo(AppLoanHomeVisitInvestigateSaveOtherDto dto) {
+ return loanHomeVisitInvestigateService.saveHomeVisitOherInfo(dto);
+ }
+
@Override
public ResultBean getHomeVisitOrderInfo(String sid) {
return loanHomeVisitInvestigateService.getHomeVisitOrderInfo(sid);
diff --git a/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/risk/loanhomevisitinvestigate/LoanHomeVisitInvestigateService.java b/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/risk/loanhomevisitinvestigate/LoanHomeVisitInvestigateService.java
index 9983cd44cb..422fd417c0 100644
--- a/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/risk/loanhomevisitinvestigate/LoanHomeVisitInvestigateService.java
+++ b/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/risk/loanhomevisitinvestigate/LoanHomeVisitInvestigateService.java
@@ -37,6 +37,8 @@ import com.yxt.anrui.riskcenter.api.loanhomevisitinvestigateoperations.LoanHomeV
import com.yxt.anrui.riskcenter.api.loanhomevisitinvestigateoperations.LoanHomeVisitInvestigateInitOperVo;
import com.yxt.anrui.riskcenter.api.loanhomevisitinvestigateorder.LoanHomeVisitInvestigateSaveOrderDto;
import com.yxt.anrui.riskcenter.api.loanhomevisitinvestigateorder.LoanHomeVisitInvestigateInitOrderVo;
+import com.yxt.anrui.riskcenter.api.loanhomevisitinvestigateotherpeo.LoanHomeVisitInvestigateInitOtherPeoVo;
+import com.yxt.anrui.riskcenter.api.loanhomevisitinvestigateotherpeo.LoanHomeVisitInvestigateSaveOtherPeoDto;
import com.yxt.anrui.riskcenter.api.loanhomevisitinvestigateproperty.LoanHomeVisitInvestigateSavePropDto;
import com.yxt.anrui.riskcenter.api.loanhomevisitinvestigateproperty.LoanHomeVisitInvestigateInitPropVo;
import com.yxt.anrui.riskcenter.api.loanhomevisitinvestigatetransport.LoanHomeVisitInvestigateSaveTranDto;
@@ -201,6 +203,65 @@ public class LoanHomeVisitInvestigateService {
return rb.success();
}
+ public ResultBean getHomeVisitOhterInfo(String sid) {
+ ResultBean rb = ResultBean.fireFail();
+ LoanHomeVisitInvestigateInitCustomerVo data = loanHomevisitInvestigateFeign.getHomeVisitCustomerInfo(sid).getData();
+ AppLoanHomeVisitInvestigateInitOtherVo appLoanHomeVisitInvestigateInitOtherVo = new AppLoanHomeVisitInvestigateInitOtherVo();
+ if (data != null){
+ appLoanHomeVisitInvestigateInitOtherVo.setSid(sid);
+ appLoanHomeVisitInvestigateInitOtherVo.setIsGK(data.getVehRegis());
+ if ("0".equals(data.getIsSecurity())){
+ appLoanHomeVisitInvestigateInitOtherVo.setIsDb("1");
+ }else if ("1".equals(data.getIsSecurity())){
+ appLoanHomeVisitInvestigateInitOtherVo.setIsDb("0");
+ }
+ appLoanHomeVisitInvestigateInitOtherVo.setDisName(data.getAccCompName());
+ appLoanHomeVisitInvestigateInitOtherVo.setRegistNum(data.getAccCompRegistNum());
+ appLoanHomeVisitInvestigateInitOtherVo.setContract(data.getAccCompContract());
+ appLoanHomeVisitInvestigateInitOtherVo.setMobile2(data.getMobile());
+ appLoanHomeVisitInvestigateInitOtherVo.setRegistDetailAddress(data.getAccCompAddress());
+ appLoanHomeVisitInvestigateInitOtherVo.setRealAddress(data.getAccCompxAddress());
+ }else {
+ return rb.setMsg("请优先完善客户信息");
+ }
+ return rb.success().setData(appLoanHomeVisitInvestigateInitOtherVo);
+ }
+
+ public ResultBean saveHomeVisitOherInfo(AppLoanHomeVisitInvestigateSaveOtherDto dto) {
+ ResultBean rb = ResultBean.fireFail();
+ LoanHomeVisitInvestigateSaveCustomerDto loanHomeVisitInvestigateSaveCustomerDto = new LoanHomeVisitInvestigateSaveCustomerDto();
+ LoanHomeVisitInvestigateInitCustomerVo data = loanHomevisitInvestigateFeign.getHomeVisitCustomerInfo(dto.getSid()).getData();
+ if (data != null){
+ BeanUtil.copyProperties(data,loanHomeVisitInvestigateSaveCustomerDto);
+ List otherPersonnel = data.getOtherPersonnel();
+ List loanHomeVisitInvestigateSaveOtherPeoDtos = new ArrayList<>();
+ if (otherPersonnel != null && otherPersonnel.size() > 0){
+ for (LoanHomeVisitInvestigateInitOtherPeoVo loanHomeVisitInvestigateInitOtherPeoVo : otherPersonnel) {
+ LoanHomeVisitInvestigateSaveOtherPeoDto loanHomeVisitInvestigateSaveOtherPeoDto = new LoanHomeVisitInvestigateSaveOtherPeoDto();
+ BeanUtil.copyProperties(loanHomeVisitInvestigateInitOtherPeoVo,loanHomeVisitInvestigateSaveOtherPeoDto);
+ loanHomeVisitInvestigateSaveOtherPeoDtos.add(loanHomeVisitInvestigateSaveOtherPeoDto);
+ }
+ loanHomeVisitInvestigateSaveCustomerDto.setOtherPersonnel(loanHomeVisitInvestigateSaveOtherPeoDtos);
+ }
+ loanHomeVisitInvestigateSaveCustomerDto.setVehRegis(dto.getIsGK());
+ if ("0".equals(dto.getIsDb())){
+ loanHomeVisitInvestigateSaveCustomerDto.setIsSecurity("1");
+ }else if ("1".equals(dto.getIsDb())){
+ loanHomeVisitInvestigateSaveCustomerDto.setIsSecurity("0");
+ }
+ loanHomeVisitInvestigateSaveCustomerDto.setAccCompName(dto.getDisName());
+ loanHomeVisitInvestigateSaveCustomerDto.setAccCompRegistNum(dto.getRegistNum());
+ loanHomeVisitInvestigateSaveCustomerDto.setAccCompContract(dto.getContract());
+ loanHomeVisitInvestigateSaveCustomerDto.setMobile(dto.getMobile2());
+ loanHomeVisitInvestigateSaveCustomerDto.setAccCompAddress(dto.getRegistDetailAddress());
+ loanHomeVisitInvestigateSaveCustomerDto.setAccCompxAddress(dto.getRealAddress());
+ }else {
+ return rb.setMsg("请优先完善客户信息");
+ }
+ loanHomevisitInvestigateFeign.saveHomeVisitCustomerInfo(loanHomeVisitInvestigateSaveCustomerDto);
+ return rb.success();
+ }
+
public ResultBean getHomeVisitOrderInfo(String sid) {
ResultBean rb = ResultBean.fireFail();
LoanHomeVisitInvestigateInitOrderVo data = loanHomevisitInvestigateFeign.getHomeVisitOrderInfo(sid).getData();