Browse Source

移动端进入首页设置默认样式

pull/319/MERGE
RuoYi 3 years ago
parent
commit
fba8008c81
  1. 1
      ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysIndexController.java
  2. 2
      ruoyi-admin/src/main/resources/templates/index-topnav.html
  3. 2
      ruoyi-admin/src/main/resources/templates/index.html

1
ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysIndexController.java

@ -60,6 +60,7 @@ public class SysIndexController extends BaseController
mmap.put("demoEnabled", RuoYiConfig.isDemoEnabled());
mmap.put("isDefaultModifyPwd", initPasswordIsModify(user.getPwdUpdateDate()));
mmap.put("isPasswordExpired", passwordIsExpiration(user.getPwdUpdateDate()));
mmap.put("isMobile", ServletUtils.checkAgentIsMobile(ServletUtils.getRequest().getHeader("User-Agent")));
// 菜单导航显示风格
String menuStyle = configService.selectConfigByKey("sys.index.menuStyle");

2
ruoyi-admin/src/main/resources/templates/index-topnav.html

@ -16,7 +16,7 @@
<link th:href="@{/css/skins.css?v=20200902}" rel="stylesheet"/>
<link th:href="@{/ruoyi/css/ry-ui.css?v=4.6.2}" rel="stylesheet"/>
</head>
<body class="fixed-sidebar full-height-layout gray-bg" style="overflow: hidden">
<body class="fixed-sidebar full-height-layout gray-bg" th:classappend="${isMobile} ? 'canvas-menu'" style="overflow: hidden">
<div id="wrapper">
<!--左侧导航开始-->

2
ruoyi-admin/src/main/resources/templates/index.html

@ -16,7 +16,7 @@
<link th:href="@{/css/skins.css}" rel="stylesheet"/>
<link th:href="@{/ruoyi/css/ry-ui.css?v=4.6.2}" rel="stylesheet"/>
</head>
<body class="fixed-sidebar full-height-layout gray-bg" style="overflow: hidden">
<body class="fixed-sidebar full-height-layout gray-bg" th:classappend="${isMobile} ? 'canvas-menu'" style="overflow: hidden">
<div id="wrapper">
<!--左侧导航开始-->

Loading…
Cancel
Save