Ver Fonte

fix: 点击收藏从新进来没有显示已收藏

xuqiaoying há 3 anos atrás
pai
commit
73e4917254

+ 1 - 1
src/pages/bank-exam-continue/index.vue

@@ -1202,7 +1202,7 @@ export default {
         let json = JSON.parse(res.data.historyExamJson);
         this.examData = res.data;
         this.questionList = json;
-
+        this.getCollectInfo(this.current)
         //5秒保存一下做题记录
         clearInterval(this.postTimer);
         this.postTimer = setInterval(() => {

+ 3 - 4
src/pages/bank-exam/index.vue

@@ -145,8 +145,8 @@
                           "
                         >
                           <template v-if="!collectList[questionIndex]"
-                            ><i class="el-icon-star-off"></i>收藏本题</template
-                          >
+                            ><i class="el-icon-star-off"></i>收藏本题
+                          </template>
                           <template v-if="collectList[questionIndex]"
                             ><i class="el-icon-star-on"></i>已收藏</template
                           >
@@ -1568,7 +1568,7 @@ export default {
 
           this.questionList = res.data;
           this.lastCount = this.questionList.length;
-
+          this.getCollectInfo(this.current)
           await this.examRecord();
         });
     },
@@ -2791,7 +2791,6 @@ export default {
             width: 970px;
             min-height: 630px;
             border: 1px solid #eee;
-
             &__header {
               height: 40px;
               padding-left: 12px;

+ 1 - 1
src/pages/mock-exam/index.vue

@@ -1503,7 +1503,7 @@ export default {
 
           this.questionList = res.data;
           this.lastCount = this.questionList.length;
-
+          this.getCollectInfo(this.current)
           await this.mockRecord();
         });
     },