| | |
| | | :label="user.id" |
| | | :key="user.id" |
| | | > |
| | | {{ user.username }} |
| | | {{ user.username}} |
| | | </el-checkbox> |
| | | </el-checkbox-group> |
| | | </div> |
| | |
| | | // 获取所有用户信息 |
| | | getUserList() { |
| | | // 获取所有用户信息、用户查询(暂时支持电话号码) |
| | | this.$axios.get(`sccg/admin/list`).then((res) => { |
| | | this.$axios.get(`/sccg/depart/query_surplus_user`).then((res) => { |
| | | if (res.code === 200) { |
| | | this.userList = res.data.records; |
| | | this.userList = res.data; |
| | | } |
| | | }); |
| | | }, |
| | |
| | | this.checkedList.forEach((e) => { |
| | | this.checkedUser.push(e.userId); |
| | | }); |
| | | console.log(this.checkedUser) |
| | | this.$axios({ |
| | | method: "get", |
| | | url: "sccg/depart/tree", |
| | | }).then((res) => { |
| | | that.departList = res.data; |
| | | }); |
| | | this.getUserList(); |
| | | this.getUserList(this.user.id); |
| | | // 获取部门类型 |
| | | this.getDepartType(); |
| | | }, |
| | |
| | | }, |
| | | |
| | | // 获取所有用户信息 |
| | | getUserList() { |
| | | getUserList(id) { |
| | | // 获取所有用户信息、用户查询(暂时支持电话号码) |
| | | this.$axios.get(`sccg/admin/list`).then((res) => { |
| | | this.$axios.get(`/sccg/depart/query_surplus_exist_user?id=`+id).then((res) => { |
| | | if (res.code === 200) { |
| | | this.userList = res.data.records; |
| | | this.userList = res.data; |
| | | } |
| | | }); |
| | | }, |
| | |
| | | // 修改用户信息 |
| | | 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}`; |
| | |
| | | } 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({ |