谢杰标 3 years ago
parent
commit
440e5f065e

+ 8 - 5
src/pages/course-detail/index copy.vue

@@ -2700,7 +2700,7 @@ export default {
       // if (liveMenu && liveMenu.length) {
       //   earlyTime = liveMenu[0].liveStartTime;
       // }
-  
+
       await this.courseCourseList();
       if (this.sectionItem.recordingUrl) {
         let noteSecond = this.$route.query.noteSecond;
@@ -4373,14 +4373,17 @@ export default {
         "课程学习需要开启摄像头进行拍照,经检测您的设备无摄像头可使用,请检测环境是否支持。",
         "提示",
         {
-          showConfirmButton: false,
+          confirmButtonText: "返回",
+          showConfirmButton: true,
           closeOnClickModal: false,
           showCancelButton: false,
           closeOnPressEscape: false,
           distinguishCancelAndClose: false,
           showClose: false,
         }
-      );
+      ).then(() => {
+        this.$router.go(-1);
+      });
     },
     /**
      * 切换科目
@@ -5647,7 +5650,7 @@ export default {
       console.log(this);
       console.log(PlayDuration, "PlayDuration");
       let data = {
-        fromPlat: 2, //来源平台 1小程序 2网站	
+        fromPlat: 2, //来源平台 1小程序 2网站
         photo: self.ossAvatarUrl,
         sectionId: parseInt(this.playSectionId),
         goodsId: parseInt(this.goodsId),
@@ -7285,7 +7288,7 @@ export default {
           right: 0;
           bottom: 0;
           margin: 30px auto 0;
-          box-shadow: 0 0 0 2000px rgba(0,0,0,0.4);
+          box-shadow: 0 0 0 2000px rgba(0, 0, 0, 0.4);
         }
       }
     }

+ 5 - 2
src/pages/course-detail/index.vue

@@ -4955,14 +4955,17 @@ export default {
         "课程学习需要开启摄像头进行拍照,经检测您的设备无摄像头可使用,请检测环境是否支持。",
         "提示",
         {
-          showConfirmButton: false,
+          confirmButtonText: "返回",
+          showConfirmButton: true,
           closeOnClickModal: false,
           showCancelButton: false,
           closeOnPressEscape: false,
           distinguishCancelAndClose: false,
           showClose: false,
         }
-      );
+      ).then(() => {
+        this.$router.go(-1);
+      });
     },
     /**
      * 切换科目

+ 31 - 26
src/pages/course-exam/index.vue

@@ -1083,7 +1083,7 @@
                 <div class="right-box__header">
                   <div class="title">答题卡</div>
                   <div class="time" v-if="allTimes">
-                    剩余时间 {{ lastTime }}
+                    剩余时间 {{ countdown(lastTime) }}
                   </div>
                 </div>
                 <div class="right-box__body">
@@ -1342,19 +1342,20 @@ export default {
      * @param {Object} current
      * 获取收藏信息
      */
-     getCollectInfo(current) {
-      this.$request.getCollectInfo({
-        examId: this.examId,
-        questionId: this.questionList[current].questionId,
-        goodsId: this.goodsId,
-        orderGoodsId: this.orderGoodsId,
-      })
-      .then((res) => {
-        this.$set(this.collectList, current, res.data);
-      })
-      .catch((err) => {
-        this.$set(this.collectList, current, false);
-      });
+    getCollectInfo(current) {
+      this.$request
+        .getCollectInfo({
+          examId: this.examId,
+          questionId: this.questionList[current].questionId,
+          goodsId: this.goodsId,
+          orderGoodsId: this.orderGoodsId,
+        })
+        .then((res) => {
+          this.$set(this.collectList, current, res.data);
+        })
+        .catch((err) => {
+          this.$set(this.collectList, current, false);
+        });
     },
     /**
      * 请求题目列表
@@ -1498,7 +1499,7 @@ export default {
 
           this.questionList = res.data;
           this.lastCount = this.questionList.length;
-          this.getCollectInfo(this.current)
+          this.getCollectInfo(this.current);
           await this.examRecord();
         });
     },
@@ -1750,14 +1751,17 @@ export default {
         "课程学习需要开启摄像头进行拍照,经检测您的设备无摄像头可使用,请检测环境是否支持。",
         "提示",
         {
-          showConfirmButton: false,
+          confirmButtonText: "返回",
+          showConfirmButton: true,
           closeOnClickModal: false,
           showCancelButton: false,
           closeOnPressEscape: false,
           distinguishCancelAndClose: false,
           showClose: false,
         }
-      );
+      ).then(() => {
+        this.$router.go(-1);
+      });
     },
 
     /**
@@ -2085,7 +2089,7 @@ export default {
 
     changeIndex(index) {
       this.current = index;
-      this.getCollectInfo(this.current)
+      this.getCollectInfo(this.current);
     },
     nextQuestion() {
       if (this.current >= this.questionList.length - 1) {
@@ -2096,7 +2100,7 @@ export default {
         return;
       }
       this.current++;
-      this.getCollectInfo(this.current)
+      this.getCollectInfo(this.current);
     },
     prevQuestion() {
       if (this.current == 0) {
@@ -2107,7 +2111,7 @@ export default {
         return;
       } else {
         this.current--;
-        this.getCollectInfo(this.current)
+        this.getCollectInfo(this.current);
       }
     },
     isCheck(item, index) {
@@ -2521,7 +2525,7 @@ export default {
           gradeId: this.gradeId,
           courseId: this.courseId,
           orderGoodsId: this.orderGoodsId,
-          type: this.type, //题卷类型 1章卷 2节卷 3模块卷	
+          type: this.type, //题卷类型 1章卷 2节卷 3模块卷
           examId: this.examId,
           goodsId: this.goodsId,
           reportStatus: reportStatus,
@@ -2530,13 +2534,13 @@ export default {
           lessQuestionNum: lessQuestionNum,
           status: 1,
           doQuestionIds: doQuestionIds.join(","),
-          rightQuestionIds:rightQuestionIds.join(','),
+          rightQuestionIds: rightQuestionIds.join(","),
           doQuestionNum: doQuestionNum,
           performance: score,
           totalScore: allScore,
           examTime: parseInt(this.allTimes),
           doTime: parseInt(this.allTimes) - parseInt(this.lastTime),
-          historyExamJson: JSON.stringify(this.questionList)
+          historyExamJson: JSON.stringify(this.questionList),
         })
         .then((res) => {
           this.isSubmit = true;
@@ -2574,8 +2578,9 @@ export default {
           console.log(err, "err");
         });
 
-        //错题集id提交(客观题)/exam/wwrong/record
-      this.$request.examWrongRecord({
+      //错题集id提交(客观题)/exam/wwrong/record
+      this.$request
+        .examWrongRecord({
           moduleId: this.moduleId || 0,
           chapterId: this.chapterId || 0,
           sectionId: this.sectionId || 0,
@@ -3172,7 +3177,7 @@ export default {
           right: 0;
           bottom: 0;
           margin: 30px auto 0;
-          box-shadow: 0 0 0 2000px rgba(0,0,0,0.4);
+          box-shadow: 0 0 0 2000px rgba(0, 0, 0, 0.4);
         }
       }
     }

+ 5 - 2
src/pages/live-detail/index.vue

@@ -4459,14 +4459,17 @@ export default {
         "课程学习需要开启摄像头进行拍照,经检测您的设备无摄像头可使用,请检测环境是否支持。",
         "提示",
         {
-          showConfirmButton: false,
+          confirmButtonText: "返回",
+          showConfirmButton: true,
           closeOnClickModal: false,
           showCancelButton: false,
           closeOnPressEscape: false,
           distinguishCancelAndClose: false,
           showClose: false,
         }
-      );
+      ).then(() => {
+        this.$router.go(-1);
+      });
     },
     /**
      * 切换科目