diff --git a/web/src/pages/mockExamination/paper/index.tsx b/web/src/pages/mockExamination/paper/index.tsx index 9417d67..f109d14 100644 --- a/web/src/pages/mockExamination/paper/index.tsx +++ b/web/src/pages/mockExamination/paper/index.tsx @@ -340,8 +340,8 @@ const CardList = () => { let score = 0 // 当前分类下试题总数 - if (JSON.stringify(rulesPaperInfo) !== "{}") { - rulesPaperInfo.question_type_count.map((e, i) => { + if (JSON.stringify(rulesPaperInfo) !== "{}" && rulesPaperInfo.length > 0) { + rulesPaperInf?.question_type_count.map((e, i) => { if (e.question_type === questionType) { num = e.count questionName = e.type_name @@ -444,7 +444,6 @@ const CardList = () => { {questionNow.id ? questionNow.index[0] + 1 : ""} 、{questionNow?.question_stem} - {/* {console.log(questionNow.answerId, 'answerId', questionNow.answerId)} */}