diff --git a/ruoyi-ui/src/assets/styles/ruoyi.scss b/ruoyi-ui/src/assets/styles/ruoyi.scss index ec6a409..2e7eee7 100644 --- a/ruoyi-ui/src/assets/styles/ruoyi.scss +++ b/ruoyi-ui/src/assets/styles/ruoyi.scss @@ -117,6 +117,25 @@ font-size: 13px; } } + .el-table__fixed { + height: auto !important; + bottom: 8px !important; + } + .el-table__fixed::before, .el-table__fixed::before { + display: none; + } + + //修改滚动条的宽度和高度(横向是高度,纵向是宽度) + ::-webkit-scrollbar { + width: 8px; + height: 8px; + background-color: transparent; + } + //加宽滚动条的错层问题 + .el-scrollbar__wrap::-webkit-scrollbar { + width: 8px; + height: 8px; + } .el-table__body-wrapper { .el-button [class*="el-icon-"] + span { diff --git a/ruoyi-ui/src/main.js b/ruoyi-ui/src/main.js index 0fdb8ab..89c7946 100644 --- a/ruoyi-ui/src/main.js +++ b/ruoyi-ui/src/main.js @@ -123,3 +123,23 @@ Element.TableColumn.props.align = { //模态框点击空白不消失 Element.Dialog.props.closeOnClickModal.default = false + + +//聚焦事件 +Vue.directive("focus", { + bind:function (el) { // 1.每当指令绑定到元素上的时候,会立即执行这个bind函数,【执行一次】 + el.focus() + }, + inserted:function (el) { // 2.当元素插入到DOM中的时候,会执行 inserted 函数, 【触发一次】 + if(el.tagName.toLocaleLowerCase() == 'input'){ + el.focus() + }else{ + if(el.getElementsByTagName('input')){ + el.getElementsByTagName('input')[0].focus() + } + } + }, + updated:function ( ) { // 3.当VNode更新的时候,会执行 updated,【可能触发多次】 + el.focus() + } +})