From 2cc69af05abf3d3d77c93a8f51e633ccfc5f38c9 Mon Sep 17 00:00:00 2001 From: river <1376754470@qq.com> Date: Wed, 9 Dec 2020 15:55:23 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B4=B7=E5=AE=A1=E4=BC=9A=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../financial/hrms/DeptControllerApi.java | 7 +- .../DgComplianceInvestigationMapper.java | 2 + .../mapper/DgLoanCommitteeConsiderMapper.java | 4 +- .../DgWorkConferenceConsiderMapper.java | 4 + .../DgComplianceInvestigationServiceImpl.java | 104 ++++++++------- .../DgLoanCommitteeConsiderServiceImpl.java | 121 +++++++++--------- .../DgWorkConferenceConsiderServiceImpl.java | 56 ++++---- .../DgComplianceInvestigationMapper.xml | 5 + .../DgLoanCommitteeConsiderMapper.xml | 15 ++- .../DgWorkConferenceConsiderMapper.xml | 10 ++ .../guarantee/DgLoanCommitteeConsider.java | 5 + 11 files changed, 197 insertions(+), 136 deletions(-) diff --git a/dq-financial-api/src/main/java/com/daqing/financial/hrms/DeptControllerApi.java b/dq-financial-api/src/main/java/com/daqing/financial/hrms/DeptControllerApi.java index 4d72d6e9..a07fff28 100644 --- a/dq-financial-api/src/main/java/com/daqing/financial/hrms/DeptControllerApi.java +++ b/dq-financial-api/src/main/java/com/daqing/financial/hrms/DeptControllerApi.java @@ -58,8 +58,11 @@ public interface DeptControllerApi { /** * 查询所有部门及部门下的员工信息 */ - /*@ApiOperation(value = "查询所有部门及部门下的员工信息", notes = "查询所有部门及部门下的员工信息") - ResponseResult trees();*/ + @ApiOperation(value = "查询所有部门及部门下的员工信息(加条件限制,即担保专员、ABC角不能为同一用户)", notes = "查询所有部门及部门下的员工信息") + ResponseResult trees(String account); + + @ApiOperation(value = "查询所有部门及部门下的员工信息(不加条件限制)", notes = "查询所有部门及部门下的员工信息") + ResponseResult empTrees(String account); /** * 查询该部门下所有子部门及部门下的的员工 diff --git a/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/mapper/DgComplianceInvestigationMapper.java b/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/mapper/DgComplianceInvestigationMapper.java index df3f371e..c28b2ff8 100644 --- a/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/mapper/DgComplianceInvestigationMapper.java +++ b/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/mapper/DgComplianceInvestigationMapper.java @@ -74,4 +74,6 @@ public interface DgComplianceInvestigationMapper extends BaseMapper 0) { - // 工作会该条数据存在,表示是工作会驳回的数据,现将当前审批状态更新为已审核 - Boolean result2 = this.getBaseMapper().updateAuditStatusByBusinessId(complianceInvestigation.getBusinessId(), StatusCode.SP_REVIEWED); - if (result2) { - // 再更新工作会的数据为待处理 - result1 = this.getBaseMapper().updateWorkConferenceConsider(complianceInvestigation.getBusinessId(), PromptSuccess.GZU_ID, - StatusCode.SP_IN_REVIEW, StatusCode.CZ_ON_HAND); + // 更新当前审批状态为已审核 + Boolean result2 = this.getBaseMapper().updateAuditStatusByBusinessId(this.getComplianceInvestigation(iid).getBusinessId(), + StatusCode.SP_REVIEWED); + if (result2) { + // 判断当前业务id下的工作会数据是否存在 + DgComplianceInvestigation complianceInvestigation = this.getComplianceInvestigation(iid); + Integer count = this.getBaseMapper().countWorkConferenceConsider(complianceInvestigation.getBusinessId(), PromptSuccess.GZU_ID); + Boolean result1; + if (count > 0) { + // 工作会该条数据存在,表示为工作会驳回数据,更新工作会的数据为审核中和待处理(工作会的业务过程中只会有一条数据) + result1 = this.getBaseMapper().updateWorkConferenceConsider(complianceInvestigation.getBusinessId(), + PromptSuccess.GZU_ID, StatusCode.SP_IN_REVIEW, StatusCode.CZ_ON_HAND); } else { - result1 = false; + // 工作会该条数据不存在,表示不是工作会驳回数据,需要新增一条 + DgWorkConferenceConsider workConferenceConsider = new DgWorkConferenceConsider(); + workConferenceConsider.setCompanyId(complianceInvestigation.getCompanyId()); + workConferenceConsider.setBusinessId(complianceInvestigation.getBusinessId()); + workConferenceConsider.setRoleId(PromptSuccess.GZU_ID); + workConferenceConsider.setAuditStatus(StatusCode.SP_IN_REVIEW); + workConferenceConsider.setOperationStatus(StatusCode.CZ_ON_HAND); + workConferenceConsider.setCreateTime(new Date()); + workConferenceConsider.setUpdateTime(new Date()); + result1 = this.getBaseMapper().insertWorkConferenceConsider(workConferenceConsider); + } + if (result1) { + // 在业务流程表中插入一条法规领导审核成功的数据 + return AuditProcessUtil.save(this.getComplianceInvestigation(iid).getBusinessId(), DgApplyAmountInfoController.getAccount(), + PromptSuccess.FG_LD_NAME, opinion, PromptSuccess.HG_PROCESS_ID); } - } else { - // 工作会该条数据不存在,表示不是工作会驳回数据,需要新增一条 - DgWorkConferenceConsider workConferenceConsider = new DgWorkConferenceConsider(); - workConferenceConsider.setCompanyId(complianceInvestigation.getCompanyId()); - workConferenceConsider.setBusinessId(complianceInvestigation.getBusinessId()); - workConferenceConsider.setRoleId(PromptSuccess.GZU_ID); - workConferenceConsider.setAuditStatus(StatusCode.SP_IN_REVIEW); - workConferenceConsider.setOperationStatus(StatusCode.CZ_ON_HAND); - workConferenceConsider.setCreateTime(new Date()); - workConferenceConsider.setUpdateTime(new Date()); - result1 = this.getBaseMapper().insertWorkConferenceConsider(workConferenceConsider); - } - if (result1) { - // 在业务流程表中插入一条法规领导审核成功的数据 - return AuditProcessUtil.save(this.getComplianceInvestigation(iid).getBusinessId(), DgApplyAmountInfoController.getAccount(), - PromptSuccess.FG_LD_NAME, opinion, PromptSuccess.HG_PROCESS_ID); } } } @@ -433,20 +433,24 @@ public class DgComplianceInvestigationServiceImpl extends ServiceImpl ids) { - if (null == ids || ids.size() == 0){ + if (null == ids || ids.size() == 0) { ExceptionCast.cast(GuaranteeCode.EXCEL_ID_NOT_NULL); } List idList = new ArrayList<>(); diff --git a/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/impl/DgWorkConferenceConsiderServiceImpl.java b/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/impl/DgWorkConferenceConsiderServiceImpl.java index 3444ab56..ac4051de 100644 --- a/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/impl/DgWorkConferenceConsiderServiceImpl.java +++ b/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/impl/DgWorkConferenceConsiderServiceImpl.java @@ -16,7 +16,6 @@ import com.daqing.financial.guarantee.service.IDgWorkConferenceConsiderService; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.daqing.financial.guarantee.util.AuditProcessUtil; import com.daqing.framework.domain.crms.response.CrmsCode; -import com.daqing.framework.domain.guarantee.DgComplianceInvestigation; import com.daqing.framework.domain.guarantee.DgLoanCommitteeConsider; import com.daqing.framework.domain.guarantee.DgWorkConferenceConsider; import com.daqing.framework.domain.guarantee.GuaranteeCode; @@ -74,7 +73,7 @@ public class DgWorkConferenceConsiderServiceImpl extends ServiceImpl dgWorkConferencePOS = list.getRecords(); System.out.println(dgWorkConferencePOS); Integer[] userIds = new Integer[dgWorkConferencePOS.size() * 5]; + // 获取所有的userId for (int i = 0; i < userIds.length; i += 5) { for (int j = i / 5; j < i / 5 + 1; j++) { userIds[i] = dgWorkConferencePOS.get(j).getAUserId(); @@ -162,20 +162,24 @@ public class DgWorkConferenceConsiderServiceImpl extends ServiceImpl + + + UPDATE dg_compliance_investigation SET user_id = #{userId} WHERE id = #{id} + + diff --git a/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgLoanCommitteeConsiderMapper.xml b/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgLoanCommitteeConsiderMapper.xml index 1a4c3690..444d0d27 100644 --- a/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgLoanCommitteeConsiderMapper.xml +++ b/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgLoanCommitteeConsiderMapper.xml @@ -70,16 +70,16 @@ WHERE id = #{lr.id} - + UPDATE dg_loan_committee_consider - SET agree_person = #{agreePerson} + SET all_person = #{allPerson} WHERE business_id = #{businessId} - + @@ -113,7 +113,7 @@ @@ -137,4 +137,9 @@ WHERE business_id = #{businessId} AND role_id = #{roleId} + + + UPDATE dg_loan_committee_consider SET user_id = #{userId} WHERE id = #{id} + + diff --git a/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgWorkConferenceConsiderMapper.xml b/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgWorkConferenceConsiderMapper.xml index 00c90df5..ed325ae5 100644 --- a/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgWorkConferenceConsiderMapper.xml +++ b/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgWorkConferenceConsiderMapper.xml @@ -117,4 +117,14 @@ UPDATE dg_work_conference_consider SET operation_status = #{operationStatus},opinion = #{opinion} WHERE id = #{id} + + + UPDATE dg_work_conference_consider SET operation_status = #{operationStatus} WHERE id = #{id} + + + + + UPDATE dg_work_conference_consider SET user_id = #{userId} WHERE id = #{id} + + diff --git a/dq-framework-model/src/main/java/com/daqing/framework/domain/guarantee/DgLoanCommitteeConsider.java b/dq-framework-model/src/main/java/com/daqing/framework/domain/guarantee/DgLoanCommitteeConsider.java index 286ec025..c89075b4 100644 --- a/dq-framework-model/src/main/java/com/daqing/framework/domain/guarantee/DgLoanCommitteeConsider.java +++ b/dq-framework-model/src/main/java/com/daqing/framework/domain/guarantee/DgLoanCommitteeConsider.java @@ -90,6 +90,11 @@ public class DgLoanCommitteeConsider implements Serializable { */ private String disagreePerson; + /** + * 所有的贷审委员 + */ + private String allPerson; + /** * 附件(会议记录) */