浏览代码

修正部门菜单排序字段无效

RuoYi 6 年之前
父节点
当前提交
9d225fecb9

+ 1 - 1
ruoyi-common/src/main/java/com/ruoyi/common/config/Global.java

@@ -86,7 +86,7 @@ public class Global
      */
     public static String getVersion()
     {
-        return StringUtils.nvl(getConfig("ruoyi.version"), "3.0.0");
+        return StringUtils.nvl(getConfig("ruoyi.version"), "3.1.0");
     }
 
     /**

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

@@ -49,6 +49,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 		</if>
 		<!-- 数据范围过滤 -->
 		${params.dataScope}
+		order by d.order_num
     </select>
 	
 	<select id="checkDeptExistUser" parameterType="Long" resultType="int">

+ 2 - 0
ruoyi-system/src/main/resources/mapper/system/SysMenuMapper.xml

@@ -46,6 +46,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 	
 	<select id="selectMenuAll" resultMap="SysMenuResult">
 		<include refid="selectMenuVo"/>
+		order by order_num
 	</select>
 	
 	<select id="selectPermsByUserId" parameterType="Long" resultType="String">
@@ -74,6 +75,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 				AND visible = #{visible}
 			</if>
 		</where>
+		order by order_num
     </select>
 	
 	<delete id="deleteMenuById" parameterType="Long">

+ 1 - 1
sql/ry_20181203.sql

@@ -166,7 +166,7 @@ insert into sys_menu values('108',  '日志管理', '1', '9', '#',
 insert into sys_menu values('109',  '在线用户', '2', '1', '/monitor/online',     'C', '0', 'monitor:online:view',      '#', 'admin', '2018-03-16 11-33-00', 'ry', '2018-03-16 11-33-00', '在线用户菜单');
 insert into sys_menu values('110',  '定时任务', '2', '2', '/monitor/job',        'C', '0', 'monitor:job:view',         '#', 'admin', '2018-03-16 11-33-00', 'ry', '2018-03-16 11-33-00', '定时任务菜单');
 insert into sys_menu values('111',  '数据监控', '2', '3', '/monitor/data',       'C', '0', 'monitor:data:view',        '#', 'admin', '2018-03-16 11-33-00', 'ry', '2018-03-16 11-33-00', '数据监控菜单');
-insert into sys_menu values('112',  '服务监控', '2', '3', '/monitor/server',     'C', '0', 'monitor:server:view',      '#', 'admin', '2018-03-16 11-33-00', 'ry', '2018-03-16 11-33-00', '数据监控菜单');
+insert into sys_menu values('112',  '服务监控', '2', '3', '/monitor/server',     'C', '0', 'monitor:server:view',      '#', 'admin', '2018-03-16 11-33-00', 'ry', '2018-03-16 11-33-00', '服务监控菜单');
 insert into sys_menu values('113',  '表单构建', '3', '1', '/tool/build',         'C', '0', 'tool:build:view',          '#', 'admin', '2018-03-16 11-33-00', 'ry', '2018-03-16 11-33-00', '表单构建菜单');
 insert into sys_menu values('114',  '代码生成', '3', '2', '/tool/gen',           'C', '0', 'tool:gen:view',            '#', 'admin', '2018-03-16 11-33-00', 'ry', '2018-03-16 11-33-00', '代码生成菜单');
 insert into sys_menu values('115',  '系统接口', '3', '3', '/tool/swagger',       'C', '0', 'tool:swagger:view',        '#', 'admin', '2018-03-16 11-33-00', 'ry', '2018-03-16 11-33-00', '系统接口菜单');