| | |
| | | order by d.parent_id, d.order_num
|
| | | </select>
|
| | |
|
| | | <select id="selectDeptListByRoleId" resultType="Integer">
|
| | | <select id="selectDeptListByRoleId" resultType="Long">
|
| | | select d.dept_id
|
| | | from sys_dept d
|
| | | left join sys_role_dept rd on d.dept_id = rd.dept_id
|
| | |
| | |
|
| | | <select id="checkDeptNameUnique" resultMap="SysDeptResult">
|
| | | <include refid="selectDeptVo"/>
|
| | | where dept_name=#{deptName} and parent_id = #{parentId} limit 1
|
| | | where dept_name=#{deptName} and parent_id = #{parentId} and del_flag = '0' limit 1
|
| | | </select>
|
| | |
|
| | | <insert id="insertDept" parameterType="SysDept">
|
| | |
| | | </foreach>
|
| | | </update>
|
| | |
|
| | | <update id="updateDeptSort" parameterType="SysDept">
|
| | | update sys_dept set order_num = #{orderNum} where dept_id = #{deptId}
|
| | | </update>
|
| | | |
| | | <delete id="deleteDeptById" parameterType="Long">
|
| | | update sys_dept set del_flag = '2' where dept_id = #{deptId}
|
| | | </delete>
|
| | |
|
| | | </mapper> |
| | | </mapper> |