成绩管理统计等

master
yujialong 9 months ago
parent 8d0e6ec72f
commit 192221dd33
  1. 2
      src/api/index.js
  2. 18
      src/pages/achievement/info/course.vue
  3. 1
      src/pages/achievement/info/project.vue
  4. 5
      src/pages/project/add/index.vue
  5. 6
      src/pages/screen/index.vue
  6. 2
      src/pages/system/list/index.vue
  7. 32
      src/pages/system/list/staff.vue
  8. 8
      src/pages/system/list/staffSide.vue

@ -331,7 +331,7 @@ export default {
saveGrade: `occupationlab/occupationlab/staff/saveGrade`, //新增年级 saveGrade: `occupationlab/occupationlab/staff/saveGrade`, //新增年级
updateGrade: `occupationlab/occupationlab/staff/updateGrade`, //编辑年级 updateGrade: `occupationlab/occupationlab/staff/updateGrade`, //编辑年级
deleteGrade: `occupationlab/occupationlab/staff/deleteGrade`, //删除年级 deleteGrade: `occupationlab/occupationlab/staff/deleteGrade`, //删除年级
// 员工管理 // 教师管理
saveStaff: `occupationlab/occupationlab/staff/saveStaff`, //新增员工 saveStaff: `occupationlab/occupationlab/staff/saveStaff`, //新增员工
staffDetail: `occupationlab/occupationlab/staff/staffDetail`, //员工详情 staffDetail: `occupationlab/occupationlab/staff/staffDetail`, //员工详情
modifyStaff: `occupationlab/occupationlab/staff/modifyStaff`, //编辑员工 modifyStaff: `occupationlab/occupationlab/staff/modifyStaff`, //编辑员工

@ -10,13 +10,6 @@
<el-card shadow="hover" <el-card shadow="hover"
class="m-b-20"> class="m-b-20">
<!-- <el-radio-group v-model="classId"
size="small">
<el-radio v-for="(item, i) in classList"
:key="i"
:label="item.id"
@change="initData">{{ item.className }}</el-radio>
</el-radio-group> -->
<el-tabs v-model="classId" <el-tabs v-model="classId"
@tab-click="classChange"> @tab-click="classChange">
<el-tab-pane v-for="(item, i) in classList" <el-tab-pane v-for="(item, i) in classList"
@ -301,7 +294,7 @@ export default {
accountId: this.$route.query.accountId, accountId: this.$route.query.accountId,
id: +this.$route.query.id, id: +this.$route.query.id,
cid: +this.$route.query.cid, cid: +this.$route.query.cid,
classId: this.$route.query.classId ? +this.$route.query.classId : '', classId: this.$route.query.classId || '',
classList: [], classList: [],
keyword: "", keyword: "",
searchTimer: null, searchTimer: null,
@ -339,7 +332,7 @@ export default {
} }
}, },
mounted () { mounted () {
this.classId = +this.$route.query.classId || '' this.classId = this.$route.query.classId || ''
this.getClass() this.getClass()
}, },
methods: { methods: {
@ -389,6 +382,9 @@ export default {
// //
getClass () { getClass () {
this.$post(this.api.allClassesInOurSchool).then(({ data }) => { this.$post(this.api.allClassesInOurSchool).then(({ data }) => {
data.forEach(e => {
e.id = e.id + ''
})
if (data.length && !this.classId) this.classId = data[0].id if (data.length && !this.classId) this.classId = data[0].id
this.classList = data this.classList = data
this.initData() this.initData()
@ -432,7 +428,9 @@ export default {
}) })
list = practice ? res.userScoreList.records : res.listOfAssessmentResults.records list = practice ? res.userScoreList.records : res.listOfAssessmentResults.records
} }
const curClass = this.classList.find(e => e.id == this.classId)
list.forEach(e => { list.forEach(e => {
e.className = curClass ? curClass.className : ''
e.goodsName = this.goodsName e.goodsName = this.goodsName
e.cid = this.cid e.cid = this.cid
}) })
@ -565,6 +563,7 @@ export default {
for (const i in this.stageNumber) { for (const i in this.stageNumber) {
data[+(i.replace('num', '')) - 1] = this.stageNumber[i] data[+(i.replace('num', '')) - 1] = this.stageNumber[i]
} }
console.log("🚀 ~ getChart ~ data:", data)
let myChart = echarts.init(document.getElementById("chart")); let myChart = echarts.init(document.getElementById("chart"));
myChart.setOption({ myChart.setOption({
title: { text: "实验分数分布图" }, title: { text: "实验分数分布图" },
@ -579,7 +578,6 @@ export default {
yAxis: { yAxis: {
name: "人数", name: "人数",
type: "value", type: "value",
interval: 5,
minInterval: 5, minInterval: 5,
}, },
series: [{ series: [{

@ -547,7 +547,6 @@ export default {
yAxis: { yAxis: {
name: this.permissions ? "人数" : '成绩报告数量', name: this.permissions ? "人数" : '成绩报告数量',
type: "value", type: "value",
interval: 5,
minInterval: 5, minInterval: 5,
}, },
series: [{ series: [{

@ -629,8 +629,9 @@ export default {
}); });
} }
}, },
scoreChange (row, index, val) { // scoreChange (row, i) {
this.projectJudgmentData.splice(index, 1, row); row.score = row.score.replace(/[^\d]/g, '')
this.projectJudgmentData.splice(i, 1, row);
}, },
delJudgePoint (index) { // delJudgePoint (index) { //
this.$confirm("确定要删除吗?", "提示", { this.$confirm("确定要删除吗?", "提示", {

@ -397,8 +397,12 @@ export default {
data () { data () {
return { return {
token: Util.local.get(Setting.tokenKey), token: Util.local.get(Setting.tokenKey),
time: 0, time: 2,
times: [ times: [
{
id: 2,
name: '年'
},
{ {
id: 0, id: 0,
name: '月' name: '月'

@ -51,7 +51,7 @@ export default {
}, },
initTabs () { initTabs () {
const { btns } = this const { btns } = this
const tab1 = btns.includes('/system/list:员工管理') const tab1 = btns.includes('/system/list:教师管理')
const tab2 = btns.includes('/system/list:角色权限') const tab2 = btns.includes('/system/list:角色权限')
const tab3 = btns.includes('/system/list:系统logo设置') const tab3 = btns.includes('/system/list:系统logo设置')
tab1 || delete this.tabs.staff tab1 || delete this.tabs.staff

@ -18,15 +18,15 @@
</li> </li>
</ul> </ul>
<div> <div>
<el-button v-auth="'员工管理:新增员工'" <el-button v-auth="'教师管理:新增教师'"
type="info" type="info"
round round
@click="addTeacher">新增教师</el-button> @click="addTeacher">新增教师</el-button>
<el-button v-auth="'员工管理:批量导入'" <el-button v-auth="'教师管理:批量导入'"
type="primary" type="primary"
round round
@click="batchImport">批量导入</el-button> @click="batchImport">批量导入</el-button>
<el-button v-auth="'员工管理:批量删除'" <el-button v-auth="'教师管理:批量删除'"
type="primary" type="primary"
round round
@click="delAllSelection">批量删除</el-button> @click="delAllSelection">批量删除</el-button>
@ -68,16 +68,16 @@
width="200" width="200"
align="center"> align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button v-auth="'员工管理:员工查看'" <el-button v-auth="'教师管理:教师查看'"
type="text" type="text"
@click="showTeacher(scope.row)">查看</el-button> @click="showTeacher(scope.row)">查看</el-button>
<el-button v-auth="'员工管理:员工编辑'" <el-button v-auth="'教师管理:教师编辑'"
type="text" type="text"
@click="editTeacher(scope.row)">编辑</el-button> @click="editTeacher(scope.row)">编辑</el-button>
<el-button v-auth="'员工管理:重置密码'" <el-button v-auth="'教师管理:重置密码'"
type="text" type="text"
@click="resetPassword(scope.row)">重置密码</el-button> @click="resetPassword(scope.row)">重置密码</el-button>
<el-button v-auth="'员工管理:员工删除'" <el-button v-auth="'教师管理:教师删除'"
type="text" type="text"
@click="delTeacher(scope.row)">删除</el-button> @click="delTeacher(scope.row)">删除</el-button>
</template> </template>
@ -218,7 +218,7 @@ export default {
isAdd: false, isAdd: false,
teacherVisible: false, teacherVisible: false,
roleList: [], // roleList: [], //
orgList: [], // orgList: [], //
casProps: { casProps: {
value: 'id' value: 'id'
}, },
@ -267,7 +267,7 @@ export default {
phoneRepeat: false, phoneRepeat: false,
emailRepeat: false, emailRepeat: false,
listData: [], // listData: [], //
keyword: "", keyword: "",
page: 1, page: 1,
pageSize: 10, pageSize: 10,
@ -278,9 +278,9 @@ export default {
uploadList: [], // uploadList: [], //
uploadFaild: false, // uploadFaild: false, //
gradeId: "", // ID gradeId: "", // ID
staffArchitectureId: "", // ID staffArchitectureId: "", // ID
submiting: false // submiting: false //
}; };
}, },
components: { components: {
@ -325,7 +325,7 @@ export default {
this.page = 1 this.page = 1
this.getData() this.getData()
}, },
getData () { // getData () { //
let data = { let data = {
keyWord: this.keyword, keyWord: this.keyword,
pageNum: this.page, pageNum: this.page,
@ -351,7 +351,7 @@ export default {
// this.roleList = res.rolePage.records; // this.roleList = res.rolePage.records;
}).catch(res => { }); }).catch(res => { });
}, },
closeTeacher () { // / closeTeacher () { // /
this.form = { this.form = {
accountId: "", accountId: "",
account: "", account: "",
@ -366,13 +366,13 @@ export default {
this.$refs.form.clearValidate(); this.$refs.form.clearValidate();
this.teacherVisible = false; this.teacherVisible = false;
}, },
addTeacher () { // addTeacher () { //
this.isDetail = false; this.isDetail = false;
this.isAdd = true; this.isAdd = true;
this.teacherVisible = true; this.teacherVisible = true;
this.orgList = this.$refs.org.orgList; this.orgList = this.$refs.org.orgList;
}, },
getStaffDetail (accountId) { // getStaffDetail (accountId) { //
this.$get(`${this.api.staffDetail}?accountId=${accountId}`).then(res => { this.$get(`${this.api.staffDetail}?accountId=${accountId}`).then(res => {
let { data } = res; let { data } = res;
this.form = data; this.form = data;

@ -6,7 +6,7 @@
style="margin-bottom: 0">教师组织架构</h6> style="margin-bottom: 0">教师组织架构</h6>
<el-button type="text" <el-button type="text"
@click="addMajor" @click="addMajor"
v-auth="'员工管理:新增专业'">添加</el-button> v-auth="'教师管理:新增专业'">添加</el-button>
</div> </div>
<org-tree :data="orgList" <org-tree :data="orgList"
show-checkbox show-checkbox
@ -22,18 +22,18 @@
slot-scope="{ node, data }"> slot-scope="{ node, data }">
<span style="display: inline-block; margin-right: 20px">{{ node.label }}</span> <span style="display: inline-block; margin-right: 20px">{{ node.label }}</span>
<span> <span>
<el-button v-auth="'员工管理:新增专业'" <el-button v-auth="'教师管理:新增专业'"
type="text" type="text"
icon="el-icon-edit-outline" icon="el-icon-edit-outline"
@click="() => handleEdit(node, data)"> @click="() => handleEdit(node, data)">
</el-button> </el-button>
<el-button v-auth="'员工管理:编辑专业'" <el-button v-auth="'教师管理:编辑专业'"
v-if="node.level === 1" v-if="node.level === 1"
type="text" type="text"
icon="el-icon-circle-plus-outline" icon="el-icon-circle-plus-outline"
@click="() => handleAdd(node, data)"> @click="() => handleAdd(node, data)">
</el-button> </el-button>
<el-button v-auth="'员工管理:删除专业'" <el-button v-auth="'教师管理:删除专业'"
type="text" type="text"
icon="el-icon-delete" icon="el-icon-delete"
@click="() => handleDel(node, data)"> @click="() => handleDel(node, data)">

Loading…
Cancel
Save