소스 검색

角色列表返回类型保持一致

RuoYi 4 년 전
부모
커밋
a8eba6949e

+ 1 - 1
ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/mapper/SysRoleMapper.java

@@ -40,7 +40,7 @@ public interface SysRoleMapper
40 40
      * @param userId 用户ID
41 41
      * @return 选中角色ID列表
42 42
      */
43
-    public List<Integer> selectRoleListByUserId(Long userId);
43
+    public List<Long> selectRoleListByUserId(Long userId);
44 44
 
45 45
     /**
46 46
      * 通过角色ID查询角色

+ 1 - 1
ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/service/ISysRoleService.java

@@ -49,7 +49,7 @@ public interface ISysRoleService
49 49
      * @param userId 用户ID
50 50
      * @return 选中角色ID列表
51 51
      */
52
-    public List<Integer> selectRoleListByUserId(Long userId);
52
+    public List<Long> selectRoleListByUserId(Long userId);
53 53
 
54 54
     /**
55 55
      * 通过角色ID查询角色

+ 1 - 1
ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysRoleServiceImpl.java

@@ -122,7 +122,7 @@ public class SysRoleServiceImpl implements ISysRoleService
122 122
      * @return 选中角色ID列表
123 123
      */
124 124
     @Override
125
-    public List<Integer> selectRoleListByUserId(Long userId)
125
+    public List<Long> selectRoleListByUserId(Long userId)
126 126
     {
127 127
         return roleMapper.selectRoleListByUserId(userId);
128 128
     }

+ 1 - 1
ruoyi-modules/ruoyi-system/src/main/resources/mapper/system/SysRoleMapper.xml

@@ -65,7 +65,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
65 65
 		<include refid="selectRoleVo"/>
66 66
 	</select>
67 67
 	
68
-	<select id="selectRoleListByUserId" parameterType="Long" resultType="Integer">
68
+	<select id="selectRoleListByUserId" parameterType="Long" resultType="Long">
69 69
 		select r.role_id
70 70
         from sys_role r
71 71
 	        left join sys_user_role ur on ur.role_id = r.role_id