master
tangyi 2022-01-20 00:29:07 +08:00
parent 77a582ca9e
commit dd7a950c31
3 changed files with 248 additions and 15628 deletions

15598
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -123,7 +123,7 @@
<el-table :data="tableData" style="width: 100%" max-height="500"> <el-table :data="tableData" style="width: 100%" max-height="500">
<el-table-column align="center" prop="id" label="用户ID" /> <el-table-column align="center" prop="id" label="用户ID" />
<el-table-column align="center" prop="idCard" label="身份证号" /> <el-table-column align="center" prop="idCard" label="身份证号" />
<el-table-column align="center" prop="topic" label="人格类型" /> <el-table-column align="center" prop="topicTopicStr" label="人格类型" />
<el-table-column align="center" label="允许参测人员查看测试结果"> <el-table-column align="center" label="允许参测人员查看测试结果">
<template #default="scope"> <template #default="scope">
@ -289,17 +289,17 @@ export default {
id: data.id, id: data.id,
isAllowViewResult, isAllowViewResult,
}); });
// this.axios this.axios
// .post("/hysc/test/allowViewResult", { .post("/hysc/test/allowViewResult", {
// id: data.id, id: data.id,
// isAllowViewResult, isAllowViewResult,
// }) })
// .then(function (response) { .then(function (response) {
// console.log(response.data.data); console.log(response.data.data);
// }) })
// .catch(function (error) { .catch(function (error) {
// console.log(error); console.log(error);
// }); });
}, },
allowAllViewResult() { allowAllViewResult() {
this.axios this.axios

View File

@ -3,9 +3,24 @@
<NavLeft navIf="index" /> <NavLeft navIf="index" />
<div class="consumer"> <div class="consumer">
<div class="indexTit"> <div class="indexTit">
<p @click="indexTitIfFun(1)" :class="indexTitIf==1?'indexTitIf':''">系统管理员</p> <p
<p @click="indexTitIfFun(2)" :class="indexTitIf==2?'indexTitIf':''">普通管理员</p> @click="indexTitIfFun(1)"
<p @click="indexTitIfFun(3)" :class="indexTitIf==3?'indexTitIf':''">权限说明</p> :class="indexTitIf == 1 ? 'indexTitIf' : ''"
>
系统管理员
</p>
<p
@click="indexTitIfFun(2)"
:class="indexTitIf == 2 ? 'indexTitIf' : ''"
>
普通管理员
</p>
<p
@click="indexTitIfFun(3)"
:class="indexTitIf == 3 ? 'indexTitIf' : ''"
>
权限说明
</p>
</div> </div>
<div v-if="indexTitIf == 1"> <div v-if="indexTitIf == 1">
<div class="consumer-seach"> <div class="consumer-seach">
@ -17,7 +32,6 @@
class="input-with-select" class="input-with-select"
style="width: 340px" style="width: 340px"
> >
</el-input> </el-input>
</li> </li>
@ -33,7 +47,10 @@
<el-table-column align="center" prop="name" label="账号信息" /> <el-table-column align="center" prop="name" label="账号信息" />
<el-table-column align="center" prop="phone" label="手机号" /> <el-table-column align="center" prop="phone" label="手机号" />
<el-table-column align="center" #default="scope" label="是否启用"> <el-table-column align="center" #default="scope" label="是否启用">
<el-switch v-model="scope.row.statusIf" @change="addUsername(scope.row)" /> <el-switch
v-model="scope.row.statusIf"
@change="addUsername(scope.row)"
/>
</el-table-column> </el-table-column>
<el-table-column align="center" #default="scope" label="操作"> <el-table-column align="center" #default="scope" label="操作">
<el-button type="text" size="small" @click="queryName(scope)" <el-button type="text" size="small" @click="queryName(scope)"
@ -60,19 +77,18 @@
</div> </div>
<div v-if="indexTitIf == 3"> <div v-if="indexTitIf == 3">
<div class='quanian'> <div class="quanian">
<p>系统管理员权限</p> <p>系统管理员权限</p>
<p>1.生成测试</p> <p>1.生成测试</p>
<p>2.生成测试二维码配置二维码有效期</p> <p>2.生成测试二维码配置二维码有效期</p>
<p>3.配置某人某次考生可以查看测试结果导出测试报告</p> <p>3.配置某人某次考生可以查看测试结果导出测试报告</p>
</div> </div>
<div class='quanian'> <div class="quanian">
<p>普通成员权限</p> <p>普通成员权限</p>
<p>1.查看所有数据</p> <p>1.查看所有数据</p>
<p>2.编辑题库</p> <p>2.编辑题库</p>
</div> </div>
</div> </div>
</div> </div>
<el-drawer <el-drawer
@ -164,6 +180,7 @@ export default {
// //
this.userData = JSON.parse(localStorage.userData); this.userData = JSON.parse(localStorage.userData);
this.getReportList(); this.getReportList();
this.getroleData()
}, },
methods: { methods: {
upLoad(e) { upLoad(e) {
@ -217,7 +234,7 @@ export default {
.get("/hysc/system/role/getRoleList") .get("/hysc/system/role/getRoleList")
.then(function (response) { .then(function (response) {
that.roleData = response.data.data; that.roleData = response.data.data;
console.log(that.roleData);
}) })
.catch(function (error) { .catch(function (error) {
console.log(error); console.log(error);
@ -234,7 +251,7 @@ export default {
this.usernameDataIf = ifS; this.usernameDataIf = ifS;
}, },
indexTitIfFun(data) { indexTitIfFun(data) {
this.indexTitIf=data this.indexTitIf = data;
}, },
// //
@ -262,7 +279,7 @@ indexTitIfFun(data){
this.getroleData(); this.getroleData();
}, },
queryNamea(data) { queryNamea(data) {
let that=this let that = this;
this.axios this.axios
.post("/hysc/user/delUserById", { id: data.row.id }) .post("/hysc/user/delUserById", { id: data.row.id })
.then(function (response) { .then(function (response) {
@ -296,11 +313,16 @@ indexTitIfFun(data){
that.tableData = response.data.data.records; that.tableData = response.data.data.records;
for (let index = 0; index < that.tableData.length; index++) { for (let index = 0; index < that.tableData.length; index++) {
if (that.tableData[index].status == 1) { if (that.tableData[index].status == 1) {
that.tableData[index].statusIf=false that.tableData[index].statusIf = false;
} else { } else {
that.tableData[index].statusIf=true that.tableData[index].statusIf = true;
} }
} }
console.log(that.roleDatam,"123");
that.total = response.data.data.total; that.total = response.data.data.total;
}) })
.catch(function (error) { .catch(function (error) {
@ -333,17 +355,15 @@ indexTitIfFun(data){
if (data) { if (data) {
this.adduserData.id = data.id; this.adduserData.id = data.id;
if (this.adduserData.statusIf) { if (this.adduserData.statusIf) {
this.adduserData.status=0 this.adduserData.status = 0;
} else { } else {
this.adduserData.status=1 this.adduserData.status = 1;
} }
} else { } else {
this.adduserData.avatar = this.imgData; this.adduserData.avatar = this.imgData;
this.adduserData.phone=this.adduserData.account this.adduserData.phone = this.adduserData.account;
} }
this.axios this.axios
.post("/hysc/user/submit", this.adduserData) .post("/hysc/user/submit", this.adduserData)
.then(function (response) { .then(function (response) {