From cbae45c7cea1c41091aceafcac324340b9b7aa74 Mon Sep 17 00:00:00 2001 From: RuoYi Date: Mon, 4 Oct 2021 10:28:13 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E5=8D=87=E7=BA=A7element-ui=E5=88=B0?= =?UTF-8?q?=E6=9C=80=E6=96=B0=E7=89=88=E6=9C=AC2.15.5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pom.xml | 4 ++-- ruoyi-ui/package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pom.xml b/pom.xml index 2e1d5e075..c1d9a291c 100644 --- a/pom.xml +++ b/pom.xml @@ -21,8 +21,8 @@ 1.2.6 1.21 3.0.0 - 2.3.2 - 2.1.4 + 2.3.2 + 2.1.4 1.3.1 1.2.78 5.8.0 diff --git a/ruoyi-ui/package.json b/ruoyi-ui/package.json index c7db2d8ed..034e0642d 100644 --- a/ruoyi-ui/package.json +++ b/ruoyi-ui/package.json @@ -41,7 +41,7 @@ "clipboard": "2.0.6", "core-js": "3.8.1", "echarts": "4.9.0", - "element-ui": "2.15.5", + "element-ui": "2.15.6", "file-saver": "2.0.5", "fuse.js": "6.4.3", "highlight.js": "9.18.5", From f7f006e162b1e68a6734e9f54d22ca7d15724cb4 Mon Sep 17 00:00:00 2001 From: caohong Date: Wed, 29 Dec 2021 13:53:33 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=20=E4=BF=AE=E6=94=B9=E6=96=B9=E6=B3=95?= =?UTF-8?q?=E5=90=8D=E7=A7=B0praseStrEmpty=E4=B8=BAparseStrEmpty?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ruoyi-ui/src/api/system/user.js | 254 ++++++++++++++++---------------- ruoyi-ui/src/utils/ruoyi.js | 2 +- 2 files changed, 128 insertions(+), 128 deletions(-) diff --git a/ruoyi-ui/src/api/system/user.js b/ruoyi-ui/src/api/system/user.js index 577bea24c..4fd752b4b 100644 --- a/ruoyi-ui/src/api/system/user.js +++ b/ruoyi-ui/src/api/system/user.js @@ -1,127 +1,127 @@ -import request from '@/utils/request' -import { praseStrEmpty } from "@/utils/ruoyi"; - -// 查询用户列表 -export function listUser(query) { - return request({ - url: '/system/user/list', - method: 'get', - params: query - }) -} - -// 查询用户详细 -export function getUser(userId) { - return request({ - url: '/system/user/' + praseStrEmpty(userId), - method: 'get' - }) -} - -// 新增用户 -export function addUser(data) { - return request({ - url: '/system/user', - method: 'post', - data: data - }) -} - -// 修改用户 -export function updateUser(data) { - return request({ - url: '/system/user', - method: 'put', - data: data - }) -} - -// 删除用户 -export function delUser(userId) { - return request({ - url: '/system/user/' + userId, - method: 'delete' - }) -} - -// 用户密码重置 -export function resetUserPwd(userId, password) { - const data = { - userId, - password - } - return request({ - url: '/system/user/resetPwd', - method: 'put', - data: data - }) -} - -// 用户状态修改 -export function changeUserStatus(userId, status) { - const data = { - userId, - status - } - return request({ - url: '/system/user/changeStatus', - method: 'put', - data: data - }) -} - -// 查询用户个人信息 -export function getUserProfile() { - return request({ - url: '/system/user/profile', - method: 'get' - }) -} - -// 修改用户个人信息 -export function updateUserProfile(data) { - return request({ - url: '/system/user/profile', - method: 'put', - data: data - }) -} - -// 用户密码重置 -export function updateUserPwd(oldPassword, newPassword) { - const data = { - oldPassword, - newPassword - } - return request({ - url: '/system/user/profile/updatePwd', - method: 'put', - params: data - }) -} - -// 用户头像上传 -export function uploadAvatar(data) { - return request({ - url: '/system/user/profile/avatar', - method: 'post', - data: data - }) -} - -// 查询授权角色 -export function getAuthRole(userId) { - return request({ - url: '/system/user/authRole/' + userId, - method: 'get' - }) -} - -// 保存授权角色 -export function updateAuthRole(data) { - return request({ - url: '/system/user/authRole', - method: 'put', - params: data - }) -} +import request from '@/utils/request' +import { parseStrEmpty } from "@/utils/ruoyi"; + +// 查询用户列表 +export function listUser(query) { + return request({ + url: '/system/user/list', + method: 'get', + params: query + }) +} + +// 查询用户详细 +export function getUser(userId) { + return request({ + url: '/system/user/' + parseStrEmpty(userId), + method: 'get' + }) +} + +// 新增用户 +export function addUser(data) { + return request({ + url: '/system/user', + method: 'post', + data: data + }) +} + +// 修改用户 +export function updateUser(data) { + return request({ + url: '/system/user', + method: 'put', + data: data + }) +} + +// 删除用户 +export function delUser(userId) { + return request({ + url: '/system/user/' + userId, + method: 'delete' + }) +} + +// 用户密码重置 +export function resetUserPwd(userId, password) { + const data = { + userId, + password + } + return request({ + url: '/system/user/resetPwd', + method: 'put', + data: data + }) +} + +// 用户状态修改 +export function changeUserStatus(userId, status) { + const data = { + userId, + status + } + return request({ + url: '/system/user/changeStatus', + method: 'put', + data: data + }) +} + +// 查询用户个人信息 +export function getUserProfile() { + return request({ + url: '/system/user/profile', + method: 'get' + }) +} + +// 修改用户个人信息 +export function updateUserProfile(data) { + return request({ + url: '/system/user/profile', + method: 'put', + data: data + }) +} + +// 用户密码重置 +export function updateUserPwd(oldPassword, newPassword) { + const data = { + oldPassword, + newPassword + } + return request({ + url: '/system/user/profile/updatePwd', + method: 'put', + params: data + }) +} + +// 用户头像上传 +export function uploadAvatar(data) { + return request({ + url: '/system/user/profile/avatar', + method: 'post', + data: data + }) +} + +// 查询授权角色 +export function getAuthRole(userId) { + return request({ + url: '/system/user/authRole/' + userId, + method: 'get' + }) +} + +// 保存授权角色 +export function updateAuthRole(data) { + return request({ + url: '/system/user/authRole', + method: 'put', + params: data + }) +} diff --git a/ruoyi-ui/src/utils/ruoyi.js b/ruoyi-ui/src/utils/ruoyi.js index 4cc5e24ea..0c4c77bbe 100644 --- a/ruoyi-ui/src/utils/ruoyi.js +++ b/ruoyi-ui/src/utils/ruoyi.js @@ -108,7 +108,7 @@ export function sprintf(str) { } // 转换字符串,undefined,null等转化为"" -export function praseStrEmpty(str) { +export function parseStrEmpty(str) { if (!str || str == "undefined" || str == "null") { return ""; }