浏览代码

删除无用接口

bihuisong 1 月之前
父节点
当前提交
a4e18d9444

+ 0 - 9
src/main/java/com/ruoyi/system/controller/SysDeptController.java

@@ -454,13 +454,4 @@ public class SysDeptController extends BaseController {
         return AjaxResult.success("查询成功",deptService.selectDeptListByDeptNames(deptName));
     }
 
-    /**
-     * 根据用户名查询dept_id, parent_id, ancestors, dept_name
-     */
-    @ApiOperation(value = "根据用户名查询dept_id, parent_id, ancestors, dept_name", notes = "根据用户名查询dept_id, parent_id, ancestors, dept_name")
-    @GetMapping("/findDeptIdByUserName/{userName}")
-    public R findDeptIdByUserName(@PathVariable("userName") String userName) {
-        return R.ok(deptService.findDeptIdByUserName(userName));
-    }
-
 }

+ 0 - 5
src/main/java/com/ruoyi/system/mapper/SysDeptMapper.java

@@ -233,9 +233,4 @@ public interface SysDeptMapper {
      */
     Integer thisDeptIdIsParentIdChild(@Param("deptId") Long deptId, @Param("parentId") Long parentId);
 
-    /**
-     * 根据用户名查询dept_id, parent_id, ancestors, dept_name
-     */
-    SysDept findDeptIdByUserName(@Param("userName") String userName);
-
 }

+ 0 - 5
src/main/java/com/ruoyi/system/service/ISysDeptService.java

@@ -232,9 +232,4 @@ public interface ISysDeptService
      */
     public List<SysDept> selectDeptListByDeptNames(String[] deptName);
 
-    /**
-     * 根据用户名查询dept_id, parent_id, ancestors, dept_name
-     * */
-    SysDept findDeptIdByUserName(String userName);
-
 }

+ 0 - 5
src/main/java/com/ruoyi/system/service/impl/SysDeptServiceImpl.java

@@ -496,9 +496,4 @@ public class SysDeptServiceImpl implements ISysDeptService
         return deptMapper.selectDeptListImportExcel(deptName);
     }
 
-    @Override
-    public SysDept findDeptIdByUserName(String userName) {
-        return deptMapper.findDeptIdByUserName(userName);
-    }
-
 }

+ 0 - 17
src/main/resources/mapper/system/SysDeptMapper.xml

@@ -621,21 +621,4 @@
             #{item}
         </foreach>
     </select>
-    <select id="findDeptIdByUserName" parameterType="SysDept" resultMap="SysDeptResult">
-        SELECT
-            dept.dept_id,
-            dept.parent_id,
-            dept.ancestors,
-            dept.dept_name,
-            su.user_name
-        FROM
-            sys_user su
-                LEFT JOIN sys_user_dept ud ON ud.user_id = su.user_id
-                LEFT JOIN sys_dept dept ON ud.dept_id = dept.dept_id
-        WHERE
-            su.del_flag = 0
-          AND dept.del_flag = 0
-          AND su.user_name = #{userName}
-            LIMIT 1
-    </select>
 </mapper>