From 6e7ab962f22e09325fa2977b3ba58ad594b95673 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E5=A7=9C=E7=8E=89=E7=90=A6?=
<7507756+jiang_yuqi@user.noreply.gitee.com>
Date: Thu, 18 Jul 2024 21:52:00 +0800
Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E4=BB=A3=E7=A0=81?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/api/menu/index.ts | 4 +-
src/api/myUser/index.js | 49 +++
src/views/manage/otherTool/add.vue | 1 -
src/views/manage/otherTool/index.vue | 13 +-
src/views/system/user/index.vue | 576 ++++++++-------------------
5 files changed, 229 insertions(+), 414 deletions(-)
create mode 100644 src/api/myUser/index.js
diff --git a/src/api/menu/index.ts b/src/api/menu/index.ts
index 20dac53..3fd09d5 100644
--- a/src/api/menu/index.ts
+++ b/src/api/menu/index.ts
@@ -508,7 +508,7 @@ class MenuAPI {
meta: {
title: "角色管理",
icon: "role",
- hidden: false,
+ hidden: true,
roles: ["ADMIN6", "GUEST", "ADMIN"],
keepAlive: true,
alwaysShow: false,
@@ -533,7 +533,7 @@ class MenuAPI {
meta: {
title: "菜单管理",
icon: "menu",
- hidden: false,
+ hidden: true,
roles: ["ADMIN6", "GUEST", "ADMIN"],
keepAlive: true,
alwaysShow: false,
diff --git a/src/api/myUser/index.js b/src/api/myUser/index.js
new file mode 100644
index 0000000..c66e77c
--- /dev/null
+++ b/src/api/myUser/index.js
@@ -0,0 +1,49 @@
+import request from "@/utils/request";
+
+//获取用户列表
+const list = (data) => {
+ return request({
+ url: `/users`,
+ method: "get",
+ params: data
+ });
+}
+//新增用户
+const add = (data) => {
+ return request({
+ url: `/users`,
+ method: "post",
+ data: data
+ });
+}
+//删除用户
+const deleteUser = (id) => {
+ return request({
+ url: `/users/${id}`,
+ method: "delete"
+ });
+}
+//更新用户信息
+const updateAuth = (id, data) => {
+ return request({
+ url: `/users/${id}/auth`,
+ method: "put",
+ data: data
+ });
+}
+//更新用户密码
+const updatePassword = (id, data) => {
+ return request({
+ url: `/users/${id}/auth`,
+ method: "put",
+ data: data
+ });
+}
+
+export default {
+ list,
+ add,
+ deleteUser,
+ updateAuth,
+ updatePassword
+}
\ No newline at end of file
diff --git a/src/views/manage/otherTool/add.vue b/src/views/manage/otherTool/add.vue
index 3d29483..da41085 100644
--- a/src/views/manage/otherTool/add.vue
+++ b/src/views/manage/otherTool/add.vue
@@ -24,7 +24,6 @@
-
-
-
+ /> -->
@@ -83,8 +82,8 @@ const pageData = ref([]); // 分页数据
const removeIds = ref([]); // 删除ID集合 用于批量删除
const queryFormRef = ref(ElForm); // 查询表单
const queryParams = reactive({
- page_num: 1,
- page_size: 10,
+ //page_num: 1,
+ //page_size: 10,
tool_type: null,
});
@@ -126,8 +125,8 @@ function handleQuery() {
/** 重置查询 */
function resetQuery() {
queryFormRef.value.resetFields();
- queryParams.page_num = 1;
- queryParams.tool_type = null;
+ //queryParams.page_num = 1;
+ //queryParams.tool_type = null;
handleQuery();
}
diff --git a/src/views/system/user/index.vue b/src/views/system/user/index.vue
index 988b04c..a89492c 100644
--- a/src/views/system/user/index.vue
+++ b/src/views/system/user/index.vue
@@ -1,23 +1,16 @@
-
-
-
-
-
- 新增用户
-
+
-
-
-
-
-
+
+
+
+
+
- {{
- scope.row.status == 1 ? "正常" : "禁用"
- }}
-
-
-
-
-
-
- 重置密码修改密码
+ 修改角色
编辑删除
@@ -83,128 +66,55 @@
-
-
+
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
-
+
-
-
-
-
-
-
-
- 正常
- 禁用
-
-
-
-
-
-
-
-
+
-
-
-
-
-
-
-
- 将文件拖到此处,或
- 点击上传
-
-
- xls/xlsx files
-
-
-
@@ -218,101 +128,59 @@