|
@@ -479,10 +479,8 @@ public class LoanApplicationServiceImpl implements ILoanApplicationService {
|
|
|
return AjaxResult.success();
|
|
|
//审核流程结束
|
|
|
} else if (THR.equals(auditType) && Integer.parseInt(auditSchedule) > 2) {
|
|
|
- //进入到A角色申诉状态
|
|
|
- loanApplication.setLoanSchedule(TWO);
|
|
|
+ //进入到A角色申诉状态保留当前项目状态,只把audit_type改为申诉
|
|
|
loanApplication.setAuditType(FOR);
|
|
|
- loanApplication.setAuditSchedule(TWO);
|
|
|
loanApplicationMapper.updateLoanApplication(loanApplication);
|
|
|
//给A角色发送待办提醒
|
|
|
WaitRemind waitRemind = new WaitRemind();
|
|
@@ -577,7 +575,7 @@ public class LoanApplicationServiceImpl implements ILoanApplicationService {
|
|
|
}
|
|
|
}
|
|
|
//审核流程结束
|
|
|
- } else if (auditSchedule.equals(SEV)) {
|
|
|
+ } /*else if (auditSchedule.equals(SEV)) {
|
|
|
loanApplication.setLoanSchedule(String.valueOf(Integer.parseInt(loanScheduleOld) + 1));
|
|
|
loanApplication.setAuditSchedule(auditSchedule);
|
|
|
loanApplication.setAuditType(auditType);
|
|
@@ -600,7 +598,7 @@ public class LoanApplicationServiceImpl implements ILoanApplicationService {
|
|
|
waitRemindList.add(waitRemindManager);
|
|
|
}
|
|
|
}
|
|
|
- } else {
|
|
|
+ }*/ else {
|
|
|
loanApplication.setLoanSchedule(String.valueOf(Integer.parseInt(loanScheduleOld) + 1));
|
|
|
loanApplication.setAuditSchedule(String.valueOf(Integer.parseInt(auditSchedule) + 1));
|
|
|
loanApplication.setAuditType(ONE);
|
|
@@ -647,19 +645,20 @@ public class LoanApplicationServiceImpl implements ILoanApplicationService {
|
|
|
*/
|
|
|
@Override
|
|
|
public AjaxResult ss(LoanApplication loanApplication) {
|
|
|
- //先判断当前人是否是A角色
|
|
|
+ //先判断当前人是否是A角色或者B角色
|
|
|
Long userId = SecurityUtils.getUserId();
|
|
|
Long aLong = loanApplication.getaUserId();
|
|
|
- if (!Objects.equals(userId, aLong)) {
|
|
|
+ Long bLong = loanApplication.getbUserId();
|
|
|
+ if (!Objects.equals(userId, aLong) || !Objects.equals(userId, bLong)) {
|
|
|
return AjaxResult.error("当前您无权限申诉,请联系管理员");
|
|
|
}
|
|
|
- loanApplication.setLoanSchedule(TWO);
|
|
|
+ //申诉中判断评审会进度不是1等待上会,则重置为1
|
|
|
+ loanApplication.setReviewSchedule(ONE);
|
|
|
//进入待审核
|
|
|
loanApplication.setAuditType(ONE);
|
|
|
- loanApplication.setAuditSchedule(TWO);
|
|
|
loanApplicationMapper.updateLoanApplication(loanApplication);
|
|
|
//删除基础附件外的所有附件
|
|
|
- loanApplicationFjMapper.deleteLoanApplicationFjByLoanApplicationIdAndBigType(loanApplication.getLoanApplicationId());
|
|
|
+ //loanApplicationFjMapper.deleteLoanApplicationFjByLoanApplicationIdAndBigType(loanApplication.getLoanApplicationId());
|
|
|
|
|
|
//业务审核意见
|
|
|
ReviewComments reviewComments = new ReviewComments();
|
|
@@ -685,10 +684,10 @@ public class LoanApplicationServiceImpl implements ILoanApplicationService {
|
|
|
String auditSchedule = loanApplication.getAuditSchedule();
|
|
|
String auditType = loanApplication.getAuditType();
|
|
|
String reviewSchedule = loanApplication.getReviewSchedule();
|
|
|
- if (!loanSchedule.equals(SIX) || !auditSchedule.equals(SEV) || !auditType.equals(ONE)){
|
|
|
+ //判断项目状态
|
|
|
+ if (!loanSchedule.equals(SIX) || !auditSchedule.equals(SEV) || !auditType.equals(ONE)) {
|
|
|
return AjaxResult.error("当前项目状态异常,不允许上会");
|
|
|
}
|
|
|
- //判断项目状态必须是
|
|
|
int rows = loanApplicationMapper.updateLoanApplication(loanApplication);
|
|
|
//给A角色发送上会审核信息
|
|
|
WaitRemind waitRemindManager = new WaitRemind();
|
|
@@ -698,11 +697,11 @@ public class LoanApplicationServiceImpl implements ILoanApplicationService {
|
|
|
waitRemindManager.setRemindTime(DateUtils.getNowDate());
|
|
|
waitRemindManager.setRemindType(FIV);
|
|
|
waitRemindManager.setReadUserId(loanApplication.getaUserId().toString());
|
|
|
- String result = "通过";
|
|
|
- if (TWO.equals(reviewSchedule)){
|
|
|
- result = "不通过";
|
|
|
+ String result = "通过";
|
|
|
+ if (TWO.equals(reviewSchedule)) {
|
|
|
+ result = "不通过";
|
|
|
}
|
|
|
- waitRemindManager.setRemindContent(loanApplication.getEnterpriseName() + "的上会审核信息申请"+result);
|
|
|
+ waitRemindManager.setRemindContent(loanApplication.getEnterpriseName() + "的上会审核信息申请" + result);
|
|
|
//给管理员发送待办提醒
|
|
|
waitRemindManager.setReadUserId(String.valueOf(loanApplication.getaUserId()));
|
|
|
waitRemindMapper.insertWaitRemind(waitRemindManager);
|
|
@@ -710,7 +709,7 @@ public class LoanApplicationServiceImpl implements ILoanApplicationService {
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
- * 7:合同签约 8:放款合规风险审核 9:放款通知
|
|
|
+ * 7:合同签约 8:放款合规风险审核推进到下一步功能
|
|
|
*
|
|
|
* @param loanApplication
|
|
|
* @return
|
|
@@ -718,17 +717,19 @@ public class LoanApplicationServiceImpl implements ILoanApplicationService {
|
|
|
@Override
|
|
|
public AjaxResult schedule(LoanApplication loanApplication) {
|
|
|
String loanSchedule = loanApplication.getLoanSchedule();
|
|
|
- if (!SEV.equals(loanSchedule) && !EIG.equals(loanSchedule) && !NIN.equals(loanSchedule)) {
|
|
|
+ if (!SEV.equals(loanSchedule) && !EIG.equals(loanSchedule)) {
|
|
|
return AjaxResult.error("当前项目进度错误。");
|
|
|
}
|
|
|
LoanApplication application = new LoanApplication();
|
|
|
application.setLoanApplicationId(loanApplication.getLoanApplicationId());
|
|
|
- if (NIN.equals(loanSchedule)) {
|
|
|
+ application.setAuditType(ONE);
|
|
|
+ if (SEV.equals(loanSchedule)){
|
|
|
+ application.setLoanSchedule(EIG);
|
|
|
+ application.setAuditSchedule(NIN);
|
|
|
+ }
|
|
|
+ if (EIG.equals(loanSchedule)){
|
|
|
application.setLoanSchedule(NIN);
|
|
|
- application.setAuditType(TWO);
|
|
|
- } else {
|
|
|
- application.setLoanSchedule(String.valueOf(Integer.parseInt(loanSchedule) + 1));
|
|
|
- application.setAuditType(ONE);
|
|
|
+ application.setAuditSchedule(TEN);
|
|
|
}
|
|
|
loanApplicationMapper.updateLoanApplication(application);
|
|
|
|
|
@@ -767,9 +768,7 @@ public class LoanApplicationServiceImpl implements ILoanApplicationService {
|
|
|
ReviewComments reviewComments = new ReviewComments();
|
|
|
reviewComments.setLoanApplicationId(loanApplication.getLoanApplicationId());
|
|
|
reviewComments.setLoanApplicationNumber(loanApplication.getLoanApplicationNumber());
|
|
|
- //把7:合同签约 8:放款合规风险审核 9:放款通知 变成业务审核意见表中对应编号需要+1
|
|
|
- int i = Integer.parseInt(loanApplication.getLoanSchedule()) + 1;
|
|
|
- reviewComments.setAuditSchedule(String.valueOf(i));
|
|
|
+ reviewComments.setAuditSchedule(loanApplication.getAuditSchedule());
|
|
|
reviewComments.setAuditType(TWO);
|
|
|
reviewComments.setAuditTime(DateUtils.getNowDate());
|
|
|
reviewComments.setCreateBy(SecurityUtils.getUsername());
|