From ef4bfde4a8d43e012ade7c3e8946f4c121fc578d Mon Sep 17 00:00:00 2001 From: RuoYi <yzz_ivy@163.com> Date: 星期一, 22 十一月 2021 18:06:44 +0800 Subject: [PATCH] 优化提示信息 --- ruoyi-ui/src/views/system/dict/data.vue | 2 ruoyi-ui/src/views/system/role/selectUser.vue | 4 ++ ruoyi-ui/src/views/system/user/profile/resetPwd.vue | 9 +--- ruoyi-ui/src/views/system/role/index.vue | 3 - ruoyi-ui/src/views/system/menu/index.vue | 35 +++++++++-------- ruoyi-ui/src/views/system/user/index.vue | 3 - ruoyi-ui/src/views/system/dept/index.vue | 6 +-- ruoyi-ui/src/views/monitor/operlog/index.vue | 4 +- ruoyi-ui/src/components/RightToolbar/index.vue | 2 ruoyi-ui/src/views/login.vue | 8 +++- ruoyi-ui/src/plugins/tab.js | 4 - ruoyi-quartz/src/main/java/com/ruoyi/quartz/config/ScheduleConfig.java | 2 ruoyi-ui/src/api/monitor/server.js | 2 ruoyi-ui/src/views/system/user/profile/userAvatar.vue | 4 +- ruoyi-ui/src/views/monitor/logininfor/index.vue | 4 +- 15 files changed, 46 insertions(+), 46 deletions(-) diff --git a/ruoyi-quartz/src/main/java/com/ruoyi/quartz/config/ScheduleConfig.java b/ruoyi-quartz/src/main/java/com/ruoyi/quartz/config/ScheduleConfig.java index e466ed0..e35eb26 100644 --- a/ruoyi-quartz/src/main/java/com/ruoyi/quartz/config/ScheduleConfig.java +++ b/ruoyi-quartz/src/main/java/com/ruoyi/quartz/config/ScheduleConfig.java @@ -7,7 +7,7 @@ import java.util.Properties; /** - * 定时任务配置 + * 定时任务配置(单机部署建议删除此类和qrtz数据库表,默认走内存会最高效) * * @author ruoyi */ diff --git a/ruoyi-ui/src/api/monitor/server.js b/ruoyi-ui/src/api/monitor/server.js index 4991a44..cac7791 100644 --- a/ruoyi-ui/src/api/monitor/server.js +++ b/ruoyi-ui/src/api/monitor/server.js @@ -1,6 +1,6 @@ import request from '@/utils/request' -// 查询服务器详细 +// 获取服务信息 export function getServer() { return request({ url: '/monitor/server', diff --git a/ruoyi-ui/src/components/RightToolbar/index.vue b/ruoyi-ui/src/components/RightToolbar/index.vue index c7ab139..976974e 100644 --- a/ruoyi-ui/src/components/RightToolbar/index.vue +++ b/ruoyi-ui/src/components/RightToolbar/index.vue @@ -62,7 +62,7 @@ }, // 右侧列表元素变化 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/plugins/tab.js b/ruoyi-ui/src/plugins/tab.js index f2d7b22..95a3848 100644 --- a/ruoyi-ui/src/plugins/tab.js +++ b/ruoyi-ui/src/plugins/tab.js @@ -20,8 +20,6 @@ path: '/redirect' + path }) }) - - }, // 关闭当前tab页签,打开新页签 closeOpenPage(obj) { @@ -56,7 +54,7 @@ return store.dispatch('tagsView/delOthersViews', obj || router.currentRoute); }, // 添加tab页签 - addPage(title, url) { + openPage(title, url) { var obj = { path: url, meta: { title: title } } store.dispatch('tagsView/addView', obj); return router.push(url); diff --git a/ruoyi-ui/src/views/login.vue b/ruoyi-ui/src/views/login.vue index 255eafc..3baaf24 100644 --- a/ruoyi-ui/src/views/login.vue +++ b/ruoyi-ui/src/views/login.vue @@ -3,7 +3,12 @@ <el-form ref="loginForm" :model="loginForm" :rules="loginRules" class="login-form"> <h3 class="title">若依后台管理系统</h3> <el-form-item prop="username"> - <el-input v-model="loginForm.username" type="text" auto-complete="off" placeholder="账号"> + <el-input + v-model="loginForm.username" + type="text" + auto-complete="off" + placeholder="账号" + > <svg-icon slot="prefix" icon-class="user" class="el-input__icon input-icon" /> </el-input> </el-form-item> @@ -66,7 +71,6 @@ 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 0f4ecbb..98bd743 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" /> </el-form-item> @@ -16,8 +16,8 @@ v-model="queryParams.userName" placeholder="请输入用户名称" clearable + size="small" style="width: 240px;" - size="small" @keyup.enter.native="handleQuery" /> </el-form-item> diff --git a/ruoyi-ui/src/views/monitor/operlog/index.vue b/ruoyi-ui/src/views/monitor/operlog/index.vue index 28f705b..9b8b785 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" /> </el-form-item> @@ -16,8 +16,8 @@ v-model="queryParams.operName" placeholder="请输入操作人员" clearable - style="width: 240px;" size="small" + style="width: 240px;" @keyup.enter.native="handleQuery" /> </el-form-item> diff --git a/ruoyi-ui/src/views/system/dept/index.vue b/ruoyi-ui/src/views/system/dept/index.vue index f9c7741..e215b1c 100644 --- a/ruoyi-ui/src/views/system/dept/index.vue +++ b/ruoyi-ui/src/views/system/dept/index.vue @@ -179,8 +179,6 @@ isExpandAll: true, // 重新渲染表格状态 refreshTable: true, - // 是否展开 - expand: false, // 查询参数 queryParams: { deptName: undefined, @@ -276,7 +274,7 @@ 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 @@ 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 aa878bd..c08c28a 100644 --- a/ruoyi-ui/src/views/system/dict/data.vue +++ b/ruoyi-ui/src/views/system/dict/data.vue @@ -325,7 +325,7 @@ this.queryParams.pageNum = 1; this.getList(); }, - // 返回按钮 + /** 返回按钮操作 */ handleClose() { const obj = { path: "/system/dict" }; this.$tab.closeOpenPage(obj); diff --git a/ruoyi-ui/src/views/system/menu/index.vue b/ruoyi-ui/src/views/system/menu/index.vue index a89e1ee..d65773a 100644 --- a/ruoyi-ui/src/views/system/menu/index.vue +++ b/ruoyi-ui/src/views/system/menu/index.vue @@ -78,7 +78,8 @@ </el-table-column> <el-table-column label="操作" align="center" class-name="small-padding fixed-width"> <template slot-scope="scope"> - <el-button size="mini" + <el-button + size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)" @@ -126,8 +127,8 @@ </el-radio-group> </el-form-item> </el-col> - <el-col :span="24"> - <el-form-item v-if="form.menuType != 'F'" label="菜单图标"> + <el-col :span="24" v-if="form.menuType != 'F'"> + <el-form-item label="菜单图标"> <el-popover placement="bottom-start" width="460" @@ -158,8 +159,8 @@ <el-input-number v-model="form.orderNum" controls-position="right" :min="0" /> </el-form-item> </el-col> - <el-col :span="12"> - <el-form-item v-if="form.menuType != 'F'"> + <el-col :span="12" v-if="form.menuType != 'F'"> + <el-form-item> <span slot="label"> <el-tooltip content="选择是外链则路由地址需要以`http(s)://`开头" placement="top"> <i class="el-icon-question"></i> @@ -172,8 +173,8 @@ </el-radio-group> </el-form-item> </el-col> - <el-col :span="12"> - <el-form-item v-if="form.menuType != 'F'" prop="path"> + <el-col :span="12" v-if="form.menuType != 'F'"> + <el-form-item prop="path"> <span slot="label"> <el-tooltip content="访问的路由地址,如:`user`,如外网地址需内链访问则以`http(s)://`开头" placement="top"> <i class="el-icon-question"></i> @@ -194,8 +195,8 @@ <el-input v-model="form.component" placeholder="请输入组件路径" /> </el-form-item> </el-col> - <el-col :span="12"> - <el-form-item v-if="form.menuType != 'M'"> + <el-col :span="12" v-if="form.menuType != 'M'"> + <el-form-item> <el-input v-model="form.perms" placeholder="请输入权限标识" maxlength="100" /> <span slot="label"> <el-tooltip content="控制器中定义的权限字符,如:@PreAuthorize(`@ss.hasPermi('system:user:list')`)" placement="top"> @@ -205,8 +206,8 @@ </span> </el-form-item> </el-col> - <el-col :span="12"> - <el-form-item v-if="form.menuType == 'C'"> + <el-col :span="12" v-if="form.menuType == 'C'"> + <el-form-item> <el-input v-model="form.query" placeholder="请输入路由参数" maxlength="255" /> <span slot="label"> <el-tooltip content='访问路由的默认传递参数,如:`{"id": 1, "name": "ry"}`' placement="top"> @@ -216,8 +217,8 @@ </span> </el-form-item> </el-col> - <el-col :span="12"> - <el-form-item v-if="form.menuType == 'C'"> + <el-col :span="12" v-if="form.menuType == 'C'"> + <el-form-item> <span slot="label"> <el-tooltip content="选择是则会被`keep-alive`缓存,需要匹配组件的`name`和地址保持一致" placement="top"> <i class="el-icon-question"></i> @@ -230,8 +231,8 @@ </el-radio-group> </el-form-item> </el-col> - <el-col :span="12"> - <el-form-item v-if="form.menuType != 'F'"> + <el-col :span="12" v-if="form.menuType != 'F'"> + <el-form-item> <span slot="label"> <el-tooltip content="选择隐藏则路由将不会出现在侧边栏,但仍然可以访问" placement="top"> <i class="el-icon-question"></i> @@ -247,8 +248,8 @@ </el-radio-group> </el-form-item> </el-col> - <el-col :span="12"> - <el-form-item v-if="form.menuType != 'F'"> + <el-col :span="12" v-if="form.menuType != 'F'"> + <el-form-item> <span slot="label"> <el-tooltip content="选择停用则路由将不会出现在侧边栏,也不能被访问" placement="top"> <i class="el-icon-question"></i> diff --git a/ruoyi-ui/src/views/system/role/index.vue b/ruoyi-ui/src/views/system/role/index.vue index b2cfd6b..5b99d17 100644 --- a/ruoyi-ui/src/views/system/role/index.vue +++ b/ruoyi-ui/src/views/system/role/index.vue @@ -355,8 +355,7 @@ /** 查询角色列表 */ 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 a9e2ce0..02610d8 100644 --- a/ruoyi-ui/src/views/system/role/selectUser.vue +++ b/ruoyi-ui/src/views/system/role/selectUser.vue @@ -123,6 +123,10 @@ 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/index.vue b/ruoyi-ui/src/views/system/user/index.vue index 2b7283f..3525c9b 100644 --- a/ruoyi-ui/src/views/system/user/index.vue +++ b/ruoyi-ui/src/views/system/user/index.vue @@ -206,7 +206,7 @@ </el-col> </el-row> - <!-- 添加或修改参数配置对话框 --> + <!-- 添加或修改用户配置对话框 --> <el-dialog :title="title" :visible.sync="open" width="600px" append-to-body> <el-form ref="form" :model="form" :rules="rules" label-width="80px"> <el-row> @@ -652,7 +652,6 @@ /** 下载模板操作 */ 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 3437abc..06715e5 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 @@ } }; return { - test: "1test", user: { oldPassword: undefined, newPassword: undefined, @@ -55,11 +54,9 @@ 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("修改成功"); + }); } }); }, diff --git a/ruoyi-ui/src/views/system/user/profile/userAvatar.vue b/ruoyi-ui/src/views/system/user/profile/userAvatar.vue index 402d9cc..63903a7 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 @@ <template> <div> <div class="user-info-head" @click="editCropper()"><img v-bind:src="options.img" title="点击上传头像" class="img-circle img-lg" /></div> - <el-dialog :title="title" :visible.sync="open" width="800px" append-to-body @opened="modalOpened" @close="closeDialog()"> + <el-dialog :title="title" :visible.sync="open" width="800px" append-to-body @opened="modalOpened" @close="closeDialog"> <el-row> <el-col :xs="24" :md="12" :style="{height: '350px'}"> <vue-cropper @@ -140,7 +140,7 @@ // 关闭窗口 closeDialog() { this.options.img = store.getters.avatar - this.visible = false; + this.visible = false; } } }; -- Gitblit v1.9.2