From 38d775fa2ccd433c727a5b7cec8bed02493df1ec Mon Sep 17 00:00:00 2001
From: zhongrj <123456>
Date: Thu, 18 Aug 2022 09:00:40 +0800
Subject: [PATCH] mq 相关配置去除,启动配置修改

---
 src/main/java/org/springblade/modules/system/mapper/UserMapper.xml |   21 ++++++++++++++++++---
 1 files changed, 18 insertions(+), 3 deletions(-)

diff --git a/src/main/java/org/springblade/modules/system/mapper/UserMapper.xml b/src/main/java/org/springblade/modules/system/mapper/UserMapper.xml
index 228bc9c..81e0138 100644
--- a/src/main/java/org/springblade/modules/system/mapper/UserMapper.xml
+++ b/src/main/java/org/springblade/modules/system/mapper/UserMapper.xml
@@ -360,7 +360,7 @@
             and account like concat('%', #{user.account},'%')
         </if>
         <if test="user.roleId!=null and user.roleId != ''">
-            and br.role_alias = '公安管理员'
+            and (br.role_alias = '公安管理员' or br.role_alias = '民警')
         </if>
         <if test="user.realName!=null and user.realName != ''">
             and real_name like concat(concat('%', #{user.realName}),'%')
@@ -656,7 +656,14 @@
          blade_dept bd
          on
          bu.dept_id = bd.id
-        where securitynumber = #{securityNumber}
+        where
+        1=1
+        <if test="securityNumber!=null and securityNumber!=''">
+            and securitynumber = #{securityNumber}
+        </if>
+        <if test="cardid!=null and cardid!=''">
+            and cardid = #{cardid}
+        </if>
         and bu.status = 1
         and bu.is_deleted = 0
     </select>
@@ -985,7 +992,12 @@
         <if test="user.cardid!=null and user.cardid != ''">
             and bu.cardid like concat('%', #{user.cardid},'%')
         </if>
-        ORDER BY bu.id desc
+        <if test="user.sortName!=null and user.sortName!=''">
+            ORDER BY bu.${user.sortName} ${user.sort},bu.id desc
+        </if>
+        <if test="user.sortName==null or user.sortName==''">
+            ORDER BY bu.id desc
+        </if>
     </select>
 
     <!--查询押运人员编码不为null的保安信息-->
@@ -1114,6 +1126,9 @@
         )
     </select>
 
+    <select id="getUserById" resultType="org.springblade.modules.system.entity.User">
+        select * from blade_user where id = #{id}
+    </select>
 
 
 </mapper>

--
Gitblit v1.9.3