From 1cae825d44372fa71004cc4585522d0dc2960917 Mon Sep 17 00:00:00 2001 From: chen <1251790704@qq.com> Date: Fri, 4 Dec 2020 11:47:29 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A7=A3=E5=86=B3bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../guarantee/controller/DgApplyAmountInfoController.java | 6 +----- .../guarantee/service/IDgApplyAmountInfoService.java | 2 ++ .../service/impl/DgApplyAmountInfoServiceImpl.java | 8 ++++++++ .../impl/DgGuaranteeLetterAssignUserServiceImpl.java | 2 +- .../guarantee/service/impl/DgLoanNoticeServiceImpl.java | 3 ++- .../guarantee/DgGuaranteeLetterAssignUserMapper.xml | 2 +- .../resources/mapper/guarantee/DgLoanNoticeMapper.xml | 2 +- .../guarantee/DgPaymentConfirmationConsiderMapper.xml | 2 +- 8 files changed, 17 insertions(+), 10 deletions(-) diff --git a/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/controller/DgApplyAmountInfoController.java b/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/controller/DgApplyAmountInfoController.java index 6a15f03c..1a5a7dd2 100644 --- a/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/controller/DgApplyAmountInfoController.java +++ b/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/controller/DgApplyAmountInfoController.java @@ -79,11 +79,7 @@ public class DgApplyAmountInfoController implements DgApplyAmountInfoControllerA @GetMapping("/getRoles") @ApiOperation(value = "获取当前用户角色") public ResponseResult getRoles(){ - HttpServletRequest request = ((ServletRequestAttributes) RequestContextHolder.getRequestAttributes()).getRequest(); - String token = request.getHeader("token"); - String userId = RedisUtil.get("dq:token:" + token); - //获取当前用户拥有的角色ids - String roleIds = RedisUtil.get("dq:userRole:" + userId); + String roleIds = applyAmountInfoService.getRoles(); return ResponseResult.SUCCESS(roleIds); } diff --git a/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/IDgApplyAmountInfoService.java b/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/IDgApplyAmountInfoService.java index 1195e4a0..c1b5b286 100644 --- a/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/IDgApplyAmountInfoService.java +++ b/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/IDgApplyAmountInfoService.java @@ -32,4 +32,6 @@ public interface IDgApplyAmountInfoService extends IService { Boolean excelExport(List ids,HttpServletResponse response); int approvalBusinessApplication(Integer id, Integer status, String remark, Integer companyId); + + String getRoles(); } diff --git a/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/impl/DgApplyAmountInfoServiceImpl.java b/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/impl/DgApplyAmountInfoServiceImpl.java index 3d09f134..e7b1e568 100644 --- a/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/impl/DgApplyAmountInfoServiceImpl.java +++ b/dq-financial-guarantee/src/main/java/com/daqing/financial/guarantee/service/impl/DgApplyAmountInfoServiceImpl.java @@ -80,6 +80,14 @@ public class DgApplyAmountInfoServiceImpl extends ServiceImpl 0 ? "驳回更新财务部经理成功" : "驳回更新财务部经理失败"); diff --git a/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgGuaranteeLetterAssignUserMapper.xml b/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgGuaranteeLetterAssignUserMapper.xml index b9419ca1..8cc0fc10 100644 --- a/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgGuaranteeLetterAssignUserMapper.xml +++ b/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgGuaranteeLetterAssignUserMapper.xml @@ -51,7 +51,7 @@ AND (lau.user_id = #{userId} or lau.user_id is null OR lau.user_id = '') - AND aai.business_code LIKE CONCAT('%',#{customerNumberOrName},'%') OR cc.name LIKE CONCAT('%',#{customerNumberOrName},'%') + AND (aai.business_code LIKE CONCAT('%' #{customerNumberOrName} '%') OR cc.name LIKE CONCAT('%' #{customerNumberOrName} '%')) AND lau.status = #{status} diff --git a/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgLoanNoticeMapper.xml b/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgLoanNoticeMapper.xml index de654666..41ef5344 100644 --- a/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgLoanNoticeMapper.xml +++ b/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgLoanNoticeMapper.xml @@ -49,7 +49,7 @@ AND (ln.consider_id = #{userId} or ln.consider_id is null OR ln.consider_id = '') - AND aai.business_code LIKE CONCAT('%',#{customerNumberOrName},'%') OR cc.name LIKE CONCAT('%',#{customerNumberOrName},'%') + AND (aai.business_code LIKE CONCAT('%' #{customerNumberOrName} '%') OR cc.name LIKE CONCAT('%' #{customerNumberOrName} '%')) AND ln.status = #{status} diff --git a/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgPaymentConfirmationConsiderMapper.xml b/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgPaymentConfirmationConsiderMapper.xml index fa3ead69..4c67b36c 100644 --- a/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgPaymentConfirmationConsiderMapper.xml +++ b/dq-financial-guarantee/src/main/resources/mapper/guarantee/DgPaymentConfirmationConsiderMapper.xml @@ -53,7 +53,7 @@ AND (pcc.consider_id = #{userId} or pcc.consider_id is null OR pcc.consider_id = '') - AND aai.business_code LIKE CONCAT('%',#{customerNumberOrName},'%') OR cc.name LIKE CONCAT('%',#{customerNumberOrName},'%') + AND (aai.business_code LIKE CONCAT('%' #{customerNumberOrName} '%') OR cc.name LIKE CONCAT('%' #{customerNumberOrName} '%')) AND pcc.status = #{status}