From 8c7361e8803a4a52cb1144dec576f01085d2a297 Mon Sep 17 00:00:00 2001
From: ZhangXianQiang <1135831638@qq.com>
Date: 星期二, 18 六月 2024 09:52:36 +0800
Subject: [PATCH] fix:修改多选题问题

---
 src/views/exam/components/answer-sheet/index.vue |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/views/exam/components/answer-sheet/index.vue b/src/views/exam/components/answer-sheet/index.vue
index 12321fe..4c44045 100644
--- a/src/views/exam/components/answer-sheet/index.vue
+++ b/src/views/exam/components/answer-sheet/index.vue
@@ -5,7 +5,7 @@
         <template v-for="item in examDetail">
           <el-collapse-item :title="examType[item.questionType]" :name="item.questionType">
             <div class="sheet-list grid grid-cols-5 gap-4 justify-items-center">
-              <div class="sheet-item cursor-pointer flex justify-center items-center" v-for="question,index in item.questionList" @click="sheetClick(item.questionType,index,question)" :class="itemClass(item.questionType, index)">
+              <div class="sheet-item cursor-pointer flex justify-center items-center" v-for="question,index in item.questionList" @click="sheetClick(item.questionType,index,question)" :class="itemClass(item,item.questionType, index)">
                 {{ index + 1 }}
               </div>
             </div>
@@ -24,8 +24,9 @@
 
 const {examType, examDetail,currentType,currentIndex} = storeToRefs(examStore);
 
-const itemClass = (type,index) => {
+const itemClass = (question,type,index) => {
   return {
+    answer: question.correct,
     active: currentType.value === type && currentIndex.value === index
   }
 }

--
Gitblit v1.8.0