|
|
|
@ -29,9 +29,8 @@ |
|
|
|
|
</li> |
|
|
|
|
<li> |
|
|
|
|
<label>课程</label> |
|
|
|
|
<el-select v-model="form.mallId" @change="initData"> |
|
|
|
|
<el-option v-for="(item, i) in curs" :key="i" :label="item.curriculumName" :value="item.mallId" |
|
|
|
|
@change="curChange"></el-option> |
|
|
|
|
<el-select v-model="form.curriculumId" @change="initData"> |
|
|
|
|
<el-option v-for="(item, i) in curs" :key="i" :label="item.curriculumName" :value="item.cid"></el-option> |
|
|
|
|
</el-select> |
|
|
|
|
</li> |
|
|
|
|
<li> |
|
|
|
@ -63,6 +62,7 @@ |
|
|
|
|
</el-table-column> |
|
|
|
|
</template> |
|
|
|
|
<el-table-column prop="projectName" label="项目名称" align="center" min-width="180"></el-table-column> |
|
|
|
|
<!-- <el-table-column prop="origin" label="类型" align="center" width="120"></el-table-column> --> |
|
|
|
|
<el-table-column prop="projectPermissions" label="分类" align="center" width="100"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
{{ form.permissions ? '考核' : '练习' }} |
|
|
|
@ -96,7 +96,7 @@ export default { |
|
|
|
|
return { |
|
|
|
|
form: { |
|
|
|
|
classId: +this.$route.query.classId || '', |
|
|
|
|
mallId: +this.$route.query.mallId || '', |
|
|
|
|
curriculumId: +this.$route.query.curriculumId || '', |
|
|
|
|
permissions: this.$route.query.permissions ? +this.$route.query.permissions : 0, |
|
|
|
|
month: +this.$route.query.month || '', |
|
|
|
|
startTime: +this.$route.query.startTime || '', |
|
|
|
@ -183,21 +183,18 @@ export default { |
|
|
|
|
|
|
|
|
|
// 获取课程 |
|
|
|
|
async getCourse () { |
|
|
|
|
const { data } = await this.$get(this.api.getSchoolEffectiveCourse) |
|
|
|
|
this.curs = data |
|
|
|
|
this.form.mallId = this.form.mallId || data[0].mallId |
|
|
|
|
this.getData(); |
|
|
|
|
}, |
|
|
|
|
// 课程选择回调 |
|
|
|
|
curChange (id) { |
|
|
|
|
this.$router.push({ |
|
|
|
|
path: 'list', |
|
|
|
|
query: { |
|
|
|
|
...this.$route.query, |
|
|
|
|
mallId: id |
|
|
|
|
} |
|
|
|
|
}) |
|
|
|
|
this.initData() |
|
|
|
|
if (this.$parent.active === 'tab2') { |
|
|
|
|
const { data } = await this.$get(this.api.getSchoolEffectiveCourse) |
|
|
|
|
this.curs = data |
|
|
|
|
this.form.curriculumId = this.form.curriculumId || data[0].cid |
|
|
|
|
} else { |
|
|
|
|
const res = await this.$get(this.api.getchoolBuiltCoursesList) |
|
|
|
|
const data = res.schoolCourse |
|
|
|
|
this.curs = data |
|
|
|
|
this.form.curriculumId = this.form.curriculumId || data[0].cid |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
this.getData() |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
getClassData () { // 获取班级下拉框数据 |
|
|
|
@ -207,12 +204,12 @@ export default { |
|
|
|
|
}, |
|
|
|
|
getData () { |
|
|
|
|
this.loading = true |
|
|
|
|
const { mallId, permissions } = this.form |
|
|
|
|
const cur = this.curs.find(e => e.mallId == mallId) || {} |
|
|
|
|
const { curriculumId, permissions } = this.form |
|
|
|
|
const cur = this.curs.find(e => e.cid == curriculumId) || {} |
|
|
|
|
let data = { |
|
|
|
|
...this.form, |
|
|
|
|
curriculumId: cur.cid, |
|
|
|
|
systemId: cur.systemId, |
|
|
|
|
mallId: cur.mallId || '', |
|
|
|
|
systemId: cur.systemId || '', |
|
|
|
|
pageNum: this.page, |
|
|
|
|
pageSize: this.pageSize, |
|
|
|
|
}; |
|
|
|
@ -250,10 +247,10 @@ export default { |
|
|
|
|
}, |
|
|
|
|
// 进入实验记录 |
|
|
|
|
entry (row) { |
|
|
|
|
const { mallId } = this.form |
|
|
|
|
const cur = this.curs.find(e => e.mallId == mallId) || {} |
|
|
|
|
const { curriculumId } = this.form |
|
|
|
|
const cur = this.curs.find(e => e.cid == curriculumId) || {} |
|
|
|
|
this.$store.commit('achievement/setReferrer', `${this.$route.path}?${qs.stringify(this.form)}&page=${this.page}`) |
|
|
|
|
this.$router.push(`project?id=${row.assessmentId || row.projectId || ''}&paperId=${row.paperId || ''}&cid=${cur.cid}&projectName=${row.projectName || ''}&permissions=${this.form.permissions}&mallId=${this.form.mallId}&classId=${row.classId || ''}`) |
|
|
|
|
this.$router.push(`project?id=${row.assessmentId || row.projectId || ''}&paperId=${row.paperId || ''}&cid=${curriculumId}&projectName=${row.projectName || ''}&permissions=${this.form.permissions}&mallId=${cur.mallId || ''}&classId=${row.classId || ''}`) |
|
|
|
|
}, |
|
|
|
|
handleDelete (row) { // 删除 |
|
|
|
|
this.$confirm("该项目下的所有成绩报告将会删除,是否继续?", "提示", { |
|
|
|
|