|
@@ -48,6 +48,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
order by d.parent_id, d.order_num
|
|
|
</select>
|
|
|
|
|
|
+
|
|
|
+ <select id="selectDeptsList" resultMap="SysDeptResult">
|
|
|
+ <include refid="selectDeptVo"/>
|
|
|
+ where d.del_flag = '0'
|
|
|
+ order by d.parent_id, d.order_num
|
|
|
+ </select>
|
|
|
+
|
|
|
<select id="validateHasChirld" parameterType="java.util.List" resultMap="SysDeptResult">
|
|
|
SELECT a.id as id, count(1) as num FROM sys_dept a LEFT JOIN sys_dept b on a.id = b.parent_id WHERE b.parent_id in
|
|
|
<foreach collection="depts" item="dept" index="index" separator="," open="(" close=")">
|
|
@@ -178,7 +185,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
|
<select id="getParentById" resultMap="SysDeptResult">
|
|
|
<include refid="selectDeptVo"/>
|
|
|
- where d.parent_id = #{deptId}
|
|
|
+ where d.id = #{parentId}
|
|
|
</select>
|
|
|
|
|
|
</mapper>
|