|
|
@ -3,6 +3,7 @@ package com.daqing.financial.guarantee.service.impl; |
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
|
|
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
|
|
|
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.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
|
|
|
import com.daqing.financial.guarantee.controller.DgApplyAmountInfoController; |
|
|
|
import com.daqing.financial.guarantee.controller.DgApplyAmountInfoController; |
|
|
|
import com.daqing.financial.guarantee.mapper.DgGuaranteeAssignUserMapper; |
|
|
|
import com.daqing.financial.guarantee.mapper.DgGuaranteeAssignUserMapper; |
|
|
|
import com.daqing.financial.guarantee.mapper.DgGuaranteeLetterAssignUserMapper; |
|
|
|
import com.daqing.financial.guarantee.mapper.DgGuaranteeLetterAssignUserMapper; |
|
|
@ -11,22 +12,18 @@ import com.daqing.financial.guarantee.mapper.DgPaymentConfirmationConsiderMapper |
|
|
|
import com.daqing.financial.guarantee.model.request.GuaranteeLetterQueryRequest; |
|
|
|
import com.daqing.financial.guarantee.model.request.GuaranteeLetterQueryRequest; |
|
|
|
import com.daqing.financial.guarantee.model.request.GuaranteeLetterUpdateStatusRequest; |
|
|
|
import com.daqing.financial.guarantee.model.request.GuaranteeLetterUpdateStatusRequest; |
|
|
|
import com.daqing.financial.guarantee.model.response.GuaranteeLetterListResponse; |
|
|
|
import com.daqing.financial.guarantee.model.response.GuaranteeLetterListResponse; |
|
|
|
import com.daqing.financial.guarantee.model.response.PaymentConfirmationListResponse; |
|
|
|
|
|
|
|
import com.daqing.financial.guarantee.service.IDgGuaranteeLetterAssignUserService; |
|
|
|
import com.daqing.financial.guarantee.service.IDgGuaranteeLetterAssignUserService; |
|
|
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
|
|
|
|
|
|
|
import com.daqing.financial.guarantee.util.AuditProcessUtil; |
|
|
|
import com.daqing.financial.guarantee.util.AuditProcessUtil; |
|
|
|
|
|
|
|
import com.daqing.financial.guarantee.util.OrdinaryUtil; |
|
|
|
import com.daqing.framework.domain.guarantee.DgGuaranteeAssignUser; |
|
|
|
import com.daqing.framework.domain.guarantee.DgGuaranteeAssignUser; |
|
|
|
import com.daqing.framework.domain.guarantee.DgGuaranteeLetterAssignUser; |
|
|
|
import com.daqing.framework.domain.guarantee.DgGuaranteeLetterAssignUser; |
|
|
|
import com.daqing.framework.domain.guarantee.DgLoanCommitteeConsider; |
|
|
|
import com.daqing.framework.domain.guarantee.DgLoanCommitteeConsider; |
|
|
|
import com.daqing.framework.domain.guarantee.DgPaymentConfirmationConsider; |
|
|
|
import com.daqing.framework.domain.guarantee.DgPaymentConfirmationConsider; |
|
|
|
import com.daqing.framework.exception.ExceptionCast; |
|
|
|
|
|
|
|
import com.daqing.framework.exception.ExceptionCatch; |
|
|
|
|
|
|
|
import com.daqing.framework.model.StatusCode; |
|
|
|
import com.daqing.framework.model.StatusCode; |
|
|
|
import com.daqing.framework.model.response.PromptSuccess; |
|
|
|
import com.daqing.framework.model.response.PromptSuccess; |
|
|
|
import com.daqing.framework.util.RedisUtil; |
|
|
|
import com.daqing.framework.util.RedisUtil; |
|
|
|
import com.daqing.framework.utils.PageUtils; |
|
|
|
import com.daqing.framework.utils.PageUtils; |
|
|
|
import com.daqing.framework.utils.excel.EasyExcelUtil; |
|
|
|
import com.daqing.framework.utils.excel.EasyExcelUtil; |
|
|
|
import com.daqing.framework.utils.excel.ExcelUtil; |
|
|
|
|
|
|
|
import lombok.extern.slf4j.Slf4j; |
|
|
|
import lombok.extern.slf4j.Slf4j; |
|
|
|
import org.springframework.beans.factory.annotation.Autowired; |
|
|
|
import org.springframework.beans.factory.annotation.Autowired; |
|
|
|
import org.springframework.stereotype.Service; |
|
|
|
import org.springframework.stereotype.Service; |
|
|
@ -167,10 +164,10 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran |
|
|
|
Integer companyId = guaranteeLetterAssignUser.getCompanyId(); |
|
|
|
Integer companyId = guaranteeLetterAssignUser.getCompanyId(); |
|
|
|
//根据当前用户更新审核状态和操作状态及审核意见
|
|
|
|
//根据当前用户更新审核状态和操作状态及审核意见
|
|
|
|
int i = baseMapper.updateById(guaranteeLetterAssignUser); |
|
|
|
int i = baseMapper.updateById(guaranteeLetterAssignUser); |
|
|
|
|
|
|
|
|
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
AuditProcessUtil.save(businessId,account,"法规部经理",auditOpinion,8,PromptSuccess.FG_JL_ID,"","",""); |
|
|
|
String departmentId = OrdinaryUtil.getDepartmentId(currentUser); |
|
|
|
|
|
|
|
AuditProcessUtil.save(currentUser,businessId,account,departmentId,auditOpinion,8,PromptSuccess.FG_JL_ID,"","",""); |
|
|
|
//更新成功,添加ab角数据
|
|
|
|
//更新成功,添加ab角数据
|
|
|
|
if (i > 0){ |
|
|
|
if (i > 0){ |
|
|
|
//获取之前指定的a角用户
|
|
|
|
//获取之前指定的a角用户
|
|
|
@ -243,7 +240,8 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran |
|
|
|
int i = baseMapper.updateById(guaranteeLetterAssignUser); |
|
|
|
int i = baseMapper.updateById(guaranteeLetterAssignUser); |
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
AuditProcessUtil.save(businessId,account,"法规部经理",auditOpinion,8,PromptSuccess.FG_JL_ID,"","",""); |
|
|
|
String departmentId = OrdinaryUtil.getDepartmentId(currentUser); |
|
|
|
|
|
|
|
AuditProcessUtil.save(currentUser,businessId,account,departmentId,auditOpinion,8,PromptSuccess.FG_JL_ID,"","",""); |
|
|
|
//更新成功,更新ab角数据及资产部经理数据
|
|
|
|
//更新成功,更新ab角数据及资产部经理数据
|
|
|
|
if (i > 0){ |
|
|
|
if (i > 0){ |
|
|
|
//更新a角
|
|
|
|
//更新a角
|
|
|
@ -302,7 +300,8 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran |
|
|
|
int i = baseMapper.updateById(guaranteeLetterAssignUser); |
|
|
|
int i = baseMapper.updateById(guaranteeLetterAssignUser); |
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
AuditProcessUtil.save(businessId,account,"法规部经理",auditOpinion,8,PromptSuccess.FG_JL_ID,"","",""); |
|
|
|
String departmentId = OrdinaryUtil.getDepartmentId(currentUser); |
|
|
|
|
|
|
|
AuditProcessUtil.save(currentUser,businessId,account,departmentId,auditOpinion,8,PromptSuccess.FG_JL_ID,"","",""); |
|
|
|
//更新成功,更新贷审会数据
|
|
|
|
//更新成功,更新贷审会数据
|
|
|
|
if (i > 0){ |
|
|
|
if (i > 0){ |
|
|
|
//根据业务id查询贷审会数据
|
|
|
|
//根据业务id查询贷审会数据
|
|
|
@ -342,7 +341,8 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran |
|
|
|
int i = baseMapper.updateById(guaranteeLetterAssignUser); |
|
|
|
int i = baseMapper.updateById(guaranteeLetterAssignUser); |
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
AuditProcessUtil.save(businessId,account,"资产部经理",auditOpinion,8,PromptSuccess.ZC_JL_ID,"","",""); |
|
|
|
String departmentId = OrdinaryUtil.getDepartmentId(currentUser); |
|
|
|
|
|
|
|
AuditProcessUtil.save(currentUser,businessId,account,departmentId,auditOpinion,8,PromptSuccess.ZC_JL_ID,"","",""); |
|
|
|
//获取公司id
|
|
|
|
//获取公司id
|
|
|
|
Integer companyId = guaranteeLetterAssignUser.getCompanyId(); |
|
|
|
Integer companyId = guaranteeLetterAssignUser.getCompanyId(); |
|
|
|
//更新成功,添加回款确认数据及更新整个业务的审核状态
|
|
|
|
//更新成功,添加回款确认数据及更新整个业务的审核状态
|
|
|
@ -408,7 +408,8 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran |
|
|
|
int i = baseMapper.updateById(guaranteeLetterAssignUser); |
|
|
|
int i = baseMapper.updateById(guaranteeLetterAssignUser); |
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
AuditProcessUtil.save(businessId,account,"资产部经理",auditOpinion,8,PromptSuccess.ZC_JL_ID,"","",""); |
|
|
|
String departmentId = OrdinaryUtil.getDepartmentId(currentUser); |
|
|
|
|
|
|
|
AuditProcessUtil.save(currentUser,businessId,account,departmentId,auditOpinion,8,PromptSuccess.ZC_JL_ID,"","",""); |
|
|
|
//更新成功,更新回款确认数据及更新整个业务的审核状态
|
|
|
|
//更新成功,更新回款确认数据及更新整个业务的审核状态
|
|
|
|
if (i > 0){ |
|
|
|
if (i > 0){ |
|
|
|
//更新法规部经理数据
|
|
|
|
//更新法规部经理数据
|
|
|
@ -466,7 +467,8 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran |
|
|
|
int i = baseMapper.updateById(guaranteeLetterAssignUser); |
|
|
|
int i = baseMapper.updateById(guaranteeLetterAssignUser); |
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
AuditProcessUtil.save(businessId,account,"资产部经理",auditOpinion,8,PromptSuccess.ZC_JL_ID,"","",""); |
|
|
|
String departmentId = OrdinaryUtil.getDepartmentId(currentUser); |
|
|
|
|
|
|
|
AuditProcessUtil.save(currentUser,businessId,account,departmentId,auditOpinion,8,PromptSuccess.ZC_JL_ID,"","",""); |
|
|
|
//更新成功,更新AB角数据
|
|
|
|
//更新成功,更新AB角数据
|
|
|
|
if (i > 0){ |
|
|
|
if (i > 0){ |
|
|
|
//更新法规部经理数据
|
|
|
|
//更新法规部经理数据
|
|
|
@ -528,7 +530,8 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran |
|
|
|
log.info(i > 0 ? "首次a角用户确认担保函更新成功" : "首次a角用户确认担保函更新失败"); |
|
|
|
log.info(i > 0 ? "首次a角用户确认担保函更新成功" : "首次a角用户确认担保函更新失败"); |
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
AuditProcessUtil.save(businessId,account,"指派A角",auditOpinion,8,PromptSuccess.DB_A_ID,"","",""); |
|
|
|
String departmentId = OrdinaryUtil.getDepartmentId(currentUser); |
|
|
|
|
|
|
|
AuditProcessUtil.save(currentUser,businessId,account,departmentId,auditOpinion,8,PromptSuccess.DB_A_ID,"","",""); |
|
|
|
//更新成功后,判断b角用户是否确认
|
|
|
|
//更新成功后,判断b角用户是否确认
|
|
|
|
if (i > 0){ |
|
|
|
if (i > 0){ |
|
|
|
QueryWrapper<DgGuaranteeLetterAssignUser> tempB = new QueryWrapper<>(); |
|
|
|
QueryWrapper<DgGuaranteeLetterAssignUser> tempB = new QueryWrapper<>(); |
|
|
@ -577,7 +580,8 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran |
|
|
|
log.info(i > 0 ? "驳回后a角用户确认担保函更新成功" : "驳回后a角用户确认担保函更新失败"); |
|
|
|
log.info(i > 0 ? "驳回后a角用户确认担保函更新成功" : "驳回后a角用户确认担保函更新失败"); |
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
AuditProcessUtil.save(businessId,account,"指派A角",auditOpinion,8,PromptSuccess.DB_A_ID,"","",""); |
|
|
|
String departmentId = OrdinaryUtil.getDepartmentId(currentUser); |
|
|
|
|
|
|
|
AuditProcessUtil.save(currentUser,businessId,account,departmentId,auditOpinion,8,PromptSuccess.DB_A_ID,"","",""); |
|
|
|
//更新成功后,判断b角用户是否确认
|
|
|
|
//更新成功后,判断b角用户是否确认
|
|
|
|
if (i > 0){ |
|
|
|
if (i > 0){ |
|
|
|
QueryWrapper<DgGuaranteeLetterAssignUser> tempB = new QueryWrapper<>(); |
|
|
|
QueryWrapper<DgGuaranteeLetterAssignUser> tempB = new QueryWrapper<>(); |
|
|
@ -618,7 +622,8 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran |
|
|
|
log.info(i > 0 ? "a角用户驳回担保函更新成功" : "a角用户驳回担保函更新失败"); |
|
|
|
log.info(i > 0 ? "a角用户驳回担保函更新成功" : "a角用户驳回担保函更新失败"); |
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
AuditProcessUtil.save(businessId,account,"指派A角",auditOpinion,8,PromptSuccess.DB_A_ID,"","",""); |
|
|
|
String departmentId = OrdinaryUtil.getDepartmentId(currentUser); |
|
|
|
|
|
|
|
AuditProcessUtil.save(currentUser,businessId,account,departmentId,auditOpinion,8,PromptSuccess.DB_A_ID,"","",""); |
|
|
|
//更新成功后,更新b角数据及更新法规部经理数据
|
|
|
|
//更新成功后,更新b角数据及更新法规部经理数据
|
|
|
|
if (i > 0){ |
|
|
|
if (i > 0){ |
|
|
|
//更新b用户的审核状态为驳回,操作状态为已处理
|
|
|
|
//更新b用户的审核状态为驳回,操作状态为已处理
|
|
|
@ -667,7 +672,8 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran |
|
|
|
log.info(i > 0 ? "首次b角用户确认担保函更新成功" : "首次b角用户确认担保函更新失败"); |
|
|
|
log.info(i > 0 ? "首次b角用户确认担保函更新成功" : "首次b角用户确认担保函更新失败"); |
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
AuditProcessUtil.save(businessId,account,"指派B角",auditOpinion,8,PromptSuccess.DB_B_ID,"","",""); |
|
|
|
String departmentId = OrdinaryUtil.getDepartmentId(currentUser); |
|
|
|
|
|
|
|
AuditProcessUtil.save(currentUser,businessId,account,departmentId,auditOpinion,8,PromptSuccess.DB_B_ID,"","",""); |
|
|
|
//更新成功后,判断a角用户是否确认
|
|
|
|
//更新成功后,判断a角用户是否确认
|
|
|
|
if (i > 0){ |
|
|
|
if (i > 0){ |
|
|
|
QueryWrapper<DgGuaranteeLetterAssignUser> tempB = new QueryWrapper<>(); |
|
|
|
QueryWrapper<DgGuaranteeLetterAssignUser> tempB = new QueryWrapper<>(); |
|
|
@ -717,7 +723,8 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran |
|
|
|
log.info(i > 0 ? "驳回后b角用户确认担保函更新成功" : "驳回后b角用户确认担保函更新失败"); |
|
|
|
log.info(i > 0 ? "驳回后b角用户确认担保函更新成功" : "驳回后b角用户确认担保函更新失败"); |
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
AuditProcessUtil.save(businessId,account,"指派B角",auditOpinion,8,PromptSuccess.DB_B_ID,"","",""); |
|
|
|
String departmentId = OrdinaryUtil.getDepartmentId(currentUser); |
|
|
|
|
|
|
|
AuditProcessUtil.save(currentUser,businessId,account,departmentId,auditOpinion,8,PromptSuccess.DB_B_ID,"","",""); |
|
|
|
//更新成功后,判断a角用户是否确认
|
|
|
|
//更新成功后,判断a角用户是否确认
|
|
|
|
if (i > 0){ |
|
|
|
if (i > 0){ |
|
|
|
QueryWrapper<DgGuaranteeLetterAssignUser> tempB = new QueryWrapper<>(); |
|
|
|
QueryWrapper<DgGuaranteeLetterAssignUser> tempB = new QueryWrapper<>(); |
|
|
@ -758,7 +765,8 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran |
|
|
|
log.info(i > 0 ? "b角用户驳回担保函更新成功" : "b角用户驳回担保函更新失败"); |
|
|
|
log.info(i > 0 ? "b角用户驳回担保函更新成功" : "b角用户驳回担保函更新失败"); |
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
//同时往审核流程进程表新增一条记录
|
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
String account = DgApplyAmountInfoController.getAccount(); |
|
|
|
AuditProcessUtil.save(businessId,account,"指派B角",auditOpinion,8,PromptSuccess.DB_B_ID,"","",""); |
|
|
|
String departmentId = OrdinaryUtil.getDepartmentId(currentUser); |
|
|
|
|
|
|
|
AuditProcessUtil.save(currentUser,businessId,account,departmentId,auditOpinion,8,PromptSuccess.DB_B_ID,"","",""); |
|
|
|
//更新成功后,更新a角数据及更新法规部经理数据
|
|
|
|
//更新成功后,更新a角数据及更新法规部经理数据
|
|
|
|
if (i > 0){ |
|
|
|
if (i > 0){ |
|
|
|
//更新a用户的审核状态为驳回,操作状态为已处理
|
|
|
|
//更新a用户的审核状态为驳回,操作状态为已处理
|
|
|
|