Browse Source

联系方式修改

谢杰标 2 years ago
parent
commit
99497fedd1
3 changed files with 75 additions and 37 deletions
  1. 32 22
      pages/learn/index.vue
  2. 42 14
      pages3/polyv/detail.vue
  3. 1 1
      pages5/mockExam/registrationSuccess.vue

+ 32 - 22
pages/learn/index.vue

@@ -194,10 +194,7 @@
                 </template>
 
                 <template v-else>
-                  <!-- 班级有效期过了 -->
-                  <template
-                    v-if="item.classEndTime && item.classEndTime < sysTime"
-                  >
+                  <template v-if="item.classEndTime && item.classEndTime < sysTime">
                     <view class="class-warm">
                       <u-icon
                         class="class-warm__icon"
@@ -224,11 +221,13 @@
                             )
                           }}</view
                         >
-                        <view class="date">班级状态:已过期 </view>
-                        <!-- <view class="date"
-                          >班级状态:已过期,有疑问请联系
-                          <text @click="call()">020-87085982</text></view
-                        > -->
+                        <view class="date"
+                          >班级状态:已过期
+                          <template v-if="eduPhone">
+                            <text>,有疑问请联系</text>
+                            <text @click="call()">{{ eduPhone }}</text>
+                          </template>
+                        </view>
                       </view>
                     </view>
                   </template>
@@ -265,11 +264,14 @@
                             )
                           }}</view
                         >
-                        <view class="date">班级状态:未到学习时间 </view>
-                        <!-- <view class="date"
-                          >班级状态:未到学习时间,有疑问请联系
-                          <text @click="call()">020-87085982</text></view
-                        > -->
+                        <view class="date"
+                          >班级状态:未到学习时间
+
+                          <template v-if="eduPhone">
+                            <text>,有疑问请联系</text>
+                            <text @click="call()">{{ eduPhone }}</text>
+                          </template>
+                        </view>
                       </view>
                     </view>
                   </template>
@@ -818,6 +820,9 @@ export default {
     allCourse() {
       return this.courseLists.length || this.livingLists.length ? true : false;
     },
+    eduPhone() {
+      return this.userInfo.eduPhone;
+    },
   },
   onLoad() {
     // 1668873600 ,2022.11.20的时间戳
@@ -1035,9 +1040,8 @@ export default {
 
       // 进入视频课
       this.activeItem = item;
-      if (item.interfaceAccountId > 0) {
+      if (!item.interfaceAccountId) {
         //学习账号已开通
-
         if (item.learnStatus > 0) {
           //跳转第三方h5
           uni.navigateTo({
@@ -1045,10 +1049,10 @@ export default {
           });
           return;
         } else {
-          // ,有疑问,请联系020-87085982
+          const text = this.eduPhone ? ",有疑问,请联系" + this.eduPhone : "";
           uni.showModal({
             showCancel: false,
-            content: "您的学习账号未开通,请稍后再尝试,有疑问!",
+            content: "您的学习账号未开通,请稍后再尝试" + text,
           });
           return;
         }
@@ -1241,11 +1245,13 @@ export default {
             if (res.data.data.pushInfo) {
               resolve(true);
             } else {
-              // ,有疑问,请联系020-87085982
+              const text = this.eduPhone
+                ? ",有疑问,请联系" + this.eduPhone
+                : "";
               uni.showModal({
                 showCancel: false,
                 title: "提示",
-                content: "开通信息推送不成功,无法进入学习",
+                content: "开通信息推送不成功,无法进入学习" + text,
               });
               resolve(false);
             }
@@ -1371,11 +1377,13 @@ export default {
                   title: "提交成功",
                 });
               } else {
-                // ,有疑问,请联系020-87085982
+                const text = this.eduPhone
+                  ? ",有疑问,请联系" + this.eduPhone
+                  : "";
                 uni.showModal({
                   showCancel: false,
                   title: "提示",
-                  content: "开通信息推送不成功,无法进入学!",
+                  content: "开通信息推送不成功,无法进入学!" + text,
                 });
               }
               this.showUserConfirmInfo = false;
@@ -1394,9 +1402,11 @@ export default {
       clearInterval(this.confirmTimer);
     },
     call() {
+      // #ifdef MP-WEIXIN
       uni.makePhoneCall({
         phoneNumber: "020-87085982", //仅为示例
       });
+      // #endif
     },
     closePop() {
       this.appointTestShow = false;

+ 42 - 14
pages3/polyv/detail.vue

@@ -653,7 +653,24 @@
         </view>
       </view>
     </u-popup>
-
+    <!-- 倒计时提交 -->
+    <u-popup
+      v-model="noticeShow1"
+      class="notice_modal"
+      mode="center"
+      border-radius="28"
+      width="650rpx"
+      height="262rpx"
+      :mask-close-able="false"
+    >
+      <view class="content">
+        <view class="title">提示</view>
+        <view class="had_read">
+          <text v-if="CountTo1 >= 0">视频学习时长不达标,请等待</text>
+          <text v-if="CountTo1 >= 0">{{ " " + CountTo1 + "s" }}</text>
+        </view>
+      </view>
+    </u-popup>
     <u-modal
       v-model="showMark"
       title="提示"
@@ -898,6 +915,7 @@ export default {
       prendreAutoCarme: false, // 是否发起授权相机
       studyTimer: null, // 学习记录定时器
       CountTo: 30, // 倒计时
+      CountTo1: 0,
       handoutTipLength: 0,
       menuAllList: [],
       popupPhotoShow: false,
@@ -913,6 +931,7 @@ export default {
       pauseTimer: null,
       barTimer: null,
       isReach: false,
+      noticeShow1: false,
     };
   },
   computed: {
@@ -1708,13 +1727,10 @@ export default {
           if (!data.sectionId) {
             data = this.menuAllList[0];
           } else {
-            // if (
-            //   data.learning == 1 &&
-            //   this.orderNum == 2
-            // ) {
-            //   let next = this.menuAllList.find((e) => e.studyStatus != 1);
-            //   next && (data = next);
-            // }
+            if (data.learning == 1 && this.orderNum == 2) {
+              let next = this.menuAllList.find((e) => e.studyStatus != 1);
+              next && (data = next);
+            }
           }
           this.initPlayVideo(data);
           // if (res.data.data) {
@@ -2928,9 +2944,9 @@ export default {
         PlayDuration = polyvPlayerContext.j2s_realPlayVideoTime(); //本次看的时长
         // #endif
       }
-      if (currentTime < 15) {
-        return;
-      }
+      // if (currentTime < 15 && !this.ossAvatarUrl) {
+      //   return;
+      // }
       if (this.playChannelId > 0) {
         currentTime = 2; //直播无法获取,无论开始结束都传2秒
       }
@@ -2965,7 +2981,7 @@ export default {
           .studyRecord(data)
           .then((res) => {
             console.log(res, "记录返回");
-            let { code } = res.data;
+            let { code, msg } = res.data;
             if (code == 200) {
               if (status > 0) {
                 this.studyRecordMenuAllList();
@@ -2984,11 +3000,23 @@ export default {
               uni.showModal({
                 showCancel: false,
                 title: "提示",
-                content: res.data.msg,
+                content: msg,
                 success: (resultst) => {
                   uni.navigateBack();
                 },
               });
+            } else if (code == 558) {          
+              this.CountTo1 = msg.split(",")[1]
+              this.noticeShow1 = true;
+              var timer = setInterval(() => {
+                this.CountTo1--;
+                if (this.CountTo1 < 0) {
+                  this.noticeShow1 = false;
+                  clearInterval(timer);
+                  this.postStudyRecord(1)
+                }
+              }, 1000);
+              reject("中断执行");
             } else {
               this.uploadLock = false;
               uni.showToast({
@@ -3000,7 +3028,7 @@ export default {
                 this.isReach = true;
                 this.openPhoto();
               }
-              if (code == 559 || code == 588 || code == 558) {
+              if (code == 559 || code == 588) {
                 reject("中断执行");
               }
             }

+ 1 - 1
pages5/mockExam/registrationSuccess.vue

@@ -26,7 +26,7 @@
                 </view>
             </view>
             <view class="time_down">
-                <view class="look_mock" @click="toLookMock()">立即查看模考</view>
+                <view class="look_mock" @click="toLookMock()">立即进入模考</view>
             </view>
         </view>
         <view class="mains">