| | |
| | | <div class="search"> |
| | | <div class="left"> |
| | | <div class="id"> |
| | | 姓名/手机号 |
| | | <el-input v-model="inputText" placeholder="请输入"></el-input> |
| | | 用户名/姓名/手机号 |
| | | <el-input v-model="inputText" placeholder="请输入" clearable></el-input> |
| | | </div> |
| | | |
| | | <div class="cluster"> |
| | | <div class="cluster" v-show="false"> |
| | | 授权时长 |
| | | <el-select @change="findUserList" v-model="timeLength" placeholder="请选择"> |
| | | <el-option v-for="item in durationArr" :key="item.value" :label="item.label" :value="item.value"> |
| | |
| | | <el-table-column label="序号" width="55" class-name="index"> |
| | | <template slot-scope="scope">{{ scope.$index + 1 + (page - 1) * size }}</template> |
| | | </el-table-column> |
| | | <el-table-column prop="username" label="用户名" show-overflow-tooltip></el-table-column> |
| | | <el-table-column prop="trueName" label="姓名" show-overflow-tooltip></el-table-column> |
| | | <el-table-column prop="phoneNum" label="手机号" show-overflow-tooltip></el-table-column> |
| | | <el-table-column prop="userType" label="用户类型"> |
| | | <el-table-column prop="username" label="用户名" show-overflow-tooltip ></el-table-column> |
| | | <el-table-column prop="trueName" label="姓名" show-overflow-tooltip ></el-table-column> |
| | | <el-table-column prop="phoneNum" label="手机号" show-overflow-tooltip ></el-table-column> |
| | | <el-table-column prop="userType" label="用户类型" > |
| | | <template slot-scope="scope"> |
| | | <span>{{ scope.row.userType == 1 ? "本地" : "OA账户" }}</span> |
| | | </template> |
| | |
| | | <!-- <el-table-column prop="authDuration" label="授权时长"> |
| | | </el-table-column> --> |
| | | <!-- <el-table-column prop="dataNames" label="公司"> </el-table-column> --> |
| | | <el-table-column prop="companyName" label="部门" show-overflow-tooltip></el-table-column> |
| | | <el-table-column prop="companyName" label="部门" show-overflow-tooltip min-width="200px"></el-table-column> |
| | | |
| | | <!-- <el-table-column label="状态"> |
| | | <template slot-scope="scope"> |
| | |
| | | </template> |
| | | </el-table-column> --> |
| | | |
| | | <el-table-column label="操作"> |
| | | <el-table-column label="操作" align="center" width="100px"> |
| | | <template slot-scope="scope"> |
| | | <span class="iconfont option" @click="editUser(scope.row)">编辑</span> |
| | | <span class="iconfont option" style="color:red" @click="delUser(scope.row)">删除</span> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import { findUserList, saveSubUser, getMenu, getDataTree } from "@/api/user" |
| | | import { findUserList, saveSubUser, getMenu, getDataTree, deleteUser } from "@/api/user" |
| | | import { getAreas, getDic } from "@/api/login" |
| | | |
| | | import Steps from "./Steps" |
| | |
| | | this.ruleForm.companyName = row.companyName |
| | | this.ruleForm.phoneNum = row.phoneNum |
| | | this.ruleForm.email = row.email |
| | | this.ruleForm.isChangePwd = row.isChangePwd |
| | | this.ruleForm.isChangePwd = false |
| | | this.ruleForm.industryId = row.industryId |
| | | this.ruleForm.areaId = row.areaId |
| | | this.ruleForm.address = [row.provinceId, row.areaId] |
| | |
| | | this.$refs.ztreeMenus.updateNodes(cameraIds) |
| | | } |
| | | }, |
| | | delUser(row) { |
| | | this.$confirm('确认要删除该用户吗, 是否继续?', '提示', { |
| | | confirmButtonText: '确定', |
| | | cancelButtonText: '取消', |
| | | type: 'warning' |
| | | }).then(async () => { |
| | | let rsp = await deleteUser({id:row.id}) |
| | | if (rsp && rsp.success) { |
| | | this.$message({ |
| | | type: 'success', |
| | | message: '删除成功!' |
| | | }); |
| | | } |
| | | |
| | | this.findUserList() |
| | | }) |
| | | }, |
| | | resetUser() { |
| | | this.ruleForm = { |
| | | id: "", |