diff --git a/pom.xml b/pom.xml
index 2edd52312..dfb34647f 100644
--- a/pom.xml
+++ b/pom.xml
@@ -24,7 +24,7 @@
1.5.22
4.1.2
2.2.11
- 1.7
+ 2.3
0.9.1
3.4.3.4
3.9.1
@@ -118,7 +118,7 @@
org.apache.velocity
- velocity
+ velocity-engine-core
${velocity.version}
diff --git a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysProfileController.java b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysProfileController.java
index 440eebb7e..4261f17e4 100644
--- a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysProfileController.java
+++ b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysProfileController.java
@@ -73,6 +73,7 @@ public class SysProfileController extends BaseController {
LoginUser loginUser = getLoginUser();
SysUser sysUser = userService.selectUserById(loginUser.getUserId());
user.setUserId(sysUser.getUserId());
+ user.setUserName(null);
user.setPassword(null);
if (userService.updateUserProfile(user) > 0) {
return AjaxResult.success();
diff --git a/ruoyi-generator/pom.xml b/ruoyi-generator/pom.xml
index 668489f6e..045ecbaf8 100644
--- a/ruoyi-generator/pom.xml
+++ b/ruoyi-generator/pom.xml
@@ -20,7 +20,7 @@
org.apache.velocity
- velocity
+ velocity-engine-core
diff --git a/ruoyi-generator/src/main/java/com/ruoyi/generator/util/VelocityInitializer.java b/ruoyi-generator/src/main/java/com/ruoyi/generator/util/VelocityInitializer.java
index 461bc2cce..a81bd51df 100644
--- a/ruoyi-generator/src/main/java/com/ruoyi/generator/util/VelocityInitializer.java
+++ b/ruoyi-generator/src/main/java/com/ruoyi/generator/util/VelocityInitializer.java
@@ -19,10 +19,9 @@ public class VelocityInitializer {
Properties p = new Properties();
try {
// 加载classpath目录下的vm文件
- p.setProperty("file.resource.loader.class", "org.apache.velocity.runtime.resource.loader.ClasspathResourceLoader");
+ p.setProperty("resource.loader.file.class", "org.apache.velocity.runtime.resource.loader.ClasspathResourceLoader");
// 定义字符集
p.setProperty(Velocity.INPUT_ENCODING, Constants.UTF8);
- p.setProperty(Velocity.OUTPUT_ENCODING, Constants.UTF8);
// 初始化Velocity引擎,指定配置Properties
Velocity.init(p);
} catch (Exception e) {
diff --git a/ruoyi-generator/src/main/java/com/ruoyi/generator/util/VelocityUtils.java b/ruoyi-generator/src/main/java/com/ruoyi/generator/util/VelocityUtils.java
index 0a3ffbc51..d2e0e3a65 100644
--- a/ruoyi-generator/src/main/java/com/ruoyi/generator/util/VelocityUtils.java
+++ b/ruoyi-generator/src/main/java/com/ruoyi/generator/util/VelocityUtils.java
@@ -247,7 +247,8 @@ public class VelocityUtils {
List dicts = new ArrayList();
for (GenTableColumn column : columns) {
if (!column.isSuperColumn() && StringUtils.isNotEmpty(column.getDictType()) && StringUtils.equalsAny(
- column.getHtmlType(), new String[]{GenConstants.HTML_SELECT, GenConstants.HTML_RADIO})) {
+ column.getHtmlType(),
+ new String[] { GenConstants.HTML_SELECT, GenConstants.HTML_RADIO, GenConstants.HTML_CHECKBOX })) {
dicts.add("'" + column.getDictType() + "'");
}
}
diff --git a/ruoyi-generator/src/main/resources/vm/vue/index-tree.vue.vm b/ruoyi-generator/src/main/resources/vm/vue/index-tree.vue.vm
index 24494adf3..7c530cb13 100644
--- a/ruoyi-generator/src/main/resources/vm/vue/index-tree.vue.vm
+++ b/ruoyi-generator/src/main/resources/vm/vue/index-tree.vue.vm
@@ -108,7 +108,11 @@
#elseif($column.list && $column.dictType && "" != $column.dictType)
+#if($column.htmlType == "checkbox")
+
+#else
+#end
#elseif($column.list && "" != $javaField)
@@ -296,8 +300,7 @@ export default {
queryParams: {
#foreach ($column in $columns)
#if($column.query)
- $column.javaField: null#if($velocityCount != $columns.size()),#end
-
+ $column.javaField: null#if($foreach.count != $columns.size()),#end
#end
#end
},
@@ -315,8 +318,7 @@ export default {
#end
$column.javaField: [
{ required: true, message: "$comment不能为空", trigger: #if($column.htmlType == "select")"change"#else"blur"#end }
- ]#if($velocityCount != $columns.size()),#end
-
+ ]#if($foreach.count != $columns.size()),#end
#end
#end
}
@@ -379,14 +381,12 @@ export default {
this.form = {
#foreach ($column in $columns)
#if($column.htmlType == "radio")
- $column.javaField: #if($column.javaType == "Integer" || $column.javaType == "Long")0#else"0"#end#if($velocityCount != $columns.size()),#end
+ $column.javaField: #if($column.javaType == "Integer" || $column.javaType == "Long")0#else"0"#end#if($foreach.count != $columns.size()),#end
#elseif($column.htmlType == "checkbox")
- $column.javaField: []#if($velocityCount != $columns.size()),#end
-
+ $column.javaField: []#if($foreach.count != $columns.size()),#end
#else
- $column.javaField: null#if($velocityCount != $columns.size()),#end
-
+ $column.javaField: null#if($foreach.count != $columns.size()),#end
#end
#end
};
diff --git a/ruoyi-generator/src/main/resources/vm/vue/index.vue.vm b/ruoyi-generator/src/main/resources/vm/vue/index.vue.vm
index 765017054..c0a5bf716 100644
--- a/ruoyi-generator/src/main/resources/vm/vue/index.vue.vm
+++ b/ruoyi-generator/src/main/resources/vm/vue/index.vue.vm
@@ -136,7 +136,11 @@
#elseif($column.list && $column.dictType && "" != $column.dictType)
+#if($column.htmlType == "checkbox")
+
+#else
+#end
#elseif($column.list && "" != $javaField)
@@ -360,8 +364,7 @@ export default {
pageSize: 10,
#foreach ($column in $columns)
#if($column.query)
- $column.javaField: undefined#if($velocityCount != $columns.size()),#end
-
+ $column.javaField: undefined#if($foreach.count != $columns.size()),#end
#end
#end
},
@@ -379,8 +382,7 @@ export default {
#end
$column.javaField: [
{ required: true, message: "$comment不能为空", trigger: #if($column.htmlType == "select")"change"#else"blur"#end }
- ]#if($velocityCount != $columns.size()),#end
-
+ ]#if($foreach.count != $columns.size()),#end
#end
#end
}
@@ -424,14 +426,11 @@ export default {
this.form = {
#foreach ($column in $columns)
#if($column.htmlType == "radio")
- $column.javaField: #if($column.javaType == "Integer" || $column.javaType == "Long")0#else"0"#end#if($velocityCount != $columns.size()),#end
-
+ $column.javaField: #if($column.javaType == "Integer" || $column.javaType == "Long")0#else"0"#end#if($foreach.count != $columns.size()),#end
#elseif($column.htmlType == "checkbox")
- $column.javaField: []#if($velocityCount != $columns.size()),#end
-
+ $column.javaField: []#if($foreach.count != $columns.size()),#end
#else
- $column.javaField: undefined#if($velocityCount != $columns.size()),#end
-
+ $column.javaField: undefined#if($foreach.count != $columns.size()),#end
#end
#end
};
diff --git a/ruoyi-ui/package.json b/ruoyi-ui/package.json
index cb2109c51..bad8e7723 100644
--- a/ruoyi-ui/package.json
+++ b/ruoyi-ui/package.json
@@ -46,7 +46,7 @@
"fuse.js": "6.4.3",
"highlight.js": "9.18.5",
"js-beautify": "1.13.0",
- "js-cookie": "2.2.1",
+ "js-cookie": "3.0.1",
"jsencrypt": "3.2.1",
"nprogress": "0.2.0",
"quill": "1.3.7",
@@ -55,7 +55,7 @@
"vue": "2.6.12",
"vue-count-to": "1.0.13",
"vue-cropper": "0.5.5",
- "vue-meta": "^2.4.0",
+ "vue-meta": "2.4.0",
"vue-router": "3.4.9",
"vuedraggable": "2.24.3",
"vuex": "3.6.0"
diff --git a/ruoyi-ui/src/api/monitor/server.js b/ruoyi-ui/src/api/monitor/server.js
index feed7836c..12489d873 100644
--- a/ruoyi-ui/src/api/monitor/server.js
+++ b/ruoyi-ui/src/api/monitor/server.js
@@ -1,9 +1,9 @@
import request from '@/utils/request'
-// 查询服务器详细
+// 获取服务信息
export function getServer() {
return request({
url: '/monitor/server',
method: 'get'
})
-}
\ No newline at end of file
+}
diff --git a/ruoyi-ui/src/components/Breadcrumb/index.vue b/ruoyi-ui/src/components/Breadcrumb/index.vue
index 1fbae5f3c..1696f5471 100644
--- a/ruoyi-ui/src/components/Breadcrumb/index.vue
+++ b/ruoyi-ui/src/components/Breadcrumb/index.vue
@@ -2,7 +2,7 @@
- {{ item.meta.title }}
+ {{ item.meta.title }}
{{ item.meta.title }}
diff --git a/ruoyi-ui/src/components/RightToolbar/index.vue b/ruoyi-ui/src/components/RightToolbar/index.vue
index c7ab139d7..976974e4a 100644
--- a/ruoyi-ui/src/components/RightToolbar/index.vue
+++ b/ruoyi-ui/src/components/RightToolbar/index.vue
@@ -62,7 +62,7 @@ export default {
},
// 右侧列表元素变化
dataChange(data) {
- for (var item in this.columns) {
+ for (let item in this.columns) {
const key = this.columns[item].key;
this.columns[item].visible = !data.includes(key);
}
diff --git a/ruoyi-ui/src/components/RuoYi/Doc/index.vue b/ruoyi-ui/src/components/RuoYi/Doc/index.vue
index e267f9021..a60fd213a 100644
--- a/ruoyi-ui/src/components/RuoYi/Doc/index.vue
+++ b/ruoyi-ui/src/components/RuoYi/Doc/index.vue
@@ -1,6 +1,6 @@
-
+
diff --git a/ruoyi-ui/src/components/RuoYi/Git/index.vue b/ruoyi-ui/src/components/RuoYi/Git/index.vue
index 4d580e418..faecbc178 100644
--- a/ruoyi-ui/src/components/RuoYi/Git/index.vue
+++ b/ruoyi-ui/src/components/RuoYi/Git/index.vue
@@ -1,6 +1,6 @@
-
+
diff --git a/ruoyi-ui/src/components/SizeSelect/index.vue b/ruoyi-ui/src/components/SizeSelect/index.vue
index e88065b49..069b5de9b 100644
--- a/ruoyi-ui/src/components/SizeSelect/index.vue
+++ b/ruoyi-ui/src/components/SizeSelect/index.vue
@@ -5,8 +5,7 @@
- {{
- item.label }}
+ {{ item.label }}
diff --git a/ruoyi-ui/src/layout/components/Sidebar/Logo.vue b/ruoyi-ui/src/layout/components/Sidebar/Logo.vue
index 416968737..b8d9d6b7c 100644
--- a/ruoyi-ui/src/layout/components/Sidebar/Logo.vue
+++ b/ruoyi-ui/src/layout/components/Sidebar/Logo.vue
@@ -29,7 +29,7 @@ export default {
variables() {
return variables;
},
- sideTheme() {
+ sideTheme() {
return this.$store.state.settings.sideTheme
}
},
diff --git a/ruoyi-ui/src/layout/components/TagsView/index.vue b/ruoyi-ui/src/layout/components/TagsView/index.vue
index 99bb28969..20c4b55e6 100644
--- a/ruoyi-ui/src/layout/components/TagsView/index.vue
+++ b/ruoyi-ui/src/layout/components/TagsView/index.vue
@@ -152,31 +152,24 @@ export default {
})
},
refreshSelectedTag(view) {
- this.$store.dispatch('tagsView/delCachedView', view).then(() => {
- const { fullPath } = view
- this.$nextTick(() => {
- this.$router.replace({
- path: '/redirect' + fullPath
- })
- })
- })
+ this.$tab.refreshPage(view);
},
closeSelectedTag(view) {
- this.$store.dispatch('tagsView/delView', view).then(({ visitedViews }) => {
+ this.$tab.closePage(view).then(({ visitedViews }) => {
if (this.isActive(view)) {
this.toLastView(visitedViews, view)
}
})
},
closeRightTags() {
- this.$store.dispatch('tagsView/delRightTags', this.selectedTag).then(visitedViews => {
+ this.$tab.closeRightPage(this.selectedTag).then(visitedViews => {
if (!visitedViews.find(i => i.fullPath === this.$route.fullPath)) {
this.toLastView(visitedViews)
}
})
},
closeLeftTags() {
- this.$store.dispatch('tagsView/delLeftTags', this.selectedTag).then(visitedViews => {
+ this.$tab.closeLeftPage(this.selectedTag).then(visitedViews => {
if (!visitedViews.find(i => i.fullPath === this.$route.fullPath)) {
this.toLastView(visitedViews)
}
@@ -184,12 +177,12 @@ export default {
},
closeOthersTags() {
this.$router.push(this.selectedTag).catch(()=>{});
- this.$store.dispatch('tagsView/delOthersViews', this.selectedTag).then(() => {
+ this.$tab.closeOtherPage(this.selectedTag).then(() => {
this.moveToCurrentTag()
})
},
closeAllTags(view) {
- this.$store.dispatch('tagsView/delAllViews').then(({ visitedViews }) => {
+ this.$tab.closeAllPage().then(({ visitedViews }) => {
if (this.affixTags.some(tag => tag.path === this.$route.path)) {
return
}
diff --git a/ruoyi-ui/src/layout/index.vue b/ruoyi-ui/src/layout/index.vue
index 214d86ffe..8be418409 100644
--- a/ruoyi-ui/src/layout/index.vue
+++ b/ruoyi-ui/src/layout/index.vue
@@ -98,7 +98,7 @@ export default {
}
.hideSidebar .fixed-header {
- width: calc(100% - 54px)
+ width: calc(100% - 54px);
}
.mobile .fixed-header {
diff --git a/ruoyi-ui/src/main.js b/ruoyi-ui/src/main.js
index 76e33d59e..29c402265 100644
--- a/ruoyi-ui/src/main.js
+++ b/ruoyi-ui/src/main.js
@@ -10,7 +10,7 @@ import '@/assets/styles/ruoyi.scss' // ruoyi css
import App from './App'
import store from './store'
import router from './router'
-import directive from './directive' //directive
+import directive from './directive' // directive
import plugins from './plugins' // plugins
import { download } from '@/utils/request'
diff --git a/ruoyi-ui/src/plugins/index.js b/ruoyi-ui/src/plugins/index.js
index 7cc83a4c8..9bc6eacd3 100644
--- a/ruoyi-ui/src/plugins/index.js
+++ b/ruoyi-ui/src/plugins/index.js
@@ -1,3 +1,4 @@
+import tab from './tab'
import auth from './auth'
import cache from './cache'
import modal from './modal'
@@ -5,6 +6,8 @@ import download from './download'
export default {
install(Vue) {
+ // 页签操作
+ Vue.prototype.$tab = tab
// 认证对象
Vue.prototype.$auth = auth
// 缓存对象
diff --git a/ruoyi-ui/src/plugins/tab.js b/ruoyi-ui/src/plugins/tab.js
new file mode 100644
index 000000000..95a3848b6
--- /dev/null
+++ b/ruoyi-ui/src/plugins/tab.js
@@ -0,0 +1,66 @@
+import store from '@/store'
+import router from '@/router';
+
+export default {
+ // 刷新当前tab页签
+ refreshPage(obj) {
+ const { path, matched } = router.currentRoute;
+ if (obj === undefined) {
+ matched.forEach((m) => {
+ if (m.components && m.components.default && m.components.default.name) {
+ if (!['Layout', 'ParentView'].includes(m.components.default.name)) {
+ obj = { name: m.components.default.name, path: path };
+ }
+ }
+ });
+ }
+ return store.dispatch('tagsView/delCachedView', obj).then(() => {
+ const { path } = obj
+ router.replace({
+ path: '/redirect' + path
+ })
+ })
+ },
+ // 关闭当前tab页签,打开新页签
+ closeOpenPage(obj) {
+ store.dispatch("tagsView/delView", router.currentRoute);
+ if (obj !== undefined) {
+ return router.push(obj);
+ }
+ },
+ // 关闭指定tab页签
+ closePage(obj) {
+ if (obj === undefined) {
+ return store.dispatch('tagsView/delView', router.currentRoute).then(({ lastPath }) => {
+ return router.push(lastPath || '/');
+ });
+ }
+ return store.dispatch('tagsView/delView', obj);
+ },
+ // 关闭所有tab页签
+ closeAllPage() {
+ return store.dispatch('tagsView/delAllViews');
+ },
+ // 关闭左侧tab页签
+ closeLeftPage(obj) {
+ return store.dispatch('tagsView/delLeftTags', obj || router.currentRoute);
+ },
+ // 关闭右侧tab页签
+ closeRightPage(obj) {
+ return store.dispatch('tagsView/delRightTags', obj || router.currentRoute);
+ },
+ // 关闭其他tab页签
+ closeOtherPage(obj) {
+ return store.dispatch('tagsView/delOthersViews', obj || router.currentRoute);
+ },
+ // 添加tab页签
+ openPage(title, url) {
+ var obj = { path: url, meta: { title: title } }
+ store.dispatch('tagsView/addView', obj);
+ return router.push(url);
+ },
+ // 修改tab页签
+ updatePage(obj) {
+ return store.dispatch('tagsView/updateVisitedView', obj);
+ }
+}
diff --git a/ruoyi-ui/src/router/index.js b/ruoyi-ui/src/router/index.js
index b6b14fabc..cda6d4c3a 100644
--- a/ruoyi-ui/src/router/index.js
+++ b/ruoyi-ui/src/router/index.js
@@ -95,7 +95,7 @@ export const constantRoutes = [
path: 'role/:userId(\\d+)',
component: (resolve) => require(['@/views/system/user/authRole'], resolve),
name: 'AuthRole',
- meta: { title: '分配角色', activeMenu: '/system/user'}
+ meta: { title: '分配角色', activeMenu: '/system/user' }
}
]
},
@@ -108,7 +108,7 @@ export const constantRoutes = [
path: 'user/:roleId(\\d+)',
component: (resolve) => require(['@/views/system/role/authUser'], resolve),
name: 'AuthUser',
- meta: { title: '分配用户', activeMenu: '/system/role'}
+ meta: { title: '分配用户', activeMenu: '/system/role' }
}
]
},
@@ -121,7 +121,7 @@ export const constantRoutes = [
path: 'index/:dictId(\\d+)',
component: (resolve) => require(['@/views/system/dict/data'], resolve),
name: 'Data',
- meta: { title: '字典数据', activeMenu: '/system/dict'}
+ meta: { title: '字典数据', activeMenu: '/system/dict' }
}
]
},
@@ -147,7 +147,7 @@ export const constantRoutes = [
path: 'index',
component: (resolve) => require(['@/views/tool/gen/editTable'], resolve),
name: 'GenEdit',
- meta: { title: '修改生成配置', activeMenu: '/tool/gen'}
+ meta: { title: '修改生成配置', activeMenu: '/tool/gen' }
}
]
}
diff --git a/ruoyi-ui/src/store/modules/permission.js b/ruoyi-ui/src/store/modules/permission.js
index dba9252f4..8d84fff81 100644
--- a/ruoyi-ui/src/store/modules/permission.js
+++ b/ruoyi-ui/src/store/modules/permission.js
@@ -1,7 +1,7 @@
import { constantRoutes } from '@/router'
import { getRouters } from '@/api/menu'
import Layout from '@/layout/index'
-import ParentView from '@/components/ParentView';
+import ParentView from '@/components/ParentView'
import InnerLink from '@/layout/components/InnerLink'
const permission = {
@@ -24,7 +24,7 @@ const permission = {
// 顶部导航菜单默认添加统计报表栏指向首页
const index = [{
path: 'index',
- meta: { title: '统计报表', icon: 'dashboard'}
+ meta: { title: '统计报表', icon: 'dashboard' }
}]
state.topbarRouters = routes.concat(index);
},
diff --git a/ruoyi-ui/src/store/modules/settings.js b/ruoyi-ui/src/store/modules/settings.js
index 5f36d8eee..2455a1e27 100644
--- a/ruoyi-ui/src/store/modules/settings.js
+++ b/ruoyi-ui/src/store/modules/settings.js
@@ -8,7 +8,7 @@ const state = {
theme: storageSetting.theme || '#409EFF',
sideTheme: storageSetting.sideTheme || sideTheme,
showSettings: showSettings,
- topNav: storageSetting.topNav === undefined ? topNav : storageSetting.topNav,
+ topNav: storageSetting.topNav === undefined ? topNav : storageSetting.topNav,
tagsView: storageSetting.tagsView === undefined ? tagsView : storageSetting.tagsView,
fixedHeader: storageSetting.fixedHeader === undefined ? fixedHeader : storageSetting.fixedHeader,
sidebarLogo: storageSetting.sidebarLogo === undefined ? sidebarLogo : storageSetting.sidebarLogo,
diff --git a/ruoyi-ui/src/store/modules/tagsView.js b/ruoyi-ui/src/store/modules/tagsView.js
index ef2fe4caf..002c1d099 100644
--- a/ruoyi-ui/src/store/modules/tagsView.js
+++ b/ruoyi-ui/src/store/modules/tagsView.js
@@ -14,7 +14,7 @@ const mutations = {
},
ADD_CACHED_VIEW: (state, view) => {
if (state.cachedViews.includes(view.name)) return
- if (!view.meta.noCache) {
+ if (view.meta && !view.meta.noCache) {
state.cachedViews.push(view.name)
}
},
@@ -63,7 +63,7 @@ const mutations = {
}
}
},
-
+
DEL_RIGHT_VIEWS: (state, view) => {
const index = state.visitedViews.findIndex(v => v.path === view.path)
if (index === -1) {
diff --git a/ruoyi-ui/src/utils/dict/index.js b/ruoyi-ui/src/utils/dict/index.js
index 66ddfef9e..d6fdb802c 100644
--- a/ruoyi-ui/src/utils/dict/index.js
+++ b/ruoyi-ui/src/utils/dict/index.js
@@ -5,7 +5,7 @@ export default function(Vue, options) {
mergeOptions(options)
Vue.mixin({
data() {
- if (this.$options.dicts === undefined || this.$options.dicts === null) {
+ if (this.$options === undefined || this.$options.dicts === undefined || this.$options.dicts === null) {
return {}
}
const dict = new Dict()
diff --git a/ruoyi-ui/src/views/login.vue b/ruoyi-ui/src/views/login.vue
index 6c35bd8d4..4df893666 100644
--- a/ruoyi-ui/src/views/login.vue
+++ b/ruoyi-ui/src/views/login.vue
@@ -3,7 +3,12 @@
RuoYi-Vue-Plus后台管理系统
-
+
@@ -66,7 +71,6 @@ export default {
data() {
return {
codeUrl: "",
- cookiePassword: "",
loginForm: {
username: "admin",
password: "admin123",
diff --git a/ruoyi-ui/src/views/monitor/logininfor/index.vue b/ruoyi-ui/src/views/monitor/logininfor/index.vue
index 0f4ecbba6..98bd74357 100644
--- a/ruoyi-ui/src/views/monitor/logininfor/index.vue
+++ b/ruoyi-ui/src/views/monitor/logininfor/index.vue
@@ -6,8 +6,8 @@
v-model="queryParams.ipaddr"
placeholder="请输入登录地址"
clearable
+ size="small"
style="width: 240px;"
- size="small"
@keyup.enter.native="handleQuery"
/>
@@ -16,8 +16,8 @@
v-model="queryParams.userName"
placeholder="请输入用户名称"
clearable
+ size="small"
style="width: 240px;"
- size="small"
@keyup.enter.native="handleQuery"
/>
diff --git a/ruoyi-ui/src/views/monitor/operlog/index.vue b/ruoyi-ui/src/views/monitor/operlog/index.vue
index 28f705b82..9b8b7856b 100644
--- a/ruoyi-ui/src/views/monitor/operlog/index.vue
+++ b/ruoyi-ui/src/views/monitor/operlog/index.vue
@@ -6,8 +6,8 @@
v-model="queryParams.title"
placeholder="请输入系统模块"
clearable
- style="width: 240px;"
size="small"
+ style="width: 240px;"
@keyup.enter.native="handleQuery"
/>
@@ -16,8 +16,8 @@
v-model="queryParams.operName"
placeholder="请输入操作人员"
clearable
- style="width: 240px;"
size="small"
+ style="width: 240px;"
@keyup.enter.native="handleQuery"
/>
diff --git a/ruoyi-ui/src/views/system/dept/index.vue b/ruoyi-ui/src/views/system/dept/index.vue
index f9c7741e5..e215b1c8e 100644
--- a/ruoyi-ui/src/views/system/dept/index.vue
+++ b/ruoyi-ui/src/views/system/dept/index.vue
@@ -179,8 +179,6 @@ export default {
isExpandAll: true,
// 重新渲染表格状态
refreshTable: true,
- // 是否展开
- expand: false,
// 查询参数
queryParams: {
deptName: undefined,
@@ -276,7 +274,7 @@ export default {
this.open = true;
this.title = "添加部门";
listDept().then(response => {
- this.deptOptions = this.handleTree(response.data, "deptId");
+ this.deptOptions = this.handleTree(response.data, "deptId");
});
},
/** 展开/折叠操作 */
@@ -296,7 +294,7 @@ export default {
this.title = "修改部门";
});
listDeptExcludeChild(row.deptId).then(response => {
- this.deptOptions = this.handleTree(response.data, "deptId");
+ this.deptOptions = this.handleTree(response.data, "deptId");
});
},
/** 提交按钮 */
diff --git a/ruoyi-ui/src/views/system/dict/data.vue b/ruoyi-ui/src/views/system/dict/data.vue
index bb779198b..bf538ad90 100644
--- a/ruoyi-ui/src/views/system/dict/data.vue
+++ b/ruoyi-ui/src/views/system/dict/data.vue
@@ -79,6 +79,15 @@
v-hasPermi="['system:dict:export']"
>导出
+
+ 关闭
+
@@ -316,6 +325,11 @@ export default {
this.queryParams.pageNum = 1;
this.getList();
},
+ /** 返回按钮操作 */
+ handleClose() {
+ const obj = { path: "/system/dict" };
+ this.$tab.closeOpenPage(obj);
+ },
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
diff --git a/ruoyi-ui/src/views/system/menu/index.vue b/ruoyi-ui/src/views/system/menu/index.vue
index a89e1ee71..d65773ad2 100644
--- a/ruoyi-ui/src/views/system/menu/index.vue
+++ b/ruoyi-ui/src/views/system/menu/index.vue
@@ -78,7 +78,8 @@
-
-
-
+
+
-
-
+
+
@@ -172,8 +173,8 @@
-
-
+
+
@@ -194,8 +195,8 @@
-
-
+
+
@@ -205,8 +206,8 @@
-
-
+
+
@@ -216,8 +217,8 @@
-
-
+
+
@@ -230,8 +231,8 @@
-
-
+
+
@@ -247,8 +248,8 @@
-
-
+
+
diff --git a/ruoyi-ui/src/views/system/role/authUser.vue b/ruoyi-ui/src/views/system/role/authUser.vue
index e18ea8b31..dd1881252 100644
--- a/ruoyi-ui/src/views/system/role/authUser.vue
+++ b/ruoyi-ui/src/views/system/role/authUser.vue
@@ -153,8 +153,8 @@ export default {
},
// 返回按钮
handleClose() {
- this.$store.dispatch("tagsView/delView", this.$route);
- this.$router.push({ path: "/system/role" });
+ const obj = { path: "/system/role" };
+ this.$tab.closeOpenPage(obj);
},
/** 搜索按钮操作 */
handleQuery() {
diff --git a/ruoyi-ui/src/views/system/role/index.vue b/ruoyi-ui/src/views/system/role/index.vue
index a2a412072..779f556d2 100644
--- a/ruoyi-ui/src/views/system/role/index.vue
+++ b/ruoyi-ui/src/views/system/role/index.vue
@@ -355,8 +355,7 @@ export default {
/** 查询角色列表 */
getList() {
this.loading = true;
- listRole(this.addDateRange(this.queryParams, this.dateRange)).then(
- response => {
+ listRole(this.addDateRange(this.queryParams, this.dateRange)).then(response => {
this.roleList = response.rows;
this.total = response.total;
this.loading = false;
diff --git a/ruoyi-ui/src/views/system/role/selectUser.vue b/ruoyi-ui/src/views/system/role/selectUser.vue
index a9e2ce0ff..02610d8ef 100644
--- a/ruoyi-ui/src/views/system/role/selectUser.vue
+++ b/ruoyi-ui/src/views/system/role/selectUser.vue
@@ -123,6 +123,10 @@ export default {
handleSelectUser() {
const roleId = this.queryParams.roleId;
const userIds = this.userIds.join(",");
+ if (userIds == "") {
+ this.$modal.msgError("请选择要分配的用户");
+ return;
+ }
authUserSelectAll({ roleId: roleId, userIds: userIds }).then(res => {
this.$modal.msgSuccess(res.msg);
if (res.code === 200) {
diff --git a/ruoyi-ui/src/views/system/user/authRole.vue b/ruoyi-ui/src/views/system/user/authRole.vue
index dabdc27ce..52a792357 100644
--- a/ruoyi-ui/src/views/system/user/authRole.vue
+++ b/ruoyi-ui/src/views/system/user/authRole.vue
@@ -33,7 +33,7 @@
-
+
@@ -109,9 +109,9 @@ export default {
},
/** 关闭按钮 */
close() {
- this.$store.dispatch("tagsView/delView", this.$route);
- this.$router.push({ path: "/system/user" });
+ const obj = { path: "/system/user" };
+ this.$tab.closeOpenPage(obj);
},
},
};
-
\ No newline at end of file
+
diff --git a/ruoyi-ui/src/views/system/user/index.vue b/ruoyi-ui/src/views/system/user/index.vue
index 4d86a14ab..1ff9b906b 100644
--- a/ruoyi-ui/src/views/system/user/index.vue
+++ b/ruoyi-ui/src/views/system/user/index.vue
@@ -206,7 +206,7 @@
-
+
@@ -652,7 +652,6 @@ export default {
/** 下载模板操作 */
importTemplate() {
this.download('system/user/importTemplate', {
- ...this.queryParams
}, `user_template_${new Date().getTime()}.xlsx`)
},
// 文件上传中处理
diff --git a/ruoyi-ui/src/views/system/user/profile/resetPwd.vue b/ruoyi-ui/src/views/system/user/profile/resetPwd.vue
index 119f1036f..0a8d216b1 100644
--- a/ruoyi-ui/src/views/system/user/profile/resetPwd.vue
+++ b/ruoyi-ui/src/views/system/user/profile/resetPwd.vue
@@ -29,7 +29,6 @@ export default {
}
};
return {
- test: "1test",
user: {
oldPassword: undefined,
newPassword: undefined,
@@ -55,17 +54,14 @@ export default {
submit() {
this.$refs["form"].validate(valid => {
if (valid) {
- updateUserPwd(this.user.oldPassword, this.user.newPassword).then(
- response => {
- this.$modal.msgSuccess("修改成功");
- }
- );
+ updateUserPwd(this.user.oldPassword, this.user.newPassword).then(response => {
+ this.$modal.msgSuccess("修改成功");
+ });
}
});
},
close() {
- this.$store.dispatch("tagsView/delView", this.$route);
- this.$router.push({ path: "/index" });
+ this.$tab.closePage();
}
}
};
diff --git a/ruoyi-ui/src/views/system/user/profile/userAvatar.vue b/ruoyi-ui/src/views/system/user/profile/userAvatar.vue
index 08652c2f7..d094602a2 100644
--- a/ruoyi-ui/src/views/system/user/profile/userAvatar.vue
+++ b/ruoyi-ui/src/views/system/user/profile/userAvatar.vue
@@ -1,7 +1,7 @@
-
+
\ No newline at end of file
+
diff --git a/ruoyi-ui/src/views/system/user/profile/userInfo.vue b/ruoyi-ui/src/views/system/user/profile/userInfo.vue
index 854b819e4..b422c513d 100644
--- a/ruoyi-ui/src/views/system/user/profile/userInfo.vue
+++ b/ruoyi-ui/src/views/system/user/profile/userInfo.vue
@@ -2,7 +2,7 @@
-
+
@@ -68,8 +68,7 @@ export default {
});
},
close() {
- this.$store.dispatch("tagsView/delView", this.$route);
- this.$router.push({ path: "/index" });
+ this.$tab.closePage();
}
}
};
diff --git a/ruoyi-ui/src/views/tool/gen/editTable.vue b/ruoyi-ui/src/views/tool/gen/editTable.vue
index 95b12cf59..6ba7f5d85 100644
--- a/ruoyi-ui/src/views/tool/gen/editTable.vue
+++ b/ruoyi-ui/src/views/tool/gen/editTable.vue
@@ -211,8 +211,8 @@ export default {
},
/** 关闭按钮 */
close() {
- this.$store.dispatch("tagsView/delView", this.$route);
- this.$router.push({ path: "/tool/gen", query: { t: Date.now(), pageNum: this.$route.query.pageNum } })
+ const obj = { path: "/tool/gen", query: { t: Date.now(), pageNum: this.$route.query.pageNum } };
+ this.$tab.closeOpenPage(obj);
}
},
mounted() {