提交 95e322d2 authored 作者: matian's avatar matian

班级数据列表平均分低于及格线标红

上级 7097b2fc
<template>
<app-container>
<app-list v-bind="tableOptions" ref="list" @sort-change="sortChange">
<app-list v-bind="tableOptions" ref="list" @sort-change="sortChange" :row-class-name="scoreRow">
<template v-slot:paper_title="{ row }">
<div :class="`paper-title active${row.ranking}`" v-if="tabActive === '2' || tabActive === '1'">
{{ row.ranking }}
......@@ -26,6 +26,9 @@ export default {
return {}
},
props: {
pass_score: {
type: Number
},
tabActive: {
type: String,
default: ''
......@@ -63,7 +66,17 @@ export default {
}
}
},
methods: {
scoreRow(row, index) {
console.log(row, 'fjgdj')
console.log(this.pass_count)
if (row.row.total_average < this.pass_score) {
return 'warning-row'
} else {
return ''
}
},
toPersonal(row) {
this.$router.push({
path:
......@@ -127,5 +140,8 @@ export default {
height: 41px;
}
}
.warning-row {
color: #c01540;
}
}
</style>
......@@ -11,7 +11,13 @@
<el-tab-pane :label="`待评价${count.commit_count}`" name="toEvaluate" lazy> </el-tab-pane>
<el-tab-pane :label="`未作答${count.cache_count}`" name="noAnswer" lazy> </el-tab-pane>
<!-- <el-tab-pane :label="`未提交${count.cache_count}`" name="toSubmit" lazy> </el-tab-pane> -->
<Finished :paramList="paramList" :tabActive="tabStatus" :key="tabStatus" @resCount="handleResCount" />
<Finished
:paramList="paramList"
:tabActive="tabStatus"
:key="tabStatus"
@resCount="handleResCount"
:pass_score="count.pass_score"
/>
</el-tabs>
</app-card>
</div>
......@@ -36,7 +42,8 @@ export default {
checked_count: 0,
commit_count: 0,
no_sheet_count: 0,
cache_count: 0
cache_count: 0,
pass_score: 0
}
}
},
......@@ -56,6 +63,7 @@ export default {
},
methods: {
handleResCount(val) {
console.log(val, '---val')
this.count = val
},
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论