Browse Source

查询BUG修改

anderx 3 years ago
parent
commit
045d59487c
1 changed files with 2 additions and 2 deletions
  1. 2 2
      src/main/java/com/goafanti/common/mapper/UserMapperExt.xml

+ 2 - 2
src/main/java/com/goafanti/common/mapper/UserMapperExt.xml

@@ -1848,7 +1848,7 @@ inner join(
 				left join user y on x1.uid=y.id where x1.type=1
 				and x1.status=0 and y.integrity=1 group by aid,uid)x group by aid) i on a.id=i.aid
 	where a.status='正常'
-	<if test="deps!=null">
+	<if test="deps!=null  and deps.size()>0">
 	and a.department_id in
 		<foreach close=")" collection="deps" item="depId" open="(" separator=",">
 			#{depId}
@@ -1876,7 +1876,7 @@ inner join(
 				left join user y on x1.uid=y.id where x1.type=1
 				and x1.status=0 and y.integrity=1 group by aid,uid)x group by aid) i on a.id=i.aid
 	where a.status='正常'
-	<if test="depId!=null ">
+	<if test="deps!=null and deps.size()>0">
 	and a.department_id in
 		<foreach close=")" collection="deps" item="depId" open="(" separator=",">
 			#{depId}