update 优化 重构代码逻辑 封装简化方法

This commit is contained in:
疯狂的狮子Li
2025-07-02 13:45:53 +08:00
parent c519815fd4
commit 06b145cb83
18 changed files with 236 additions and 157 deletions

View File

@@ -3,6 +3,7 @@ package org.dromara.system.api;
import org.dromara.system.api.domain.vo.RemoteDeptVo;
import java.util.List;
import java.util.Map;
/**
* 部门服务
@@ -34,4 +35,12 @@ public interface RemoteDeptService {
*/
List<RemoteDeptVo> selectDeptsByList();
/**
* 根据部门 ID 列表查询部门名称映射关系
*
* @param deptIds 部门 ID 列表
* @return Map其中 key 为部门 IDvalue 为对应的部门名称
*/
Map<Long, String> selectDeptNamesByIds(List<Long> deptIds);
}

View File

@@ -0,0 +1,21 @@
package org.dromara.system.api;
import java.util.List;
import java.util.Map;
/**
* 岗位服务
*
* @author Lion Li
*/
public interface RemotePostService {
/**
* 根据岗位 ID 列表查询岗位名称映射关系
*
* @param postIds 岗位 ID 列表
* @return Map其中 key 为岗位 IDvalue 为对应的岗位名称
*/
Map<Long, String> selectPostNamesByIds(List<Long> postIds);
}

View File

@@ -0,0 +1,21 @@
package org.dromara.system.api;
import java.util.List;
import java.util.Map;
/**
* 角色服务
*
* @author Lion Li
*/
public interface RemoteRoleService {
/**
* 根据角色 ID 列表查询角色名称映射关系
*
* @param roleIds 角色 ID 列表
* @return Map其中 key 为角色 IDvalue 为对应的角色名称
*/
Map<Long, String> selectRoleNamesByIds(List<Long> roleIds);
}

View File

@@ -165,28 +165,4 @@ public interface RemoteUserService {
*/
Map<Long, String> selectUserNamesByIds(List<Long> userIds);
/**
* 根据角色 ID 列表查询角色名称映射关系
*
* @param roleIds 角色 ID 列表
* @return Map其中 key 为角色 IDvalue 为对应的角色名称
*/
Map<Long, String> selectRoleNamesByIds(List<Long> roleIds);
/**
* 根据部门 ID 列表查询部门名称映射关系
*
* @param deptIds 部门 ID 列表
* @return Map其中 key 为部门 IDvalue 为对应的部门名称
*/
Map<Long, String> selectDeptNamesByIds(List<Long> deptIds);
/**
* 根据岗位 ID 列表查询岗位名称映射关系
*
* @param postIds 岗位 ID 列表
* @return Map其中 key 为岗位 IDvalue 为对应的岗位名称
*/
Map<Long, String> selectPostNamesByIds(List<Long> postIds);
}