Merge branch 'master' of https://gitee.com/y_project/RuoYi-Vue
This commit is contained in:
commit
dbd8c98ff9
8
pom.xml
8
pom.xml
@ -25,8 +25,8 @@
|
|||||||
<mybatis-spring-boot.version>2.2.0</mybatis-spring-boot.version>
|
<mybatis-spring-boot.version>2.2.0</mybatis-spring-boot.version>
|
||||||
<pagehelper.boot.version>1.4.0</pagehelper.boot.version>
|
<pagehelper.boot.version>1.4.0</pagehelper.boot.version>
|
||||||
<fastjson.version>1.2.78</fastjson.version>
|
<fastjson.version>1.2.78</fastjson.version>
|
||||||
<oshi.version>5.8.0</oshi.version>
|
<oshi.version>5.8.2</oshi.version>
|
||||||
<jna.version>5.8.0</jna.version>
|
<jna.version>5.9.0</jna.version>
|
||||||
<commons.io.version>2.11.0</commons.io.version>
|
<commons.io.version>2.11.0</commons.io.version>
|
||||||
<commons.fileupload.version>1.4</commons.fileupload.version>
|
<commons.fileupload.version>1.4</commons.fileupload.version>
|
||||||
<commons.collections.version>3.2.2</commons.collections.version>
|
<commons.collections.version>3.2.2</commons.collections.version>
|
||||||
@ -242,7 +242,7 @@
|
|||||||
<repository>
|
<repository>
|
||||||
<id>public</id>
|
<id>public</id>
|
||||||
<name>aliyun nexus</name>
|
<name>aliyun nexus</name>
|
||||||
<url>http://maven.aliyun.com/nexus/content/groups/public/</url>
|
<url>https://maven.aliyun.com/repository/public</url>
|
||||||
<releases>
|
<releases>
|
||||||
<enabled>true</enabled>
|
<enabled>true</enabled>
|
||||||
</releases>
|
</releases>
|
||||||
@ -253,7 +253,7 @@
|
|||||||
<pluginRepository>
|
<pluginRepository>
|
||||||
<id>public</id>
|
<id>public</id>
|
||||||
<name>aliyun nexus</name>
|
<name>aliyun nexus</name>
|
||||||
<url>http://maven.aliyun.com/nexus/content/groups/public/</url>
|
<url>https://maven.aliyun.com/repository/public</url>
|
||||||
<releases>
|
<releases>
|
||||||
<enabled>true</enabled>
|
<enabled>true</enabled>
|
||||||
</releases>
|
</releases>
|
||||||
|
@ -39,7 +39,7 @@ public interface SysRoleMapper
|
|||||||
* @param userId 用户ID
|
* @param userId 用户ID
|
||||||
* @return 选中角色ID列表
|
* @return 选中角色ID列表
|
||||||
*/
|
*/
|
||||||
public List<Integer> selectRoleListByUserId(Long userId);
|
public List<Long> selectRoleListByUserId(Long userId);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 通过角色ID查询角色
|
* 通过角色ID查询角色
|
||||||
|
@ -49,7 +49,7 @@ public interface ISysRoleService
|
|||||||
* @param userId 用户ID
|
* @param userId 用户ID
|
||||||
* @return 选中角色ID列表
|
* @return 选中角色ID列表
|
||||||
*/
|
*/
|
||||||
public List<Integer> selectRoleListByUserId(Long userId);
|
public List<Long> selectRoleListByUserId(Long userId);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 通过角色ID查询角色
|
* 通过角色ID查询角色
|
||||||
|
@ -122,7 +122,7 @@ public class SysRoleServiceImpl implements ISysRoleService
|
|||||||
* @return 选中角色ID列表
|
* @return 选中角色ID列表
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public List<Integer> selectRoleListByUserId(Long userId)
|
public List<Long> selectRoleListByUserId(Long userId)
|
||||||
{
|
{
|
||||||
return roleMapper.selectRoleListByUserId(userId);
|
return roleMapper.selectRoleListByUserId(userId);
|
||||||
}
|
}
|
||||||
|
@ -65,7 +65,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<include refid="selectRoleVo"/>
|
<include refid="selectRoleVo"/>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="selectRoleListByUserId" parameterType="Long" resultType="Integer">
|
<select id="selectRoleListByUserId" parameterType="Long" resultType="Long">
|
||||||
select r.role_id
|
select r.role_id
|
||||||
from sys_role r
|
from sys_role r
|
||||||
left join sys_user_role ur on ur.role_id = r.role_id
|
left join sys_user_role ur on ur.role_id = r.role_id
|
||||||
|
@ -86,7 +86,7 @@ function filterChildren(childrenMap, lastRouter = false) {
|
|||||||
var children = []
|
var children = []
|
||||||
childrenMap.forEach((el, index) => {
|
childrenMap.forEach((el, index) => {
|
||||||
if (el.children && el.children.length) {
|
if (el.children && el.children.length) {
|
||||||
if (el.component === 'ParentView') {
|
if (el.component === 'ParentView' && !lastRouter) {
|
||||||
el.children.forEach(c => {
|
el.children.forEach(c => {
|
||||||
c.path = el.path + '/' + c.path
|
c.path = el.path + '/' + c.path
|
||||||
if (c.children && c.children.length) {
|
if (c.children && c.children.length) {
|
||||||
@ -106,8 +106,13 @@ function filterChildren(childrenMap, lastRouter = false) {
|
|||||||
return children
|
return children
|
||||||
}
|
}
|
||||||
|
|
||||||
export const loadView = (view) => { // 路由懒加载
|
export const loadView = (view) => {
|
||||||
|
if (process.env.NODE_ENV === 'development') {
|
||||||
return (resolve) => require([`@/views/${view}`], resolve)
|
return (resolve) => require([`@/views/${view}`], resolve)
|
||||||
|
} else {
|
||||||
|
// 使用 import 实现生产环境的路由懒加载
|
||||||
|
return () => import(`@/views/${view}`)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
export default permission
|
export default permission
|
||||||
|
Loading…
x
Reference in New Issue
Block a user