|
|
@ -4,11 +4,16 @@ import com.baomidou.mybatisplus.core.metadata.IPage; |
|
|
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
|
|
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
|
|
|
import com.daqing.financial.guarantee.feign.HrmsFeignService; |
|
|
|
import com.daqing.financial.guarantee.feign.HrmsFeignService; |
|
|
|
import com.daqing.financial.guarantee.mapper.DgComplianceInvestigationMapper; |
|
|
|
import com.daqing.financial.guarantee.mapper.DgComplianceInvestigationMapper; |
|
|
|
|
|
|
|
import com.daqing.financial.guarantee.mapper.DgGuaranteeAssignUserMapper; |
|
|
|
import com.daqing.financial.guarantee.model.request.DgComplianceInvestigationRequest; |
|
|
|
import com.daqing.financial.guarantee.model.request.DgComplianceInvestigationRequest; |
|
|
|
|
|
|
|
import com.daqing.financial.guarantee.model.response.AssetsDetailResponse; |
|
|
|
|
|
|
|
import com.daqing.financial.guarantee.model.response.DgComplianceInvestigationInfoResponse; |
|
|
|
import com.daqing.financial.guarantee.model.response.DgComplianceInvestigationResponse; |
|
|
|
import com.daqing.financial.guarantee.model.response.DgComplianceInvestigationResponse; |
|
|
|
|
|
|
|
import com.daqing.financial.guarantee.model.response.GuaranteeDetailResponse; |
|
|
|
|
|
|
|
import com.daqing.financial.guarantee.service.IDgAssetsInvestigationService; |
|
|
|
import com.daqing.financial.guarantee.service.IDgComplianceInvestigationService; |
|
|
|
import com.daqing.financial.guarantee.service.IDgComplianceInvestigationService; |
|
|
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
|
|
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
|
|
|
import com.daqing.financial.guarantee.util.AuditProcessUtil; |
|
|
|
import com.daqing.financial.guarantee.service.IDgGuaranteeAssignUserService; |
|
|
|
import com.daqing.framework.domain.crms.response.CrmsCode; |
|
|
|
import com.daqing.framework.domain.crms.response.CrmsCode; |
|
|
|
import com.daqing.framework.domain.guarantee.DgComplianceInvestigation; |
|
|
|
import com.daqing.framework.domain.guarantee.DgComplianceInvestigation; |
|
|
|
import com.daqing.framework.domain.guarantee.DgWorkConferenceConsider; |
|
|
|
import com.daqing.framework.domain.guarantee.DgWorkConferenceConsider; |
|
|
@ -49,6 +54,15 @@ public class DgComplianceInvestigationServiceImpl extends ServiceImpl<DgComplian |
|
|
|
@Autowired |
|
|
|
@Autowired |
|
|
|
private HrmsFeignService hrmsFeignService; |
|
|
|
private HrmsFeignService hrmsFeignService; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Autowired |
|
|
|
|
|
|
|
private DgGuaranteeAssignUserMapper dgGuaranteeAssignUserMapper; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Autowired |
|
|
|
|
|
|
|
private IDgGuaranteeAssignUserService guaranteeAssignUserService; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Autowired |
|
|
|
|
|
|
|
private IDgAssetsInvestigationService dgAssetsInvestigationService; |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 列表 |
|
|
|
* 列表 |
|
|
|
*/ |
|
|
|
*/ |
|
|
@ -131,6 +145,9 @@ public class DgComplianceInvestigationServiceImpl extends ServiceImpl<DgComplian |
|
|
|
if (fileUrl == null || fileUrl.length() == 0) { |
|
|
|
if (fileUrl == null || fileUrl.length() == 0) { |
|
|
|
ExceptionCast.cast(GuaranteeCode.COMPLIANCE_UPLOAD_NOT_NULL); |
|
|
|
ExceptionCast.cast(GuaranteeCode.COMPLIANCE_UPLOAD_NOT_NULL); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
// 将合规调查的审核状态为审核中
|
|
|
|
|
|
|
|
this.getBaseMapper().updateAuditStatusByBusinessId(this.getComplianceInvestigation(iid).getBusinessId(), |
|
|
|
|
|
|
|
StatusCode.SP_IN_REVIEW); |
|
|
|
// 更新合规调查表调查数据,表示调查完成
|
|
|
|
// 更新合规调查表调查数据,表示调查完成
|
|
|
|
Boolean result = this.getBaseMapper().survey(iid, opinion, new Date(), Integer.parseInt(userId), |
|
|
|
Boolean result = this.getBaseMapper().survey(iid, opinion, new Date(), Integer.parseInt(userId), |
|
|
|
StatusCode.CZ_PROCESSED, StatusCode.SP_IN_REVIEW, fileUrl); |
|
|
|
StatusCode.CZ_PROCESSED, StatusCode.SP_IN_REVIEW, fileUrl); |
|
|
@ -153,6 +170,27 @@ public class DgComplianceInvestigationServiceImpl extends ServiceImpl<DgComplian |
|
|
|
if (opinion == null || opinion.length() == 0) { |
|
|
|
if (opinion == null || opinion.length() == 0) { |
|
|
|
ExceptionCast.cast(GuaranteeCode.COMPLIANCE_INVESTIGATION_REMARK_NOT_NULL); |
|
|
|
ExceptionCast.cast(GuaranteeCode.COMPLIANCE_INVESTIGATION_REMARK_NOT_NULL); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
// 先改变合规调查的审核状态为驳回
|
|
|
|
|
|
|
|
Boolean result = this.getBaseMapper().updateAuditStatusByBusinessId(this.getComplianceInvestigation(iid).getBusinessId(), |
|
|
|
|
|
|
|
StatusCode.SP_REJECT); |
|
|
|
|
|
|
|
if (result) { |
|
|
|
|
|
|
|
// 再改变自己的操作状态为已处理
|
|
|
|
|
|
|
|
Boolean result1 = this.getBaseMapper().updateOperationStatusById(iid, StatusCode.CZ_PROCESSED, opinion); |
|
|
|
|
|
|
|
if (result1) { |
|
|
|
|
|
|
|
// 改变担保部的审核状态为驳回
|
|
|
|
|
|
|
|
Boolean result2 = dgGuaranteeAssignUserMapper.updateAuditStatusByBusinessId(this.getComplianceInvestigation(iid).getBusinessId(), |
|
|
|
|
|
|
|
StatusCode.SP_REJECT); |
|
|
|
|
|
|
|
if (result2) { |
|
|
|
|
|
|
|
// 修改AB角的操作状态为待处理
|
|
|
|
|
|
|
|
Boolean result3 = dgGuaranteeAssignUserMapper.updateOperationStatusById(this.getComplianceInvestigation(iid) |
|
|
|
|
|
|
|
.getBusinessId(), StatusCode.CZ_ON_HAND); |
|
|
|
|
|
|
|
if (result3) { |
|
|
|
|
|
|
|
// 在业务流程表中插入一条驳回成功的数据(记得带上驳回的意见)
|
|
|
|
|
|
|
|
return true; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
return false; |
|
|
|
return false; |
|
|
|
} |
|
|
|
} |
|
|
@ -170,56 +208,139 @@ public class DgComplianceInvestigationServiceImpl extends ServiceImpl<DgComplian |
|
|
|
String userId = "1"; |
|
|
|
String userId = "1"; |
|
|
|
Integer operationStatus = this.getBaseMapper().getOperationStatusByBusinessId( |
|
|
|
Integer operationStatus = this.getBaseMapper().getOperationStatusByBusinessId( |
|
|
|
this.getComplianceInvestigation(iid).getBusinessId(), PromptSuccess.FG_JL_ID); |
|
|
|
this.getComplianceInvestigation(iid).getBusinessId(), PromptSuccess.FG_JL_ID); |
|
|
|
// 待处理,表示业务进行到法规经理审核
|
|
|
|
// 1.待处理,表示业务进行到法规经理审核
|
|
|
|
if (Objects.equals(operationStatus, StatusCode.CZ_ON_HAND)) { |
|
|
|
if (Objects.equals(operationStatus, StatusCode.CZ_ON_HAND)) { |
|
|
|
// 同意
|
|
|
|
// 查询业务流程表,找出该业务id的最新操作记录的角色id
|
|
|
|
if (status == 1) { |
|
|
|
Integer roleId = 70; |
|
|
|
Boolean result = this.getBaseMapper().check(iid, opinion, new Date(), |
|
|
|
if (roleId.equals(PromptSuccess.DB_A_ID) || roleId.equals(PromptSuccess.DB_B_ID)) { |
|
|
|
StatusCode.SP_IN_REVIEW, StatusCode.CZ_PROCESSED, Integer.parseInt(userId)); |
|
|
|
// 1.1.若为A/B角,表示为驳回数据
|
|
|
|
if (result) { |
|
|
|
// 同意
|
|
|
|
// 法规经理完成审核,新增一条法规领导审核数据(借用插入一条调查数据的接口)
|
|
|
|
if (status == 1) { |
|
|
|
DgComplianceInvestigation complianceInvestigation = this.getComplianceInvestigation(iid); |
|
|
|
// 改变自己的状态为已处理
|
|
|
|
complianceInvestigation.setUserId(null); |
|
|
|
Boolean result = this.getBaseMapper().updateOperationStatusById(iid, StatusCode.CZ_PROCESSED, opinion); |
|
|
|
complianceInvestigation.setRoleId(PromptSuccess.FG_LD_ID); |
|
|
|
if (result) { |
|
|
|
complianceInvestigation.setOperationStatus(StatusCode.CZ_ON_HAND); |
|
|
|
// 改变C角的这条数据的操作状态为待处理
|
|
|
|
complianceInvestigation.setAuditStatus(StatusCode.SP_IN_REVIEW); |
|
|
|
Boolean result1 = this.getBaseMapper().updateToAudit(this.getComplianceInvestigation(iid).getBusinessId(), |
|
|
|
complianceInvestigation.setCreateTime(new Date()); |
|
|
|
StatusCode.CZ_ON_HAND, PromptSuccess.FG_C_ID); |
|
|
|
complianceInvestigation.setUpdateTime(new Date()); |
|
|
|
if (result1) { |
|
|
|
Boolean result1 = this.getBaseMapper().assign(complianceInvestigation); |
|
|
|
// 在业务流程表中插入一条法规经理同意的数据
|
|
|
|
if (result1) { |
|
|
|
return true; |
|
|
|
// 在业务流程表中插入一条法规经理审核成功的数据
|
|
|
|
} |
|
|
|
return true; |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
// 驳回
|
|
|
|
// 驳回
|
|
|
|
if (status == 2) { |
|
|
|
if (status == 2) { |
|
|
|
if (opinion == null || opinion.length() == 0) { |
|
|
|
|
|
|
|
ExceptionCast.cast(GuaranteeCode.COMPLIANCE_INVESTIGATION_REMARK_NOT_NULL); |
|
|
|
} |
|
|
|
} |
|
|
|
// 拒绝
|
|
|
|
// 先改变所有的审核状态为驳回
|
|
|
|
if (status == 3) { |
|
|
|
Boolean result = this.getBaseMapper().updateAuditStatusByBusinessId(this.getComplianceInvestigation(iid).getBusinessId(), |
|
|
|
if (opinion == null || opinion.length() == 0) { |
|
|
|
StatusCode.SP_REJECT); |
|
|
|
ExceptionCast.cast(GuaranteeCode.COMPLIANCE_INVESTIGATION_REMARK_NOT_NULL); |
|
|
|
if (result) { |
|
|
|
|
|
|
|
// 再改变自己当前的操作状态为已处理
|
|
|
|
|
|
|
|
Boolean result1 = this.getBaseMapper().updateOperationStatusById(iid, StatusCode.CZ_PROCESSED, opinion); |
|
|
|
|
|
|
|
if (result1) { |
|
|
|
|
|
|
|
// 最后改变C角的这条数据的操作状态为待处理
|
|
|
|
|
|
|
|
Boolean result2 = this.getBaseMapper().updateToAudit(this.getComplianceInvestigation(iid).getBusinessId(), |
|
|
|
|
|
|
|
StatusCode.CZ_ON_HAND, PromptSuccess.FG_C_ID); |
|
|
|
|
|
|
|
if (result2) { |
|
|
|
|
|
|
|
// 在业务流程表中插入一条法规经理驳回的数据
|
|
|
|
|
|
|
|
return true; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
// 先改变所有的审核状态为已拒绝
|
|
|
|
// 拒绝
|
|
|
|
Boolean result = this.getBaseMapper().updateAuditStatusByBusinessId(this.getComplianceInvestigation(iid).getBusinessId(), |
|
|
|
if (status == 3) { |
|
|
|
StatusCode.SP_REFUSE); |
|
|
|
if (opinion == null || opinion.length() == 0) { |
|
|
|
if (result) { |
|
|
|
ExceptionCast.cast(GuaranteeCode.COMPLIANCE_INVESTIGATION_REMARK_NOT_NULL); |
|
|
|
// 再改变自己当前的操作状态为已处理
|
|
|
|
} |
|
|
|
Boolean result1 = this.getBaseMapper().updateOperationStatusById(iid, StatusCode.CZ_PROCESSED, opinion); |
|
|
|
// 先改变所有的审核状态为已拒绝
|
|
|
|
if (result1) { |
|
|
|
Boolean result = this.getBaseMapper().updateAuditStatusByBusinessId(this.getComplianceInvestigation(iid).getBusinessId(), |
|
|
|
// 最后改变该条贷款信息的业务状态为已否决
|
|
|
|
StatusCode.SP_REFUSE); |
|
|
|
Boolean result2 = this.getBaseMapper().updateBusinessStatusByBusinessId( |
|
|
|
if (result) { |
|
|
|
this.getComplianceInvestigation(iid).getBusinessId(), StatusCode.YW_REJECTED); |
|
|
|
// 再改变自己当前的操作状态为已处理
|
|
|
|
if (result2) { |
|
|
|
Boolean result1 = this.getBaseMapper().updateOperationStatusById(iid, StatusCode.CZ_PROCESSED, opinion); |
|
|
|
// 在业务流程表中插入一条拒绝数据(记得带上拒绝意见)
|
|
|
|
if (result1) { |
|
|
|
|
|
|
|
// 最后改变该条贷款信息的业务状态为已否决
|
|
|
|
|
|
|
|
Boolean result2 = this.getBaseMapper().updateBusinessStatusByBusinessId( |
|
|
|
|
|
|
|
this.getComplianceInvestigation(iid).getBusinessId(), StatusCode.YW_REJECTED); |
|
|
|
|
|
|
|
if (result2) { |
|
|
|
|
|
|
|
// 在业务流程表中插入一条拒绝数据(记得带上拒绝意见)
|
|
|
|
|
|
|
|
return true; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
// 1.2.若为C角,表示为非驳回数据
|
|
|
|
|
|
|
|
// 同意
|
|
|
|
|
|
|
|
if (status == 1) { |
|
|
|
|
|
|
|
Boolean result = this.getBaseMapper().check(iid, opinion, new Date(), |
|
|
|
|
|
|
|
StatusCode.SP_IN_REVIEW, StatusCode.CZ_PROCESSED, Integer.parseInt(userId)); |
|
|
|
|
|
|
|
if (result) { |
|
|
|
|
|
|
|
// 法规经理完成审核,新增一条法规领导审核数据(借用插入一条调查数据的接口)
|
|
|
|
|
|
|
|
DgComplianceInvestigation complianceInvestigation = this.getComplianceInvestigation(iid); |
|
|
|
|
|
|
|
complianceInvestigation.setUserId(null); |
|
|
|
|
|
|
|
complianceInvestigation.setRoleId(PromptSuccess.FG_LD_ID); |
|
|
|
|
|
|
|
complianceInvestigation.setOperationStatus(StatusCode.CZ_ON_HAND); |
|
|
|
|
|
|
|
complianceInvestigation.setAuditStatus(StatusCode.SP_IN_REVIEW); |
|
|
|
|
|
|
|
complianceInvestigation.setCreateTime(new Date()); |
|
|
|
|
|
|
|
complianceInvestigation.setUpdateTime(new Date()); |
|
|
|
|
|
|
|
Boolean result1 = this.getBaseMapper().assign(complianceInvestigation); |
|
|
|
|
|
|
|
if (result1) { |
|
|
|
|
|
|
|
// 在业务流程表中插入一条法规经理审核成功的数据
|
|
|
|
return true; |
|
|
|
return true; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
// 驳回
|
|
|
|
|
|
|
|
if (status == 2) { |
|
|
|
|
|
|
|
if (opinion == null || opinion.length() == 0) { |
|
|
|
|
|
|
|
ExceptionCast.cast(GuaranteeCode.COMPLIANCE_INVESTIGATION_REMARK_NOT_NULL); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
// 先改变所有的审核状态为驳回
|
|
|
|
|
|
|
|
Boolean result = this.getBaseMapper().updateAuditStatusByBusinessId(this.getComplianceInvestigation(iid).getBusinessId(), |
|
|
|
|
|
|
|
StatusCode.SP_REJECT); |
|
|
|
|
|
|
|
if (result) { |
|
|
|
|
|
|
|
// 再改变自己当前的操作状态为已处理
|
|
|
|
|
|
|
|
Boolean result1 = this.getBaseMapper().updateOperationStatusById(iid, StatusCode.CZ_PROCESSED, opinion); |
|
|
|
|
|
|
|
if (result1) { |
|
|
|
|
|
|
|
// 最后改变C角的这条数据的操作状态为待处理
|
|
|
|
|
|
|
|
Boolean result2 = this.getBaseMapper().updateToAudit(this.getComplianceInvestigation(iid).getBusinessId(), |
|
|
|
|
|
|
|
StatusCode.CZ_ON_HAND, PromptSuccess.FG_C_ID); |
|
|
|
|
|
|
|
if (result2) { |
|
|
|
|
|
|
|
// 在业务流程表中插入一条法规经理驳回的数据
|
|
|
|
|
|
|
|
return true; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
// 拒绝
|
|
|
|
|
|
|
|
if (status == 3) { |
|
|
|
|
|
|
|
if (opinion == null || opinion.length() == 0) { |
|
|
|
|
|
|
|
ExceptionCast.cast(GuaranteeCode.COMPLIANCE_INVESTIGATION_REMARK_NOT_NULL); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
// 先改变所有的审核状态为已拒绝
|
|
|
|
|
|
|
|
Boolean result = this.getBaseMapper().updateAuditStatusByBusinessId(this.getComplianceInvestigation(iid).getBusinessId(), |
|
|
|
|
|
|
|
StatusCode.SP_REFUSE); |
|
|
|
|
|
|
|
if (result) { |
|
|
|
|
|
|
|
// 再改变自己当前的操作状态为已处理
|
|
|
|
|
|
|
|
Boolean result1 = this.getBaseMapper().updateOperationStatusById(iid, StatusCode.CZ_PROCESSED, opinion); |
|
|
|
|
|
|
|
if (result1) { |
|
|
|
|
|
|
|
// 最后改变该条贷款信息的业务状态为已否决
|
|
|
|
|
|
|
|
Boolean result2 = this.getBaseMapper().updateBusinessStatusByBusinessId( |
|
|
|
|
|
|
|
this.getComplianceInvestigation(iid).getBusinessId(), StatusCode.YW_REJECTED); |
|
|
|
|
|
|
|
if (result2) { |
|
|
|
|
|
|
|
// 在业务流程表中插入一条拒绝数据(记得带上拒绝意见)
|
|
|
|
|
|
|
|
return true; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
// 已处理,表示业务进行到法规领导审核
|
|
|
|
// 2.已处理,表示业务进行到法规领导审核
|
|
|
|
if (Objects.equals(operationStatus, StatusCode.CZ_PROCESSED)) { |
|
|
|
if (Objects.equals(operationStatus, StatusCode.CZ_PROCESSED)) { |
|
|
|
// 同意
|
|
|
|
// 同意
|
|
|
|
if (status == 1) { |
|
|
|
if (status == 1) { |
|
|
@ -245,7 +366,25 @@ public class DgComplianceInvestigationServiceImpl extends ServiceImpl<DgComplian |
|
|
|
} |
|
|
|
} |
|
|
|
// 驳回
|
|
|
|
// 驳回
|
|
|
|
if (status == 2) { |
|
|
|
if (status == 2) { |
|
|
|
|
|
|
|
if (opinion == null || opinion.length() == 0) { |
|
|
|
|
|
|
|
ExceptionCast.cast(GuaranteeCode.COMPLIANCE_INVESTIGATION_REMARK_NOT_NULL); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
// 先改变所有的审核状态为驳回
|
|
|
|
|
|
|
|
Boolean result = this.getBaseMapper().updateAuditStatusByBusinessId(this.getComplianceInvestigation(iid).getBusinessId(), |
|
|
|
|
|
|
|
StatusCode.SP_REJECT); |
|
|
|
|
|
|
|
if (result) { |
|
|
|
|
|
|
|
// 再改变自己当前的操作状态为已处理
|
|
|
|
|
|
|
|
Boolean result1 = this.getBaseMapper().updateOperationStatusById(iid, StatusCode.CZ_PROCESSED, opinion); |
|
|
|
|
|
|
|
if (result1) { |
|
|
|
|
|
|
|
// 最后改变法规部经理的这条数据的操作状态为待处理
|
|
|
|
|
|
|
|
Boolean result2 = this.getBaseMapper().updateToAudit(this.getComplianceInvestigation(iid).getBusinessId(), |
|
|
|
|
|
|
|
StatusCode.CZ_ON_HAND, PromptSuccess.FG_LD_ID); |
|
|
|
|
|
|
|
if (result2) { |
|
|
|
|
|
|
|
// 在业务流程表中插入一条法规领导驳回的数据
|
|
|
|
|
|
|
|
return true; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
// 拒绝
|
|
|
|
// 拒绝
|
|
|
|
if (status == 3) { |
|
|
|
if (status == 3) { |
|
|
@ -277,8 +416,27 @@ public class DgComplianceInvestigationServiceImpl extends ServiceImpl<DgComplian |
|
|
|
* 查看 |
|
|
|
* 查看 |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
@Override |
|
|
|
@Override |
|
|
|
public DgComplianceInvestigation query(Integer iid) { |
|
|
|
public DgComplianceInvestigationInfoResponse query(Integer iid) { |
|
|
|
return this.getBaseMapper().queryDgComplianceInvestigation(iid); |
|
|
|
DgComplianceInvestigationInfoResponse dgComplianceInvestigationInfoResponse = new DgComplianceInvestigationInfoResponse(); |
|
|
|
|
|
|
|
// 担保领导的数据id
|
|
|
|
|
|
|
|
Integer guaranteeId = this.getBaseMapper().getGuaranteeId(this.getComplianceInvestigation(iid).getBusinessId(), |
|
|
|
|
|
|
|
PromptSuccess.DB_LD_ID); |
|
|
|
|
|
|
|
// 资产领导的数据id
|
|
|
|
|
|
|
|
Integer dgAssetsInvestigationId = this.getBaseMapper().getDgAssetsInvestigationId(this.getComplianceInvestigation(iid).getBusinessId(), |
|
|
|
|
|
|
|
PromptSuccess.ZC_LD_ID); |
|
|
|
|
|
|
|
// 担保详情
|
|
|
|
|
|
|
|
GuaranteeDetailResponse guaranteeDetailResponse = guaranteeAssignUserService.guaranteeDetail(guaranteeId); |
|
|
|
|
|
|
|
// 资产详情
|
|
|
|
|
|
|
|
AssetsDetailResponse assetsDetailResponse = dgAssetsInvestigationService.assetsDetail(dgAssetsInvestigationId); |
|
|
|
|
|
|
|
// 合规附件和意见
|
|
|
|
|
|
|
|
DgComplianceInvestigation dgComplianceInvestigation = this.getBaseMapper().queryDgComplianceInvestigation(iid); |
|
|
|
|
|
|
|
// 统一返回
|
|
|
|
|
|
|
|
dgComplianceInvestigationInfoResponse.setGuaranteeDetailResponse(guaranteeDetailResponse); |
|
|
|
|
|
|
|
dgComplianceInvestigationInfoResponse.setAssetsResponse(assetsDetailResponse.getAssetsResponse()); |
|
|
|
|
|
|
|
dgComplianceInvestigationInfoResponse.setFileUrl(dgComplianceInvestigation.getFile()); |
|
|
|
|
|
|
|
dgComplianceInvestigationInfoResponse.setOpinion(dgComplianceInvestigation.getOpinion()); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return dgComplianceInvestigationInfoResponse; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
@ -289,27 +447,14 @@ public class DgComplianceInvestigationServiceImpl extends ServiceImpl<DgComplian |
|
|
|
if (ids == null || ids.size() == 0) { |
|
|
|
if (ids == null || ids.size() == 0) { |
|
|
|
ExceptionCast.cast(GuaranteeCode.EXCEL_ID_NOT_NULL); |
|
|
|
ExceptionCast.cast(GuaranteeCode.EXCEL_ID_NOT_NULL); |
|
|
|
} |
|
|
|
} |
|
|
|
/*String userId = this.getUserId(); |
|
|
|
|
|
|
|
// 获取当前登录用户的角色id
|
|
|
|
|
|
|
|
String roleIdString = RedisUtil.get("dq:userRole:" + userId); |
|
|
|
|
|
|
|
if (roleIdString == null || roleIdString.length() == 0) { |
|
|
|
|
|
|
|
ExceptionCast.cast(GuaranteeCode.ROLE_IS_NOT); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
String[] roleIds = roleIdString.split(",");*/ |
|
|
|
|
|
|
|
String userId = "1"; |
|
|
|
|
|
|
|
String[] roleIds = {"70"}; |
|
|
|
|
|
|
|
List<Integer> roleList = new ArrayList<>(); |
|
|
|
|
|
|
|
for (String roleId : roleIds) { |
|
|
|
|
|
|
|
roleList.add(Integer.parseInt(roleId)); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
List<Integer> idList = new ArrayList<>(); |
|
|
|
List<Integer> idList = new ArrayList<>(); |
|
|
|
for (String id : ids) { |
|
|
|
for (String id : ids) { |
|
|
|
idList.add(Integer.parseInt(id)); |
|
|
|
idList.add(Integer.parseInt(id)); |
|
|
|
} |
|
|
|
} |
|
|
|
List<DgComplianceInvestigationResponse> list = this.getBaseMapper().listExcel(roleList, Integer.parseInt(userId), idList); |
|
|
|
List<DgComplianceInvestigationResponse> list = this.getBaseMapper().listExcel(idList); |
|
|
|
try { |
|
|
|
try { |
|
|
|
ExcelUtil.writeExcelWithSheets(response, list, "合规调查数据一览表", "complianceInvestigation", |
|
|
|
ExcelUtil.writeExcelWithSheets(response, list, "合规调查数据一览表", "NO.1", new DgComplianceInvestigationResponse()) |
|
|
|
new DgComplianceInvestigationResponse()); |
|
|
|
.finish(); |
|
|
|
} catch (Exception e) { |
|
|
|
} catch (Exception e) { |
|
|
|
ExceptionCast.cast(CrmsCode.CUSTOMER_EXPORT_EXSIT); |
|
|
|
ExceptionCast.cast(CrmsCode.CUSTOMER_EXPORT_EXSIT); |
|
|
|
} |
|
|
|
} |
|
|
|