|
|
|
@ -49,18 +49,18 @@ |
|
|
|
|
{{ scope.$index + (page - 1) * pageSize + 1 }} |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="schoolName" label="学校" width="150" align="center"> |
|
|
|
|
<el-table-column prop="schoolName" label="学校" min-width="150" align="center"> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="experimentalName" label="考核名称" align="center"> |
|
|
|
|
<el-table-column v-if="permissions" prop="experimentalName" label="考核名称" min-width="250" align="center"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
{{ experimentalName }} |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="userName" label="学生姓名" width="100" align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="workNumber" label="学号" width="100" align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="userName" label="学生姓名" min-width="100" align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="workNumber" label="学号" min-width="100" align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="score" label="分数" width="90" align="center"></el-table-column> |
|
|
|
|
<el-table-column label="耗时" width="90" align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="submitTime" label="提交时间" width="150" align="center"> |
|
|
|
|
<el-table-column prop="timeSum" label="耗时" width="90" align="center"></el-table-column> |
|
|
|
|
<el-table-column prop="submitTime" label="提交时间" min-width="150" align="center"> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column label="操作" align="center" width="160"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
@ -163,29 +163,25 @@ export default { |
|
|
|
|
show(row) { |
|
|
|
|
this.$router.push(`show?reportId=${row.reportId}`) |
|
|
|
|
}, |
|
|
|
|
exportData() { // 导出(有勾选:就导勾选中的;没有勾选:就导全部) |
|
|
|
|
// 导出(有勾选:就导勾选中的;没有勾选:就导全部) |
|
|
|
|
exportData() { |
|
|
|
|
// 考核和练习的接口不一样 |
|
|
|
|
let url = this.permissions |
|
|
|
|
? `${this.api.exportAssessmentInfo}?assessmentId=${this.id}&classId=${this.classId}` |
|
|
|
|
: `${this.api.exportPracticeInfo}?projectId=${this.id}` |
|
|
|
|
// 有勾选,就带上勾选的id |
|
|
|
|
if (this.multipleSelection.length) { |
|
|
|
|
let ids = this.multipleSelection.map(item => { |
|
|
|
|
return item.reportId; |
|
|
|
|
}); |
|
|
|
|
axios.get(`${this.api.exportAssessmentInfo}?assessmentId=${this.assessmentId}&classId=${this.classId}&ids=${ids.toString()}`,{ |
|
|
|
|
headers: { |
|
|
|
|
token: this.token |
|
|
|
|
}, |
|
|
|
|
responseType: 'blob' |
|
|
|
|
}).then((res) => { |
|
|
|
|
util.downloadFileDirect(`学生考核成绩.xls`,new Blob([res.data])) |
|
|
|
|
}).catch(res => {}) |
|
|
|
|
} else { |
|
|
|
|
axios.get(`${this.api.exportAssessmentInfo}?assessmentId=${this.assessmentId}&classId=${this.classId}&ids=`,{ |
|
|
|
|
const ids = this.multipleSelection.map(e => e.reportId) |
|
|
|
|
url += `&ids=${ids.toString()}` |
|
|
|
|
} |
|
|
|
|
axios.get(url, { |
|
|
|
|
headers: { |
|
|
|
|
token: this.token |
|
|
|
|
}, |
|
|
|
|
responseType: 'blob' |
|
|
|
|
}).then((res) => { |
|
|
|
|
util.downloadFileDirect(`学生考核成绩.xls`,new Blob([res.data])) |
|
|
|
|
util.downloadFileDirect(`学生${this.permissions ? '考核' : '练习'}成绩.xls`,new Blob([res.data])) |
|
|
|
|
}).catch(res => {}) |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
handleDelete(row) { // 删除 |
|
|
|
|
this.$confirm("确定要删除吗?", "提示", { |
|
|
|
|