From 3d453a41ccd7c69a40bd9bfa31f8c5b159513b6b Mon Sep 17 00:00:00 2001
From: liusheng <337615773@qq.com>
Date: 星期五, 10 十月 2025 16:09:00 +0800
Subject: [PATCH] 修改BUG

---
 ruoyi-system/src/main/resources/mapper/system/SysDeptMapper.xml |    7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/ruoyi-system/src/main/resources/mapper/system/SysDeptMapper.xml b/ruoyi-system/src/main/resources/mapper/system/SysDeptMapper.xml
index 6830b7a..3b91c20 100644
--- a/ruoyi-system/src/main/resources/mapper/system/SysDeptMapper.xml
+++ b/ruoyi-system/src/main/resources/mapper/system/SysDeptMapper.xml
@@ -77,9 +77,12 @@
         <if test="hisParentId != null and hisParentId != ''">
             AND his_parent_id = #{hisParentId}
         </if>
+            <if test="orgid != null and orgid != ''">
+            AND orgid = #{orgid}
+        </if>
         <!-- 鏁版嵁鑼冨洿杩囨护 -->
         ${params.dataScope}
-        order by d.parent_id, d.order_num
+        order by d.dept_type asc, d.parent_id, d.order_num
     </select>
 
     <select id="selectDeptListByRoleId" resultType="Long">
@@ -247,7 +250,7 @@
 
     <delete id="deleteDeptById" parameterType="Long">
         update sys_dept
-        set del_flag = '2'
+        set del_flag = '1'
         where dept_id = #{deptId}
     </delete>
 

--
Gitblit v1.9.3