master
yujialong 4 years ago
parent 5ce6df59a1
commit 28fd4a59d8
  1. 5
      src/components/page/Achievement.vue
  2. 12
      src/components/page/Assessment.vue
  3. 6
      src/components/page/Dashboard.vue
  4. 12
      src/components/page/Evaluation.vue
  5. 5
      src/components/page/ExperimentAss.vue
  6. 12
      src/components/page/Match.vue
  7. 8
      src/components/page/Project.vue
  8. 9
      src/components/page/Staff.vue
  9. 19
      src/components/page/Student.vue
  10. 10
      src/router/routes.js
  11. 2
      src/utils/api.js

@ -51,6 +51,7 @@
round round
class="bt_one" class="bt_one"
@click="delAllData" @click="delAllData"
v-auth
>批量删除</el-button> >批量删除</el-button>
</div> </div>
</div> </div>
@ -103,8 +104,8 @@
</el-table-column> </el-table-column>
<el-table-column label="操作" align="center"> <el-table-column label="操作" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="text" @click="entry(scope.row)">成绩管理</el-button> <el-button type="text" v-auth @click="entry(scope.row)">成绩管理</el-button>
<el-button v-if="projectPermissions" type="text" @click="handleDelete(scope.row)" :disabled="!scope.row.isdel">删除</el-button> <el-button v-if="projectPermissions" v-auth type="text" @click="handleDelete(scope.row)" :disabled="!scope.row.isdel">删除</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>

@ -55,6 +55,7 @@
round round
@click="add" @click="add"
class="bt_one" class="bt_one"
v-auth
>创建实验</el-button> >创建实验</el-button>
<el-button <el-button
type="primary" type="primary"
@ -63,6 +64,7 @@
round round
class="bt_one" class="bt_one"
@click="delAllData" @click="delAllData"
v-auth
>批量删除</el-button> >批量删除</el-button>
</div> </div>
</div> </div>
@ -114,16 +116,16 @@
<el-table-column label="操作" align="center" width="170"> <el-table-column label="操作" align="center" width="170">
<template slot-scope="scope"> <template slot-scope="scope">
<template v-if="scope.row.status == 1"> <template v-if="scope.row.status == 1">
<el-button type="text" @click="start(scope.row)">启动</el-button> <el-button type="text" v-auth @click="start(scope.row)">启动</el-button>
<el-button type="text" @click="edit(scope.row)">修改</el-button> <el-button type="text" v-auth @click="edit(scope.row)">修改</el-button>
</template> </template>
<template v-else-if="scope.row.status == 2"> <template v-else-if="scope.row.status == 2">
<el-button type="text" @click="finish(scope.row)">提前结束</el-button> <el-button type="text" v-auth @click="finish(scope.row)">提前结束</el-button>
</template> </template>
<template v-else-if="scope.row.status == 3"> <template v-else-if="scope.row.status == 3">
<el-button type="text" @click="show(scope.row)">查看成绩</el-button> <el-button type="text" v-auth @click="show(scope.row)">查看成绩</el-button>
</template> </template>
<el-button v-if="scope.row.status == 1 || scope.row.status == 3" type="text" @click="delData(scope.row)">删除</el-button> <el-button v-if="scope.row.status == 1 || scope.row.status == 3" type="text" @click="delData(scope.row)" v-auth>删除</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>

@ -75,8 +75,8 @@
</div> </div>
</div> </div>
<div class="list-btn flex-around editor-btn"> <div class="list-btn flex-around editor-btn">
<el-button type="text" icon="el-icon-edit" @click="editClass(item)">编辑</el-button> <el-button type="text" icon="el-icon-edit" @click="editClass(item)" v-auth="'dashboard:编辑'">编辑</el-button>
<el-button type="text" icon="el-icon-delete" @click="delClass(item,index)">删除</el-button> <el-button type="text" icon="el-icon-delete" @click="delClass(item,index)" v-auth="'dashboard:删除'">删除</el-button>
</div> </div>
</el-card> </el-card>
</el-col> </el-col>
@ -84,7 +84,7 @@
<el-col :span="6"> <el-col :span="6">
<el-card shadow="hover" class="editor-btn mgb20" @click.native="addClass"> <el-card shadow="hover" class="editor-btn mgb20" @click.native="addClass">
<div class="flex-center addClass-view"> <div class="flex-center addClass-view">
<el-button type="text" icon="el-icon-plus">创建班级</el-button> <el-button type="text" icon="el-icon-plus" v-auth="'dashboard:创建'">创建班级</el-button>
</div> </div>
</el-card> </el-card>
</el-col> </el-col>

@ -2,7 +2,7 @@
<div> <div>
<div class="Bank_m"> <div class="Bank_m">
<div style="text-align: right"> <div style="text-align: right">
<el-button type="primary" size="small" round @click="getInfo">测评设置</el-button> <el-button type="primary" size="small" round @click="getInfo" v-auth>测评设置</el-button>
</div> </div>
<el-dialog title="测评设置" :visible.sync="SetEvaluation" width="30%" :close-on-click-modal="false"> <el-dialog title="测评设置" :visible.sync="SetEvaluation" width="30%" :close-on-click-modal="false">
@ -224,6 +224,7 @@
round round
class="bt_one" class="bt_one"
@click="addTopics" @click="addTopics"
v-auth
>新增题目</el-button> >新增题目</el-button>
<el-button <el-button
type="primary" type="primary"
@ -232,6 +233,7 @@
round round
class="bt_one" class="bt_one"
@click="showBatchUpload" @click="showBatchUpload"
v-auth
>批量上传</el-button> >批量上传</el-button>
<el-button <el-button
type="primary" type="primary"
@ -240,6 +242,7 @@
round round
class="bt_one" class="bt_one"
@click="delAllData" @click="delAllData"
v-auth
>批量删除</el-button> >批量删除</el-button>
</div> </div>
</div> </div>
@ -270,10 +273,10 @@
<el-table-column label="操作" align="center"> <el-table-column label="操作" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<template v-if="scope.row.isEnable"> <template v-if="scope.row.isEnable">
<el-button type="text" @click="showQues(scope.row)">查看</el-button> <el-button type="text" v-auth @click="showQues(scope.row)">查看</el-button>
</template> </template>
<template v-else> <template v-else>
<el-button type="text" @click="editQues(scope.row)">修改</el-button> <el-button type="text" v-auth @click="editQues(scope.row)">修改</el-button>
</template> </template>
<el-switch <el-switch
v-model="scope.row.isEnable" v-model="scope.row.isEnable"
@ -282,8 +285,9 @@
:inactive-value="0" :inactive-value="0"
style="margin: 0 10px 0 5px" style="margin: 0 10px 0 5px"
@change="switchQues($event,scope.row,scope.$index)" @change="switchQues($event,scope.row,scope.$index)"
v-auth="'evaluation:禁用'"
></el-switch> ></el-switch>
<el-button type="text" @click="delData(scope.row)">删除</el-button> <el-button type="text" @click="delData(scope.row)" v-auth>删除</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>

@ -143,7 +143,6 @@ export default {
let not = 0 let not = 0
list.map(n => { list.map(n => {
n.class = this.className n.class = this.className
score += n.score
if(!n.isRead){ if(!n.isRead){
not++ not++
}else{ }else{
@ -154,6 +153,10 @@ export default {
this.not = not this.not = not
} }
list.map(n => {
score += n.score
})
this.listDataAll = list this.listDataAll = list
this.handlePage() this.handlePage()
this.totals = list.length this.totals = list.length

@ -55,6 +55,7 @@
round round
@click="add" @click="add"
class="bt_one" class="bt_one"
v-auth
>创建实验</el-button> >创建实验</el-button>
<el-button <el-button
type="primary" type="primary"
@ -63,6 +64,7 @@
round round
class="bt_one" class="bt_one"
@click="delAllData" @click="delAllData"
v-auth
>批量删除</el-button> >批量删除</el-button>
</div> </div>
</div> </div>
@ -119,16 +121,16 @@
<el-table-column label="操作" align="center" width="170"> <el-table-column label="操作" align="center" width="170">
<template slot-scope="scope"> <template slot-scope="scope">
<template v-if="scope.row.status == 1"> <template v-if="scope.row.status == 1">
<el-button type="text" @click="start(scope.row)">启动</el-button> <el-button type="text" v-auth @click="start(scope.row)">启动</el-button>
<el-button type="text" @click="edit(scope.row)">修改</el-button> <el-button type="text" v-auth @click="edit(scope.row)">修改</el-button>
</template> </template>
<template v-else-if="scope.row.status == 2"> <template v-else-if="scope.row.status == 2">
<el-button type="text" @click="finish(scope.row)">提前结束</el-button> <el-button type="text" v-auth @click="finish(scope.row)">提前结束</el-button>
</template> </template>
<template v-else-if="scope.row.status == 3"> <template v-else-if="scope.row.status == 3">
<el-button type="text" @click="show(scope.row)">查看成绩</el-button> <el-button type="text" v-auth @click="show(scope.row)">查看成绩</el-button>
</template> </template>
<el-button v-if="scope.row.status == 1 || scope.row.status == 3" type="text" @click="delData(scope.row)">删除</el-button> <el-button v-if="scope.row.status == 1 || scope.row.status == 3" type="text" @click="delData(scope.row)" v-auth>删除</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>

@ -62,8 +62,8 @@
<span>项目列表</span> <span>项目列表</span>
</div> </div>
<div> <div>
<el-button type="primary" size="small" round @click="add">新增项目</el-button> <el-button type="primary" size="small" v-auth round @click="add">新增项目</el-button>
<el-button type="primary" size="small" round @click="delAllData">批量删除</el-button> <el-button type="primary" size="small" v-auth round @click="delAllData">批量删除</el-button>
</div> </div>
</div> </div>
<el-table :data="projectData" class="table" ref="table" stripe header-align="center" @selection-change="handleSelectionChange"> <el-table :data="projectData" class="table" ref="table" stripe header-align="center" @selection-change="handleSelectionChange">
@ -92,8 +92,8 @@
</el-table-column> </el-table-column>
<el-table-column label="操作"> <el-table-column label="操作">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="text" @click="edit(scope.row)" v-if="roleId == 1 || (roleId == 13 && scope.row.founder != '超级管理员') || (roleId == 14 && scope.row.founder == '老师')">编辑</el-button> <el-button type="text" v-auth @click="edit(scope.row)" v-if="roleId == 1 || (roleId == 13 && scope.row.founder != '超级管理员') || (roleId == 14 && scope.row.founder == '老师')">编辑</el-button>
<el-button type="text" @click="delData(scope.row)" v-if="roleId == 1 || (roleId == 13 && scope.row.founder != '超级管理员') || (roleId == 14 && scope.row.founder == '老师')">删除</el-button> <el-button type="text" v-auth @click="delData(scope.row)" v-if="roleId == 1 || (roleId == 13 && scope.row.founder != '超级管理员') || (roleId == 14 && scope.row.founder == '老师')">删除</el-button>
<!-- <el-button type="text" @click="copyData(scope.row)">复制</el-button> --> <!-- <el-button type="text" @click="copyData(scope.row)">复制</el-button> -->
</template> </template>
</el-table-column> </el-table-column>

@ -442,6 +442,7 @@ export default {
this.teacherForm.userAccount = user.account this.teacherForm.userAccount = user.account
this.teacherForm.userId = user.userId this.teacherForm.userId = user.userId
this.teacherForm.schoolId = user.schoolId this.teacherForm.schoolId = user.schoolId
this.teacherForm.uniqueIdentificationAccount = user.uniqueIdentificationAccount
or.forEach((n,i) => { or.forEach((n,i) => {
this.teacherForm.roleValue.push(this.roleStatus(n.roleId)) this.teacherForm.roleValue.push(this.roleStatus(n.roleId))
if(n.roleId == 13) { if(n.roleId == 13) {
@ -590,19 +591,19 @@ export default {
data = { data = {
workNumber: this.encodeString(this.teacherForm.managerWorkNumber), workNumber: this.encodeString(this.teacherForm.managerWorkNumber),
roleId: 13, roleId: 13,
schoolId: this.teacherForm.schoolId // schoolId: this.teacherForm.schoolId
} }
msg = '该管理员工号已存在' msg = '该管理员工号已存在'
}else if(type == 14){ }else if(type == 14){
data = { data = {
workNumber: this.encodeString(this.teacherForm.teacherWorkNumber), workNumber: this.encodeString(this.teacherForm.teacherWorkNumber),
roleId: 14, roleId: 14,
schoolId: this.teacherForm.schoolId // schoolId: this.teacherForm.schoolId
} }
msg = '该老师工号已存在' msg = '该老师工号已存在'
} }
let res = await this.$get(this.api.queryWorkNumberIsExist, data); let res = await this.$get(this.api.queryStaffWorkNumberIsExist, data);
if(JSON.stringify(res.message) != '{}'){ if(JSON.stringify(res.status) == 201){
this.$message.warning(msg); this.$message.warning(msg);
type == 13 ? (this.managerNumberNoAdd = false) : (this.teacherNumberNoAdd = false) type == 13 ? (this.managerNumberNoAdd = false) : (this.teacherNumberNoAdd = false)
}else{ }else{

@ -25,12 +25,12 @@
<el-card shadow="hover"> <el-card shadow="hover">
<div class="flex-between mgb20"> <div class="flex-between mgb20">
<div> <div>
<el-button type="primary" size="small" round @click="addStudent">新增学生</el-button> <el-button type="primary" size="small" v-auth round @click="addStudent">新增学生</el-button>
<el-button type="primary" size="small" round @click="batchImport">批量导入</el-button> <el-button type="primary" size="small" v-auth round @click="batchImport">批量导入</el-button>
<el-button type="primary" size="small" round @click="delAllSelection">批量删除</el-button> <el-button type="primary" size="small" v-auth round @click="delAllSelection">批量删除</el-button>
</div> </div>
<div> <div>
<el-input placeholder="请输入学生姓名/学校名称" prefix-icon="el-icon-search" v-model="keyword" clearable></el-input> <el-input placeholder="请输入学生姓名/学号/学校名称" prefix-icon="el-icon-search" style="width: 260px" v-model="keyword" clearable></el-input>
</div> </div>
</div> </div>
<el-table :data="studentData" class="table" ref="table" stripe header-align="center" @selection-change="handleSelectionChange" :row-key="getRowKeys"> <el-table :data="studentData" class="table" ref="table" stripe header-align="center" @selection-change="handleSelectionChange" :row-key="getRowKeys">
@ -40,6 +40,8 @@
<el-table-column prop="account" label="账号" align="center"> <el-table-column prop="account" label="账号" align="center">
</el-table-column> </el-table-column>
<el-table-column prop="schoolName" label="院校" align="center"></el-table-column> <el-table-column prop="schoolName" label="院校" align="center"></el-table-column>
<el-table-column prop="workNumber" label="学号" align="center">
</el-table-column>
<el-table-column prop="userName" label="学生姓名" align="center"> <el-table-column prop="userName" label="学生姓名" align="center">
</el-table-column> </el-table-column>
<el-table-column prop="className" label="班级" align="center"></el-table-column> <el-table-column prop="className" label="班级" align="center"></el-table-column>
@ -54,16 +56,17 @@
</el-table-column> </el-table-column>
<el-table-column label="操作" align="center" width="300"> <el-table-column label="操作" align="center" width="300">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="text" @click="editStudent(scope.row,true)">查看</el-button> <el-button type="text" v-auth @click="editStudent(scope.row,true)">查看</el-button>
<el-button type="text" @click="editStudent(scope.row,false)">编辑</el-button> <el-button type="text" v-auth @click="editStudent(scope.row,false)">编辑</el-button>
<el-button type="text" @click="resetPassword(scope.row)">重置密码</el-button> <el-button type="text" v-auth @click="resetPassword(scope.row)">重置密码</el-button>
<el-button type="text" @click="handleDelete(scope.row)">删除</el-button> <el-button type="text" v-auth @click="handleDelete(scope.row)">删除</el-button>
<el-switch <el-switch
v-model="scope.row.disableAccount" v-model="scope.row.disableAccount"
:active-value="0" :active-value="0"
:inactive-value="1" :inactive-value="1"
style="margin: 0 5px" style="margin: 0 5px"
@change="switchOff($event,scope.row,scope.$index)" @change="switchOff($event,scope.row,scope.$index)"
v-auth="'学生管理:禁用'"
></el-switch> ></el-switch>
</template> </template>
</el-table-column> </el-table-column>

@ -16,6 +16,7 @@ export default [
} }
}, },
{ {
name: 'dashboard',
path: '/dashboard', path: '/dashboard',
component: () => import('../components/page/Dashboard.vue'), component: () => import('../components/page/Dashboard.vue'),
meta: { title: '班级教学' } meta: { title: '班级教学' }
@ -31,6 +32,7 @@ export default [
meta: { title: '新建班级' } meta: { title: '新建班级' }
}, },
{ {
name: 'assessment',
path: '/assessment', path: '/assessment',
component: () => import('../components/page/Assessment.vue'), component: () => import('../components/page/Assessment.vue'),
meta: { title: '考核管理' } meta: { title: '考核管理' }
@ -41,6 +43,7 @@ export default [
meta: { title: '考核管理' } meta: { title: '考核管理' }
}, },
{ {
name: 'achievement',
path: '/achievement', path: '/achievement',
component: () => import('../components/page/Achievement.vue'), component: () => import('../components/page/Achievement.vue'),
meta: { title: '成绩管理' } meta: { title: '成绩管理' }
@ -86,11 +89,13 @@ export default [
meta: { title: '用户管理' } meta: { title: '用户管理' }
}, },
{ {
name: 'evaluation',
path: '/evaluation', path: '/evaluation',
component: () => import('../components/page/Evaluation.vue'), component: () => import('../components/page/Evaluation.vue'),
meta: { title: '测评管理' } meta: { title: '测评管理' }
}, },
{ {
name: 'project',
path: '/project', path: '/project',
component: () => import('../components/page/Project.vue'), component: () => import('../components/page/Project.vue'),
meta: { title: '实验项目管理' } meta: { title: '实验项目管理' }
@ -111,16 +116,19 @@ export default [
meta: { title: '查看判分点' } meta: { title: '查看判分点' }
}, },
{ {
name: 'student',
path: '/student', path: '/student',
component: () => import('../components/page/Student.vue'), component: () => import('../components/page/Student.vue'),
meta: { title: '学生管理' } meta: { title: '学生管理' }
}, },
{ {
name: 'match',
path: '/match', path: '/match',
component: () => import('../components/page/Match.vue'), component: () => import('../components/page/Match.vue'),
meta: { title: '竞赛实验' } meta: { title: '竞赛实验' }
}, },
{ {
name: 'backstage',
path: '/backstage', path: '/backstage',
component: () => import('../components/page/Backstage.vue'), component: () => import('../components/page/Backstage.vue'),
meta: { title: '业务后台' } meta: { title: '业务后台' }
@ -141,11 +149,13 @@ export default [
meta: { title: '老师评语' } meta: { title: '老师评语' }
}, },
{ {
name: 'staff',
path: '/staff', path: '/staff',
component: () => import('../components/page/Staff.vue'), component: () => import('../components/page/Staff.vue'),
meta: { title: '用户管理' } meta: { title: '用户管理' }
}, },
{ {
name: 'system',
path: '/system', path: '/system',
component: () => import('../components/page/System.vue'), component: () => import('../components/page/System.vue'),
meta: { title: '系统设置' } meta: { title: '系统设置' }

@ -24,7 +24,7 @@ export default {
queryAccountIsExist:`${host}/liuwanr/userInfo/queryAccountIsExist`,//查询员工,学生账号是否存在接口 queryAccountIsExist:`${host}/liuwanr/userInfo/queryAccountIsExist`,//查询员工,学生账号是否存在接口
queryWorkNumberIsExist:`${host}/evaluation/tms/userInfo/queryWorkNumberIsExist`,//查询学号是否存在 queryWorkNumberIsExist:`${host}/evaluation/tms/userInfo/queryWorkNumberIsExist`,//查询学号是否存在
queryWorkNumberIsExist1:`${host}/liuwanr/userInfo/queryWorkNumberIsExist`,//查询工号是否存在 queryStaffWorkNumberIsExist:`${host}/evaluation/tms/system/queryStaffWorkNumberIsExist`,//查询工号是否存在
querySchool: `${host}/liuwanr/customer/querySchool`, //根据学校名称查询学校信息 querySchool: `${host}/liuwanr/customer/querySchool`, //根据学校名称查询学校信息
queryPersonalCenter:`${host}/liuwanr/personalCenter/queryPersonalCenter`, queryPersonalCenter:`${host}/liuwanr/personalCenter/queryPersonalCenter`,

Loading…
Cancel
Save