diff --git a/ruoyi-admin/src/main/resources/static/ruoyi/index.js b/ruoyi-admin/src/main/resources/static/ruoyi/index.js index fb5501c4..2d2b1e8d 100644 --- a/ruoyi-admin/src/main/resources/static/ruoyi/index.js +++ b/ruoyi-admin/src/main/resources/static/ruoyi/index.js @@ -370,7 +370,8 @@ $(function() { // 刷新按钮 $('.tabReload').on('click', refreshTab); - $('.menuTabs').on('dblclick', '.menuTab', refreshTab); + // 双击选项卡全屏显示 + $('.menuTabs').on('dblclick', '.menuTab', activeTabMax); // 左移按扭 $('.tabLeft').on('click', scrollTabLeft); @@ -396,4 +397,21 @@ $(function() { $('.page-tabs-content').css("margin-left", "0"); }); + // tab全屏显示 + $('.tabMaxCurrent').on('click', function () { + $('.page-tabs-content').find('.active').trigger("dblclick"); + }); + + // 双击选项卡全屏显示 + function activeTabMax() { + $('#content-main').toggleClass('max'); + $('#ax_close_max').show(); + } + + $(window).keydown(function(event) { + if (event.keyCode == 27) { + $('#content-main').removeClass('max'); + $('#ax_close_max').hide(); + } + }); }); \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/index.html b/ruoyi-admin/src/main/resources/templates/index.html index 3a1baf66..b8a369b6 100644 --- a/ruoyi-admin/src/main/resources/templates/index.html +++ b/ruoyi-admin/src/main/resources/templates/index.html @@ -18,6 +18,7 @@ <link th:href="@{/ruoyi/css/ry-ui.css?v=3.0.0}" rel="stylesheet"/> <style type="text/css"> .nav > li:hover .dropdown-menu {display: block;} + #content-main.max { height: calc(100% - 110px); overflow: hidden; width: 100%; height: 100%; left: 0px; position: absolute; top: 0px; z-index: 9998; margin: 0; } </style> </head> <body class="fixed-sidebar full-height-layout gray-bg" style="overflow: hidden" th:classappend="${@config.getKey('sys.index.skinName')}"> @@ -115,6 +116,7 @@ <li><a class="tabCloseCurrent" href="javascript:void();">关闭当前</a></li> <li><a class="tabCloseOther" href="javascript:void();">关闭其他</a></li> <li><a class="tabCloseAll" href="javascript:void();">全部关闭</a></li> + <li><a class="tabMaxCurrent" href="javascript:void();">全屏显示</a></li> </ul> </div> <a href="#" class="roll-nav roll-right tabReload"><i class="fa fa-refresh"></i> 刷新</a> diff --git a/ruoyi-admin/src/main/resources/templates/system/role/rule.html b/ruoyi-admin/src/main/resources/templates/system/role/rule.html index 745f7f2c..6fd50abc 100644 --- a/ruoyi-admin/src/main/resources/templates/system/role/rule.html +++ b/ruoyi-admin/src/main/resources/templates/system/role/rule.html @@ -29,7 +29,7 @@ <span class="help-block m-b-none"><i class="fa fa-info-circle"></i> 特殊情况下,设置为“自定数据权限”</span> </div> </div> - <div class="form-group" id="roleRule" style="display: none"> + <div class="form-group" id="roleRule" th:style="'display:' + @{(*{dataScope=='1'} ? 'none' : 'block')} + ''"> <label class="col-sm-3 control-label">数据权限</label> <div class="col-sm-8"> <div id="deptTrees" class="ztree"></div> @@ -50,7 +50,6 @@ expandLevel: 2 }; $.tree.init(options); - $("#dataScope").change(); }); function submitHandler() { diff --git a/ruoyi-generator/src/main/resources/vm/java/Controller.java.vm b/ruoyi-generator/src/main/resources/vm/java/Controller.java.vm index f086aef4..d50df9ae 100644 --- a/ruoyi-generator/src/main/resources/vm/java/Controller.java.vm +++ b/ruoyi-generator/src/main/resources/vm/java/Controller.java.vm @@ -14,7 +14,7 @@ import com.ruoyi.common.annotation.Log; import com.ruoyi.common.enums.BusinessType; import ${package}.domain.${className}; import ${package}.service.I${className}Service; -import com.ruoyi.web.core.base.BaseController; +import com.ruoyi.framework.web.base.BaseController; import com.ruoyi.framework.web.page.TableDataInfo; import com.ruoyi.common.base.AjaxResult;