Merge remote-tracking branch 'origin/master'

master
shijie 4 years ago
commit f928d1855b
  1. 108
      dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/impl/DgGuaranteeLetterAssignUserServiceImpl.java
  2. 12
      dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/impl/DgLoanNoticeServiceImpl.java
  3. 45
      dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/impl/DgPaymentConfirmationConsiderServiceImpl.java

@ -156,7 +156,6 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran
DgGuaranteeLetterAssignUser guaranteeLetterAssignUser = baseMapper.selectOne(queryWrapper); DgGuaranteeLetterAssignUser guaranteeLetterAssignUser = baseMapper.selectOne(queryWrapper);
//操作用户为当前用户 //操作用户为当前用户
guaranteeLetterAssignUser.setUserId(currentUser); guaranteeLetterAssignUser.setUserId(currentUser);
guaranteeLetterAssignUser.setStatus(StatusCode.SP_REVIEWED);
guaranteeLetterAssignUser.setOperatingStatus(StatusCode.CZ_PROCESSED); guaranteeLetterAssignUser.setOperatingStatus(StatusCode.CZ_PROCESSED);
guaranteeLetterAssignUser.setAuditOpinion(auditOpinion); guaranteeLetterAssignUser.setAuditOpinion(auditOpinion);
//获取公司id //获取公司id
@ -192,7 +191,6 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran
DgGuaranteeLetterAssignUser guaranteeLetterAssignUser = baseMapper.selectOne(queryWrapper); DgGuaranteeLetterAssignUser guaranteeLetterAssignUser = baseMapper.selectOne(queryWrapper);
//操作用户为当前用户 //操作用户为当前用户
guaranteeLetterAssignUser.setUserId(currentUser); guaranteeLetterAssignUser.setUserId(currentUser);
guaranteeLetterAssignUser.setStatus(StatusCode.SP_REVIEWED);
guaranteeLetterAssignUser.setOperatingStatus(StatusCode.CZ_PROCESSED); guaranteeLetterAssignUser.setOperatingStatus(StatusCode.CZ_PROCESSED);
guaranteeLetterAssignUser.setAuditOpinion(auditOpinion); guaranteeLetterAssignUser.setAuditOpinion(auditOpinion);
//根据当前用户更新审核状态和操作状态及审核意见 //根据当前用户更新审核状态和操作状态及审核意见
@ -200,7 +198,7 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran
//同时往审核流程进程表新增一条记录 //同时往审核流程进程表新增一条记录
String account = DgApplyAmountInfoController.getAccount(); String account = DgApplyAmountInfoController.getAccount();
AuditProcessUtil.save(businessId,account,"法规部经理",auditOpinion,8); AuditProcessUtil.save(businessId,account,"法规部经理",auditOpinion,8);
//更新成功,更新ab角数据 //更新成功,更新ab角数据及资产部经理数据
if (i > 0){ if (i > 0){
//更新a角 //更新a角
//根据业务id查询A用户数据 //根据业务id查询A用户数据
@ -222,7 +220,18 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran
dgGuaranteeLetterAssignUserB.setOperatingStatus(StatusCode.CZ_ON_HAND); dgGuaranteeLetterAssignUserB.setOperatingStatus(StatusCode.CZ_ON_HAND);
//清空上次的审批意见 //清空上次的审批意见
dgGuaranteeLetterAssignUserB.setAuditOpinion(""); dgGuaranteeLetterAssignUserB.setAuditOpinion("");
int update = baseMapper.updateById(dgGuaranteeLetterAssignUserB); baseMapper.updateById(dgGuaranteeLetterAssignUserB);
//更新资产部经理
//根据业务id查询资产部经理数据
QueryWrapper<DgGuaranteeLetterAssignUser> guaranteeLetterAssignUserQueryWrapperZc = new QueryWrapper<>();
guaranteeLetterAssignUserQueryWrapperZc.eq("business_id",businessId).eq("role_id",PromptSuccess.ZC_JL_ID);
DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUserZc = baseMapper.selectOne(guaranteeLetterAssignUserQueryWrapperZc);
dgGuaranteeLetterAssignUserZc.setStatus(StatusCode.SP_IN_REVIEW);
dgGuaranteeLetterAssignUserZc.setOperatingStatus(StatusCode.CZ_ON_HAND);
//清空上次的审批意见
dgGuaranteeLetterAssignUserZc.setAuditOpinion("");
int update = baseMapper.updateById(dgGuaranteeLetterAssignUserZc);
//更新成功,返回操作结果 //更新成功,返回操作结果
log.info(update > 0 ? "驳回后法规部经理成功生成担保函" : "驳回后法规部经理生成担保函失败"); log.info(update > 0 ? "驳回后法规部经理成功生成担保函" : "驳回后法规部经理生成担保函失败");
return update > 0; return update > 0;
@ -277,7 +286,6 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran
DgGuaranteeLetterAssignUser guaranteeLetterAssignUser = baseMapper.selectOne(queryWrapper); DgGuaranteeLetterAssignUser guaranteeLetterAssignUser = baseMapper.selectOne(queryWrapper);
//操作用户为当前用户 //操作用户为当前用户
guaranteeLetterAssignUser.setUserId(currentUser); guaranteeLetterAssignUser.setUserId(currentUser);
guaranteeLetterAssignUser.setStatus(StatusCode.SP_REVIEWED);
guaranteeLetterAssignUser.setOperatingStatus(StatusCode.CZ_PROCESSED); guaranteeLetterAssignUser.setOperatingStatus(StatusCode.CZ_PROCESSED);
guaranteeLetterAssignUser.setAuditOpinion(auditOpinion); guaranteeLetterAssignUser.setAuditOpinion(auditOpinion);
//根据当前用户更新审核状态和操作状态及审核意见 //根据当前用户更新审核状态和操作状态及审核意见
@ -287,8 +295,32 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran
AuditProcessUtil.save(businessId,account,"资产部经理",auditOpinion,8); AuditProcessUtil.save(businessId,account,"资产部经理",auditOpinion,8);
//获取公司id //获取公司id
Integer companyId = guaranteeLetterAssignUser.getCompanyId(); Integer companyId = guaranteeLetterAssignUser.getCompanyId();
//更新成功,添加回款确认数据 //更新成功,添加回款确认数据及更新整个业务的审核状态
if (i > 0){ if (i > 0){
//更新法规部经理数据
//根据业务id查询法规部经理数据
QueryWrapper<DgGuaranteeLetterAssignUser> guaranteeLetterAssignUserQueryWrapperFg = new QueryWrapper<>();
guaranteeLetterAssignUserQueryWrapperFg.eq("business_id",businessId).eq("role_id",PromptSuccess.FG_JL_ID);
DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUserFg = baseMapper.selectOne(guaranteeLetterAssignUserQueryWrapperFg);
dgGuaranteeLetterAssignUserFg.setStatus(StatusCode.SP_REVIEWED);
baseMapper.updateById(dgGuaranteeLetterAssignUserFg);
//更新a角
//根据业务id查询A用户数据
QueryWrapper<DgGuaranteeLetterAssignUser> guaranteeLetterAssignUserQueryWrapperA = new QueryWrapper<>();
guaranteeLetterAssignUserQueryWrapperA.eq("business_id",businessId).eq("role_id",PromptSuccess.DB_A_ID);
DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUserA = baseMapper.selectOne(guaranteeLetterAssignUserQueryWrapperA);
dgGuaranteeLetterAssignUserA.setStatus(StatusCode.SP_REVIEWED);
baseMapper.updateById(dgGuaranteeLetterAssignUserA);
//更新b角
//根据业务id查询B用户数据
QueryWrapper<DgGuaranteeLetterAssignUser> guaranteeLetterAssignUserQueryWrapperB = new QueryWrapper<>();
guaranteeLetterAssignUserQueryWrapperB.eq("business_id",businessId).eq("role_id",PromptSuccess.DB_B_ID);
DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUserB = baseMapper.selectOne(guaranteeLetterAssignUserQueryWrapperB);
dgGuaranteeLetterAssignUserB.setStatus(StatusCode.SP_REVIEWED);
baseMapper.updateById(dgGuaranteeLetterAssignUserB);
//添加财务部经理的回款数据 //添加财务部经理的回款数据
DgPaymentConfirmationConsider paymentConfirmationConsider = new DgPaymentConfirmationConsider(); DgPaymentConfirmationConsider paymentConfirmationConsider = new DgPaymentConfirmationConsider();
paymentConfirmationConsider.setRoleId(PromptSuccess.CWB_ID); paymentConfirmationConsider.setRoleId(PromptSuccess.CWB_ID);
@ -317,8 +349,32 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran
//同时往审核流程进程表新增一条记录 //同时往审核流程进程表新增一条记录
String account = DgApplyAmountInfoController.getAccount(); String account = DgApplyAmountInfoController.getAccount();
AuditProcessUtil.save(businessId,account,"资产部经理",auditOpinion,8); AuditProcessUtil.save(businessId,account,"资产部经理",auditOpinion,8);
//更新成功,更新回款确认数据 //更新成功,更新回款确认数据及更新整个业务的审核状态
if (i > 0){ if (i > 0){
//更新法规部经理数据
//根据业务id查询法规部经理数据
QueryWrapper<DgGuaranteeLetterAssignUser> guaranteeLetterAssignUserQueryWrapperFg = new QueryWrapper<>();
guaranteeLetterAssignUserQueryWrapperFg.eq("business_id",businessId).eq("role_id",PromptSuccess.FG_JL_ID);
DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUserFg = baseMapper.selectOne(guaranteeLetterAssignUserQueryWrapperFg);
dgGuaranteeLetterAssignUserFg.setStatus(StatusCode.SP_REVIEWED);
baseMapper.updateById(dgGuaranteeLetterAssignUserFg);
//更新a角
//根据业务id查询A用户数据
QueryWrapper<DgGuaranteeLetterAssignUser> guaranteeLetterAssignUserQueryWrapperA = new QueryWrapper<>();
guaranteeLetterAssignUserQueryWrapperA.eq("business_id",businessId).eq("role_id",PromptSuccess.DB_A_ID);
DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUserA = baseMapper.selectOne(guaranteeLetterAssignUserQueryWrapperA);
dgGuaranteeLetterAssignUserA.setStatus(StatusCode.SP_REVIEWED);
baseMapper.updateById(dgGuaranteeLetterAssignUserA);
//更新b角
//根据业务id查询B用户数据
QueryWrapper<DgGuaranteeLetterAssignUser> guaranteeLetterAssignUserQueryWrapperB = new QueryWrapper<>();
guaranteeLetterAssignUserQueryWrapperB.eq("business_id",businessId).eq("role_id",PromptSuccess.DB_B_ID);
DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUserB = baseMapper.selectOne(guaranteeLetterAssignUserQueryWrapperB);
dgGuaranteeLetterAssignUserB.setStatus(StatusCode.SP_REVIEWED);
baseMapper.updateById(dgGuaranteeLetterAssignUserB);
//更新财务部经理的回款数据 //更新财务部经理的回款数据
QueryWrapper<DgPaymentConfirmationConsider> paymentConfirmationConsiderQueryWrapper = new QueryWrapper<>(); QueryWrapper<DgPaymentConfirmationConsider> paymentConfirmationConsiderQueryWrapper = new QueryWrapper<>();
paymentConfirmationConsiderQueryWrapper.eq("business_id",businessId).eq("role_id",PromptSuccess.CWB_ID); paymentConfirmationConsiderQueryWrapper.eq("business_id",businessId).eq("role_id",PromptSuccess.CWB_ID);
@ -335,7 +391,7 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran
} }
} }
//驳回操作,更新数据及更新AB用户数据 //驳回操作,更新数据及更新AB用户数据及法规部经理数据
if (StatusCode.SP_REJECT.equals(status)){ if (StatusCode.SP_REJECT.equals(status)){
//根据角色及业务id查询需要更新数据 //根据角色及业务id查询需要更新数据
QueryWrapper<DgGuaranteeLetterAssignUser> queryWrapper = new QueryWrapper<>(); QueryWrapper<DgGuaranteeLetterAssignUser> queryWrapper = new QueryWrapper<>();
@ -353,6 +409,14 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran
AuditProcessUtil.save(businessId,account,"资产部经理",auditOpinion,8); AuditProcessUtil.save(businessId,account,"资产部经理",auditOpinion,8);
//更新成功,更新AB角数据 //更新成功,更新AB角数据
if (i > 0){ if (i > 0){
//更新法规部经理数据
//根据业务id查询法规部经理数据
QueryWrapper<DgGuaranteeLetterAssignUser> guaranteeLetterAssignUserQueryWrapperFg = new QueryWrapper<>();
guaranteeLetterAssignUserQueryWrapperFg.eq("business_id",businessId).eq("role_id",PromptSuccess.FG_JL_ID);
DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUserFg = baseMapper.selectOne(guaranteeLetterAssignUserQueryWrapperFg);
dgGuaranteeLetterAssignUserFg.setStatus(StatusCode.SP_REJECT);
baseMapper.updateById(dgGuaranteeLetterAssignUserFg);
//根据业务id查询A角数据 //根据业务id查询A角数据
QueryWrapper<DgGuaranteeLetterAssignUser> guaranteeLetterAssignUserQueryWrapperA = new QueryWrapper<>(); QueryWrapper<DgGuaranteeLetterAssignUser> guaranteeLetterAssignUserQueryWrapperA = new QueryWrapper<>();
guaranteeLetterAssignUserQueryWrapperA.eq("business_id",businessId).eq("role_id",PromptSuccess.DB_A_ID); guaranteeLetterAssignUserQueryWrapperA.eq("business_id",businessId).eq("role_id",PromptSuccess.DB_A_ID);
@ -396,7 +460,6 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran
queryWrapperUser.eq("business_id",businessId).eq("role_id",PromptSuccess.DB_A_ID); queryWrapperUser.eq("business_id",businessId).eq("role_id",PromptSuccess.DB_A_ID);
DgGuaranteeLetterAssignUser guaranteeLetterAssignUser = baseMapper.selectOne(queryWrapperUser); DgGuaranteeLetterAssignUser guaranteeLetterAssignUser = baseMapper.selectOne(queryWrapperUser);
guaranteeLetterAssignUser.setUserId(currentUser); guaranteeLetterAssignUser.setUserId(currentUser);
guaranteeLetterAssignUser.setStatus(StatusCode.SP_REVIEWED);
guaranteeLetterAssignUser.setOperatingStatus(StatusCode.CZ_PROCESSED); guaranteeLetterAssignUser.setOperatingStatus(StatusCode.CZ_PROCESSED);
guaranteeLetterAssignUser.setAuditOpinion(auditOpinion); guaranteeLetterAssignUser.setAuditOpinion(auditOpinion);
//获取公司id //获取公司id
@ -410,12 +473,12 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran
//更新成功后,判断b角用户是否确认 //更新成功后,判断b角用户是否确认
if (i > 0){ if (i > 0){
QueryWrapper<DgGuaranteeLetterAssignUser> tempB = new QueryWrapper<>(); QueryWrapper<DgGuaranteeLetterAssignUser> tempB = new QueryWrapper<>();
//查询b用户的审核状态 //查询b用户的操作状态
tempB.eq("business_id",businessId).eq("role_id",PromptSuccess.DB_B_ID).select("status"); tempB.eq("business_id",businessId).eq("role_id",PromptSuccess.DB_B_ID).select("operating_status");
DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUser = baseMapper.selectOne(tempB); DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUser = baseMapper.selectOne(tempB);
Integer bStatus = dgGuaranteeLetterAssignUser.getStatus(); Integer bStatus = dgGuaranteeLetterAssignUser.getOperatingStatus();
//b用户审核通过,添加资产部经理数据 //b用户审核通过,添加资产部经理数据
if (StatusCode.SP_REVIEWED.equals(bStatus)){ if (StatusCode.CZ_PROCESSED.equals(bStatus)){
DgGuaranteeLetterAssignUser ZCJLGuaranteeLetterAssign = new DgGuaranteeLetterAssignUser(); DgGuaranteeLetterAssignUser ZCJLGuaranteeLetterAssign = new DgGuaranteeLetterAssignUser();
ZCJLGuaranteeLetterAssign.setBusinessId(businessId); ZCJLGuaranteeLetterAssign.setBusinessId(businessId);
ZCJLGuaranteeLetterAssign.setCompanyId(companyId); ZCJLGuaranteeLetterAssign.setCompanyId(companyId);
@ -449,11 +512,11 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran
if (i > 0){ if (i > 0){
QueryWrapper<DgGuaranteeLetterAssignUser> tempB = new QueryWrapper<>(); QueryWrapper<DgGuaranteeLetterAssignUser> tempB = new QueryWrapper<>();
//查询b用户的审核状态 //查询b用户的审核状态
tempB.eq("business_id",businessId).eq("role_id",PromptSuccess.DB_B_ID).select("status"); tempB.eq("business_id",businessId).eq("role_id",PromptSuccess.DB_B_ID).select("operating_status");
DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUser = baseMapper.selectOne(tempB); DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUser = baseMapper.selectOne(tempB);
Integer bStatus = dgGuaranteeLetterAssignUser.getStatus(); Integer bStatus = dgGuaranteeLetterAssignUser.getOperatingStatus();
//b用户审核通过,更新资产部经理数据 //b用户审核通过,更新资产部经理数据
if (StatusCode.SP_REVIEWED.equals(bStatus)){ if (StatusCode.CZ_PROCESSED.equals(bStatus)){
QueryWrapper<DgGuaranteeLetterAssignUser> queryZCJLUser = new QueryWrapper<>(); QueryWrapper<DgGuaranteeLetterAssignUser> queryZCJLUser = new QueryWrapper<>();
queryZCJLUser.eq("business_id",businessId).eq("role_id",PromptSuccess.ZC_JL_ID); queryZCJLUser.eq("business_id",businessId).eq("role_id",PromptSuccess.ZC_JL_ID);
DgGuaranteeLetterAssignUser letterAssignUserZCJL = baseMapper.selectOne(queryZCJLUser); DgGuaranteeLetterAssignUser letterAssignUserZCJL = baseMapper.selectOne(queryZCJLUser);
@ -527,7 +590,6 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran
queryWrapperUser.eq("business_id",businessId).eq("role_id",PromptSuccess.DB_B_ID); queryWrapperUser.eq("business_id",businessId).eq("role_id",PromptSuccess.DB_B_ID);
DgGuaranteeLetterAssignUser guaranteeLetterAssignUser = baseMapper.selectOne(queryWrapperUser); DgGuaranteeLetterAssignUser guaranteeLetterAssignUser = baseMapper.selectOne(queryWrapperUser);
guaranteeLetterAssignUser.setUserId(currentUser); guaranteeLetterAssignUser.setUserId(currentUser);
guaranteeLetterAssignUser.setStatus(StatusCode.SP_REVIEWED);
guaranteeLetterAssignUser.setOperatingStatus(StatusCode.CZ_PROCESSED); guaranteeLetterAssignUser.setOperatingStatus(StatusCode.CZ_PROCESSED);
guaranteeLetterAssignUser.setAuditOpinion(auditOpinion); guaranteeLetterAssignUser.setAuditOpinion(auditOpinion);
//获取公司id //获取公司id
@ -542,11 +604,11 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran
if (i > 0){ if (i > 0){
QueryWrapper<DgGuaranteeLetterAssignUser> tempB = new QueryWrapper<>(); QueryWrapper<DgGuaranteeLetterAssignUser> tempB = new QueryWrapper<>();
//查询a用户的审核状态 //查询a用户的审核状态
tempB.eq("business_id",businessId).eq("role_id",PromptSuccess.DB_A_ID).select("status"); tempB.eq("business_id",businessId).eq("role_id",PromptSuccess.DB_A_ID).select("operating_status");
DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUser = baseMapper.selectOne(tempB); DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUser = baseMapper.selectOne(tempB);
Integer aStatus = dgGuaranteeLetterAssignUser.getStatus(); Integer aStatus = dgGuaranteeLetterAssignUser.getOperatingStatus();
//a用户审核通过,添加资产部经理数据 //a用户审核通过,添加资产部经理数据
if (StatusCode.SP_REVIEWED.equals(aStatus)){ if (StatusCode.CZ_PROCESSED.equals(aStatus)){
DgGuaranteeLetterAssignUser ZCJLGuaranteeLetterAssign = new DgGuaranteeLetterAssignUser(); DgGuaranteeLetterAssignUser ZCJLGuaranteeLetterAssign = new DgGuaranteeLetterAssignUser();
ZCJLGuaranteeLetterAssign.setBusinessId(businessId); ZCJLGuaranteeLetterAssign.setBusinessId(businessId);
ZCJLGuaranteeLetterAssign.setCompanyId(companyId); ZCJLGuaranteeLetterAssign.setCompanyId(companyId);
@ -581,11 +643,11 @@ public class DgGuaranteeLetterAssignUserServiceImpl extends ServiceImpl<DgGuaran
if (i > 0){ if (i > 0){
QueryWrapper<DgGuaranteeLetterAssignUser> tempB = new QueryWrapper<>(); QueryWrapper<DgGuaranteeLetterAssignUser> tempB = new QueryWrapper<>();
//查询a用户的审核状态 //查询a用户的审核状态
tempB.eq("business_id",businessId).eq("role_id",PromptSuccess.DB_A_ID).select("status"); tempB.eq("business_id",businessId).eq("role_id",PromptSuccess.DB_A_ID).select("operating_status");
DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUser = baseMapper.selectOne(tempB); DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUser = baseMapper.selectOne(tempB);
Integer aStatus = dgGuaranteeLetterAssignUser.getStatus(); Integer aStatus = dgGuaranteeLetterAssignUser.getOperatingStatus();
//a用户审核通过,更新资产部经理数据 //a用户审核通过,更新资产部经理数据
if (StatusCode.SP_REVIEWED.equals(aStatus)){ if (StatusCode.CZ_PROCESSED.equals(aStatus)){
QueryWrapper<DgGuaranteeLetterAssignUser> queryZCJLUser = new QueryWrapper<>(); QueryWrapper<DgGuaranteeLetterAssignUser> queryZCJLUser = new QueryWrapper<>();
queryZCJLUser.eq("business_id",businessId).eq("role_id",PromptSuccess.ZC_JL_ID); queryZCJLUser.eq("business_id",businessId).eq("role_id",PromptSuccess.ZC_JL_ID);
DgGuaranteeLetterAssignUser letterAssignUserZCJL = baseMapper.selectOne(queryZCJLUser); DgGuaranteeLetterAssignUser letterAssignUserZCJL = baseMapper.selectOne(queryZCJLUser);

@ -130,7 +130,7 @@ public class DgLoanNoticeServiceImpl extends ServiceImpl<DgLoanNoticeMapper, DgL
} }
} }
//驳回操作,更新数据和资产部经理数据及返回上一流程 //驳回操作,更新数据和法规部经理和财务部经理数据返回上一流程
if (StatusCode.SP_REJECT.equals(status)){ if (StatusCode.SP_REJECT.equals(status)){
QueryWrapper<DgLoanNotice> loanNoticeQueryWrapper = new QueryWrapper<>(); QueryWrapper<DgLoanNotice> loanNoticeQueryWrapper = new QueryWrapper<>();
loanNoticeQueryWrapper.eq("business_id",businessId).eq("role_id", PromptSuccess.FG_JL_ID); loanNoticeQueryWrapper.eq("business_id",businessId).eq("role_id", PromptSuccess.FG_JL_ID);
@ -143,7 +143,7 @@ public class DgLoanNoticeServiceImpl extends ServiceImpl<DgLoanNoticeMapper, DgL
//同时往审核流程进程表新增一条记录 //同时往审核流程进程表新增一条记录
String account = DgApplyAmountInfoController.getAccount(); String account = DgApplyAmountInfoController.getAccount();
AuditProcessUtil.save(businessId,account,"法规部经理",auditOpinion,10); AuditProcessUtil.save(businessId,account,"法规部经理",auditOpinion,10);
//更新成功,更新回款确认的财务部经理数据 //更新成功,更新回款确认的法规部经理和财务部经理数据
if (update > 0){ if (update > 0){
QueryWrapper<DgPaymentConfirmationConsider> queryWrapper = new QueryWrapper<>(); QueryWrapper<DgPaymentConfirmationConsider> queryWrapper = new QueryWrapper<>();
queryWrapper.eq("business_id",businessId).eq("role_id", PromptSuccess.FG_JL_ID); queryWrapper.eq("business_id",businessId).eq("role_id", PromptSuccess.FG_JL_ID);
@ -151,7 +151,13 @@ public class DgLoanNoticeServiceImpl extends ServiceImpl<DgLoanNoticeMapper, DgL
paymentConfirmationConsider.setStatus(StatusCode.SP_REJECT); paymentConfirmationConsider.setStatus(StatusCode.SP_REJECT);
paymentConfirmationConsider.setOperatingStatus(StatusCode.CZ_ON_HAND); paymentConfirmationConsider.setOperatingStatus(StatusCode.CZ_ON_HAND);
paymentConfirmationConsider.setAuditOpinion(""); paymentConfirmationConsider.setAuditOpinion("");
int updateById = paymentConfirmationConsiderMapper.updateById(paymentConfirmationConsider); paymentConfirmationConsiderMapper.updateById(paymentConfirmationConsider);
QueryWrapper<DgPaymentConfirmationConsider> queryWrapperCWB = new QueryWrapper<>();
queryWrapperCWB.eq("business_id",businessId).eq("role_id", PromptSuccess.CWB_ID);
DgPaymentConfirmationConsider paymentConfirmationConsiderCWB = paymentConfirmationConsiderMapper.selectOne(queryWrapperCWB);
paymentConfirmationConsiderCWB.setStatus(StatusCode.SP_REJECT);
int updateById = paymentConfirmationConsiderMapper.updateById(paymentConfirmationConsiderCWB);
//更新成功,返回操作结果 //更新成功,返回操作结果
log.info(updateById > 0 ? "驳回更新财务部经理成功" : "驳回更新财务部经理失败"); log.info(updateById > 0 ? "驳回更新财务部经理成功" : "驳回更新财务部经理失败");
return updateById > 0; return updateById > 0;

@ -137,7 +137,6 @@ public class DgPaymentConfirmationConsiderServiceImpl extends ServiceImpl<DgPaym
DgPaymentConfirmationConsider paymentConfirmationConsider = baseMapper.selectOne(queryWrapper); DgPaymentConfirmationConsider paymentConfirmationConsider = baseMapper.selectOne(queryWrapper);
paymentConfirmationConsider.setAuditOpinion(auditOpinion); paymentConfirmationConsider.setAuditOpinion(auditOpinion);
paymentConfirmationConsider.setConsiderId(currentUser); paymentConfirmationConsider.setConsiderId(currentUser);
paymentConfirmationConsider.setStatus(StatusCode.SP_REVIEWED);
paymentConfirmationConsider.setOperatingStatus(StatusCode.CZ_PROCESSED); paymentConfirmationConsider.setOperatingStatus(StatusCode.CZ_PROCESSED);
paymentConfirmationConsider.setImgFile(imgFile); paymentConfirmationConsider.setImgFile(imgFile);
int update = baseMapper.updateById(paymentConfirmationConsider); int update = baseMapper.updateById(paymentConfirmationConsider);
@ -166,7 +165,7 @@ public class DgPaymentConfirmationConsiderServiceImpl extends ServiceImpl<DgPaym
DgPaymentConfirmationConsider paymentConfirmationConsider = baseMapper.selectOne(queryWrapper); DgPaymentConfirmationConsider paymentConfirmationConsider = baseMapper.selectOne(queryWrapper);
paymentConfirmationConsider.setAuditOpinion(auditOpinion); paymentConfirmationConsider.setAuditOpinion(auditOpinion);
paymentConfirmationConsider.setConsiderId(currentUser); paymentConfirmationConsider.setConsiderId(currentUser);
paymentConfirmationConsider.setStatus(StatusCode.SP_REVIEWED); paymentConfirmationConsider.setStatus(StatusCode.SP_IN_REVIEW);
paymentConfirmationConsider.setOperatingStatus(StatusCode.CZ_PROCESSED); paymentConfirmationConsider.setOperatingStatus(StatusCode.CZ_PROCESSED);
paymentConfirmationConsider.setImgFile(imgFile); paymentConfirmationConsider.setImgFile(imgFile);
int update = baseMapper.updateById(paymentConfirmationConsider); int update = baseMapper.updateById(paymentConfirmationConsider);
@ -202,8 +201,32 @@ public class DgPaymentConfirmationConsiderServiceImpl extends ServiceImpl<DgPaym
//同时往审核流程进程表新增一条记录 //同时往审核流程进程表新增一条记录
String account = DgApplyAmountInfoController.getAccount(); String account = DgApplyAmountInfoController.getAccount();
AuditProcessUtil.save(businessId,account,"财务部经理",auditOpinion,9); AuditProcessUtil.save(businessId,account,"财务部经理",auditOpinion,9);
//更新成功,更新资产部经理数据 //更新成功,更新资产部经理数据及其他人的数据
if (update > 0){ if (update > 0){
//更新法规部经理数据
//根据业务id查询法规部经理数据
QueryWrapper<DgGuaranteeLetterAssignUser> guaranteeLetterAssignUserQueryWrapperFg = new QueryWrapper<>();
guaranteeLetterAssignUserQueryWrapperFg.eq("business_id",businessId).eq("role_id",PromptSuccess.FG_JL_ID);
DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUserFg = guaranteeLetterAssignUserMapper.selectOne(guaranteeLetterAssignUserQueryWrapperFg);
dgGuaranteeLetterAssignUserFg.setStatus(StatusCode.SP_REVIEWED);
guaranteeLetterAssignUserMapper.updateById(dgGuaranteeLetterAssignUserFg);
//更新a角
//根据业务id查询A用户数据
QueryWrapper<DgGuaranteeLetterAssignUser> guaranteeLetterAssignUserQueryWrapperA = new QueryWrapper<>();
guaranteeLetterAssignUserQueryWrapperA.eq("business_id",businessId).eq("role_id",PromptSuccess.DB_A_ID);
DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUserA = guaranteeLetterAssignUserMapper.selectOne(guaranteeLetterAssignUserQueryWrapperA);
dgGuaranteeLetterAssignUserA.setStatus(StatusCode.SP_REVIEWED);
guaranteeLetterAssignUserMapper.updateById(dgGuaranteeLetterAssignUserA);
//更新b角
//根据业务id查询B用户数据
QueryWrapper<DgGuaranteeLetterAssignUser> guaranteeLetterAssignUserQueryWrapperB = new QueryWrapper<>();
guaranteeLetterAssignUserQueryWrapperB.eq("business_id",businessId).eq("role_id",PromptSuccess.DB_B_ID);
DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUserB = guaranteeLetterAssignUserMapper.selectOne(guaranteeLetterAssignUserQueryWrapperB);
dgGuaranteeLetterAssignUserB.setStatus(StatusCode.SP_REVIEWED);
guaranteeLetterAssignUserMapper.updateById(dgGuaranteeLetterAssignUserB);
QueryWrapper<DgGuaranteeLetterAssignUser> guaranteeLetterAssignUserQueryWrapper = new QueryWrapper<>(); QueryWrapper<DgGuaranteeLetterAssignUser> guaranteeLetterAssignUserQueryWrapper = new QueryWrapper<>();
guaranteeLetterAssignUserQueryWrapper.eq("business_id",businessId).eq("role_id", PromptSuccess.ZC_JL_ID); guaranteeLetterAssignUserQueryWrapper.eq("business_id",businessId).eq("role_id", PromptSuccess.ZC_JL_ID);
DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUser = guaranteeLetterAssignUserMapper.selectOne(guaranteeLetterAssignUserQueryWrapper); DgGuaranteeLetterAssignUser dgGuaranteeLetterAssignUser = guaranteeLetterAssignUserMapper.selectOne(guaranteeLetterAssignUserQueryWrapper);
@ -242,8 +265,14 @@ public class DgPaymentConfirmationConsiderServiceImpl extends ServiceImpl<DgPaym
String account = DgApplyAmountInfoController.getAccount(); String account = DgApplyAmountInfoController.getAccount();
AuditProcessUtil.save(businessId,account,"法规部经理",auditOpinion,9); AuditProcessUtil.save(businessId,account,"法规部经理",auditOpinion,9);
Integer companyId = paymentConfirmationConsider.getCompanyId(); Integer companyId = paymentConfirmationConsider.getCompanyId();
//更新成功,添加法规部经理数据 //更新成功,添加法规部经理数据和更新财务部数据
if (update > 0){ if (update > 0){
QueryWrapper<DgPaymentConfirmationConsider> queryWrapperCwb = new QueryWrapper<>();
queryWrapperCwb.eq("business_id",businessId).eq("role_id", PromptSuccess.CWB_ID);
DgPaymentConfirmationConsider paymentConfirmationConsiderCwb = baseMapper.selectOne(queryWrapper);
paymentConfirmationConsiderCwb.setStatus(StatusCode.SP_REVIEWED);
baseMapper.updateById(paymentConfirmationConsiderCwb);
DgLoanNotice loanNotice = new DgLoanNotice(); DgLoanNotice loanNotice = new DgLoanNotice();
loanNotice.setCompanyId(companyId); loanNotice.setCompanyId(companyId);
loanNotice.setBusinessId(businessId); loanNotice.setBusinessId(businessId);
@ -268,8 +297,14 @@ public class DgPaymentConfirmationConsiderServiceImpl extends ServiceImpl<DgPaym
//同时往审核流程进程表新增一条记录 //同时往审核流程进程表新增一条记录
String account = DgApplyAmountInfoController.getAccount(); String account = DgApplyAmountInfoController.getAccount();
AuditProcessUtil.save(businessId,account,"法规部经理",auditOpinion, 9); AuditProcessUtil.save(businessId,account,"法规部经理",auditOpinion, 9);
//更新成功,更新法规部经理数据 //更新成功,更新法规部经理数据和财务部经理数据
if (update > 0){ if (update > 0){
QueryWrapper<DgPaymentConfirmationConsider> queryWrapperCwb = new QueryWrapper<>();
queryWrapperCwb.eq("business_id",businessId).eq("role_id", PromptSuccess.CWB_ID);
DgPaymentConfirmationConsider paymentConfirmationConsiderCwb = baseMapper.selectOne(queryWrapper);
paymentConfirmationConsiderCwb.setStatus(StatusCode.SP_REVIEWED);
baseMapper.updateById(paymentConfirmationConsiderCwb);
QueryWrapper<DgLoanNotice> loanNoticeQueryWrapper = new QueryWrapper<>(); QueryWrapper<DgLoanNotice> loanNoticeQueryWrapper = new QueryWrapper<>();
loanNoticeQueryWrapper.eq("business_id",businessId).eq("role_id", PromptSuccess.FG_JL_ID); loanNoticeQueryWrapper.eq("business_id",businessId).eq("role_id", PromptSuccess.FG_JL_ID);
DgLoanNotice loanNotice = dgLoanNoticeMapper.selectOne(loanNoticeQueryWrapper); DgLoanNotice loanNotice = dgLoanNoticeMapper.selectOne(loanNoticeQueryWrapper);

Loading…
Cancel
Save