|
@@ -396,8 +396,9 @@ export default defineComponent({
|
|
|
const questionWithScore = Object.entries(scoreGroups);
|
|
|
const questionWithTotalScore = questionWithScore.map((v) => [
|
|
|
v[0],
|
|
|
- v[1].map((s) => s.score * 100).reduce((acc, c) => (acc += c), 0) /
|
|
|
- 100,
|
|
|
+ v[1]
|
|
|
+ .map((s) => Math.round(s.score * 100))
|
|
|
+ .reduce((acc, c) => (acc += c), 0) / 100,
|
|
|
]);
|
|
|
const questionWithTotalScoreSorted = sortBy(
|
|
|
questionWithTotalScore,
|
|
@@ -421,7 +422,7 @@ export default defineComponent({
|
|
|
v.subNumber === cq.subNumber
|
|
|
)
|
|
|
.map((v) => v.score)
|
|
|
- .reduce((acc, v) => (acc += v * 100), 0) / 100;
|
|
|
+ .reduce((acc, v) => (acc += Math.round(v * 100)), 0) / 100;
|
|
|
}
|
|
|
markResult.scoreList = scoreList as number[];
|
|
|
// const sortScore = orderBy(markResult.trackList, ['mainNumber', 'subNumber', 'score']);
|
|
@@ -433,7 +434,7 @@ export default defineComponent({
|
|
|
markResult.markerScore =
|
|
|
markResult.scoreList
|
|
|
.filter((v): v is number => v !== null)
|
|
|
- .reduce((acc, v) => (acc += v * 100), 0) / 100;
|
|
|
+ .reduce((acc, v) => (acc += Math.round(v * 100)), 0) / 100;
|
|
|
|
|
|
// console.log(markResult.scoreList, markResult.markerScore);
|
|
|
// renderPaperAndMark();
|