Browse Source

修复问题

lex 1 year ago
parent
commit
d565e2fe10

+ 4 - 5
src/views/knowledge-library/error-question-mode/index.tsx

@@ -41,7 +41,7 @@ export default defineComponent({
       currentIndex: 0,
       questionList: [] as any,
       page: 1,
-      rows: 10,
+      rows: 50,
       total: 0,
       isFinish: false, // 是否完成加载
       visiableInfo: {
@@ -152,16 +152,15 @@ export default defineComponent({
         state.visiableInfo.graspItem.grasp = true;
 
         eventUnit.emit('unitAudioStop');
-
         // 只有一道题
-        if (state.questionList.length === 1) {
+        if (state.total === 1) {
           router.back();
           router.back();
           return;
         }
 
         // 后面还有题
-        if (state.questionList.length > state.currentIndex + 1) {
+        if (state.total > state.currentIndex + 1) {
           const index = state.questionList.findIndex(
             (item: any) =>
               item.studentExaminationErrorEditionId ===
@@ -175,7 +174,7 @@ export default defineComponent({
         }
 
         // 后面没有题
-        if (state.questionList.length === state.currentIndex + 1) {
+        if (state.total === state.currentIndex + 1) {
           const index = state.questionList.findIndex(
             (item: any) =>
               item.studentExaminationErrorEditionId ===

+ 1 - 1
src/views/knowledge-library/model/answer-list/index.tsx

@@ -38,7 +38,7 @@ export default defineComponent({
     /** 是否加载完 */
     isFinish: {
       type: Boolean,
-      default: false
+      default: true
     }
   },
   emits: ['select', 'loadMore'],