From 73b48dd59a2d47b365b87784371c4ef57dde659b Mon Sep 17 00:00:00 2001
From: Oliver <1070107765@qq.com>
Date: 星期四, 22 十二月 2022 11:17:47 +0800
Subject: [PATCH] 首页新增

---
 src/views/systemSetting/baseSetting/user/components/updateUser/index.vue |   35 +++++++----------------------------
 1 files changed, 7 insertions(+), 28 deletions(-)

diff --git a/src/views/systemSetting/baseSetting/user/components/updateUser/index.vue b/src/views/systemSetting/baseSetting/user/components/updateUser/index.vue
index 86f30f7..e631c7e 100644
--- a/src/views/systemSetting/baseSetting/user/components/updateUser/index.vue
+++ b/src/views/systemSetting/baseSetting/user/components/updateUser/index.vue
@@ -60,8 +60,8 @@
     },
     created() {
         this.user = JSON.parse(JSON.stringify(this.userInfo));
-        this.tempName = this.user.departName;
-        this.selectOrg.orgsid.push(this.user.departmentId);
+        this.tempName = this.user.depart[0].departName;
+        this.selectOrg.orgsid.push(this.user.depart[0].id);
         // 鑾峰彇鎵�鏈夎鑹插垪琛�
         this.getRoleList();
         // 鑾峰彇褰撳墠鐢ㄦ埛瑙掕壊鍒楄〃
@@ -83,6 +83,7 @@
         // 淇敼鐢ㄦ埛淇℃伅
         handleUser() {
             const { flag, user, tempName, selectOrg, tempRole, isArraySame } = this;
+            let umsDepartManage = { userId: user.id, departId: selectOrg.orgsid[0] }
             this.$refs.user.validate((valid) => {
                 if (valid) {
                     user.isDy = `${user.isDy}`;
@@ -95,30 +96,8 @@
                         } else {
                             if (user.departName) {
                                 this.$axios({
-                                    method: 'post',
-                                    url: `sccg/admin/update/${user.id}`,
-                                    data: {
-                                        "id": user.id,
-                                        "username": user.username,
-                                        "password": user.password,
-                                        "icon": user.icon,
-                                        "email": user.email,
-                                        "nickName": user.nickName,
-                                        "note": user.note,
-                                        "createTime": user.createTime,
-                                        "loginTime": user.loginTime,
-                                        "status": user.status ? 1 : 0,
-                                        "macAddress": user.macAddress,
-                                        "ipAddress": user.ipAddress,
-                                        "isDy": `${user.isDy}`,
-                                        "sex": `${user.sex}`,
-                                        "jobTitle": user.jobTitle,
-                                        "departmentId": selectOrg.orgsid[0],
-                                        "departName": user.departName,
-                                        "userType": user.userType,
-                                        "zj": user.zj,
-                                        "mobile": user.mobile,
-                                    }
+                                    method: 'put',
+                                    url: `/sccg/depart/user_update_depart?userId=` + user.id + '&departId=' + selectOrg.orgsid[0]
                                 })
                                     .then(res => {
                                         this.$message({
@@ -151,8 +130,8 @@
                         }
                         else {
                             this.$axios({
-                                method: 'post',
-                                url: 'sccg/admin/role/update?adminId=' + user.id + '&roleIds=' + user.role,
+                                method: 'put',
+                                url: 'sccg/depart/user_update_Role?id=' + user.id + '&roles=' + user.role,
                             })
                                 .then(res => {
                                     this.$message({

--
Gitblit v1.8.0