|
|
|
@ -96,7 +96,9 @@ |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="userTotalScore" label="得分" align="center"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
<p v-if="scope.row.questionType === 'essay'" class="text-red">待评分</p> |
|
|
|
|
<p v-if="scope.row.questionType === 'essay' && scope.row.userTotalScore === undefined" |
|
|
|
|
class="text-red">待评分 |
|
|
|
|
</p> |
|
|
|
|
<p v-else-if="essayExist && !scope.row.paperId" class="text-red">{{ scope.row.userTotalScore |
|
|
|
|
}}分(部分试题待判分,成绩待定)</p> |
|
|
|
|
<p v-else>{{ scope.row.userTotalScore }}分</p> |
|
|
|
@ -322,7 +324,7 @@ export default { |
|
|
|
|
const opts = n.questionAnswerVersionsList |
|
|
|
|
if (type !== 'fill_blank' && type !== 'essay') { // 选择题 |
|
|
|
|
if (!n.userScore) n.userScore = 0 |
|
|
|
|
n.isCorrect = n.userScore && n.userScore === n.questionScore ? 1 : 2 |
|
|
|
|
this.handleIsCorrect(n) |
|
|
|
|
|
|
|
|
|
// 用户选择结果 |
|
|
|
|
let { userAnswer } = n |
|
|
|
@ -369,7 +371,7 @@ export default { |
|
|
|
|
if (n.userAnswerFill) rightLen = n.userAnswerFill.filter(m => m.correct).length // 正确的空的数量 |
|
|
|
|
n.isCorrect = n.userScore && n.questionScore === n.userScore ? 1 : (rightLen ? 3 : 2) |
|
|
|
|
} else if (type === 'essay') { // 简答题 |
|
|
|
|
n.isCorrect = 4 // 简答题显示待判分 |
|
|
|
|
this.handleIsCorrect(n) |
|
|
|
|
} |
|
|
|
|
}) |
|
|
|
|
}) |
|
|
|
@ -402,6 +404,10 @@ export default { |
|
|
|
|
this.loading = false |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
// 判断试题的对错 |
|
|
|
|
handleIsCorrect (n) { |
|
|
|
|
n.isCorrect = n.userScore === undefined ? 4 : (n.userScore === n.questionScore ? 1 : n.userScore ? 3 : 2) // 简答题没有reviewScore则显示待判分, 有则判断是否跟题目分数相同,完全相同是正确,小于则部分正确,0则错误 |
|
|
|
|
}, |
|
|
|
|
scrollToSmooth (position, duration) { |
|
|
|
|
let startTime = Date.now() |
|
|
|
|
|
|
|
|
@ -655,7 +661,7 @@ samp { |
|
|
|
|
|
|
|
|
|
li { |
|
|
|
|
position: relative; |
|
|
|
|
width: 30px; |
|
|
|
|
min-width: 30px; |
|
|
|
|
margin: 7px 9px; |
|
|
|
|
font-size: 13px; |
|
|
|
|
text-align: center; |
|
|
|
@ -698,6 +704,7 @@ samp { |
|
|
|
|
|
|
|
|
|
.score { |
|
|
|
|
height: 22px; |
|
|
|
|
padding: 0 2px; |
|
|
|
|
border: 1px solid #d3d3d3; |
|
|
|
|
border-top: 0; |
|
|
|
|
line-height: 22px; |
|
|
|
|