ZhangXianQiang
2024-06-19 1a20a2c7a9e1ba9a0ffb83fb3d09ee7215d260c4
src/views/exam/components/answer-main/answer-single/index.vue
@@ -16,19 +16,21 @@
</template>
<script setup>
import { ref } from 'vue';
import { ref, onMounted } from 'vue';
import {storeToRefs} from 'pinia';
import ExamInfo from '@/components/ExamInfo/index.vue';
import {useExamStore} from '@/store/index.js';
const examStore = useExamStore();
const {currentType,currentIndex,activeQuestion,examDetail} = storeToRefs(examStore);
const {currentType,currentIndex,examDetail} = storeToRefs(examStore);
const activeQuestion = ref(examStore.getActiveQuestion);
const answerClick = (item) => {
  if(item) {
    resetAnswer();
    item.isActive = true;
    examStore.setQuestionAnswer(currentType.value, currentIndex.value, item.prefix);
  }
};
@@ -42,9 +44,6 @@
  activeQuestion.value.items.forEach(item => item.isActive = false);
}
const filterExam = () => {
}
</script>