From aff8d054df4a638f399dc8f15d98c19b9c9aa785 Mon Sep 17 00:00:00 2001
From: litian <C21AF165>
Date: 星期二, 29 四月 2025 10:11:25 +0800
Subject: [PATCH] 扫码视频播放

---
 packageDomain/pages/teacherCertification/index.js |   42 +++++++++++++++++++++++++++++-------------
 1 files changed, 29 insertions(+), 13 deletions(-)

diff --git a/packageDomain/pages/teacherCertification/index.js b/packageDomain/pages/teacherCertification/index.js
index 1285add..df343fc 100644
--- a/packageDomain/pages/teacherCertification/index.js
+++ b/packageDomain/pages/teacherCertification/index.js
@@ -57,17 +57,7 @@
     //鑾峰彇鑱岀О
     this.getpositionalTitle();
     this.getAgreement();
-    // 妫�鏌ョ櫥褰曠姸鎬�
-    const token = wx.getStorageSync(app.config.tokenKey)
-    if (!token) {
-      loginInfo(app, (data) => {
-        if (data) {
-          this.getUserRole()
-        }
-      })
-    } else {
-      this.getUserRole()
-    }
+
   },
 
   /**
@@ -81,6 +71,21 @@
    * 鐢熷懡鍛ㄦ湡鍑芥暟--鐩戝惉椤甸潰鏄剧ず
    */
   onShow() {
+    // 妫�鏌ョ櫥褰曠姸鎬�
+    const token = wx.getStorageSync(app.config.tokenKey)
+    if (!token) {
+      loginInfo(app, (data) => {
+        if (data) {
+          this.getUserRole()
+        } else {
+          wx.switchTab({
+            url: '/pages/home/home',
+          })
+        }
+      })
+    } else {
+      this.getUserRole()
+    }
 
   },
 
@@ -142,8 +147,9 @@
       })
       this.newGetTeacherInfo()
     })
-
   },
+
+
   //鑾峰彇鏁欏笀鐘舵��
   newGetTeacherInfo() {
     let that = this;
@@ -574,6 +580,14 @@
       })
       return
     }
+    if (!that.data.teacherInfo.detailedAddress) {
+      wx.showToast({
+        title: "璇峰~鍐欒缁嗗湴鍧�锛�",
+        icon: 'none',
+        duration: 1000,
+      })
+      return
+    }
     if (that.data.imgPics.length == 0) {
       wx.showToast({
         title: "璇蜂笂浼犲伐浣滆瘉锛�",
@@ -689,7 +703,6 @@
     if (!this.data.isIos === 'ios') {
       return
     }
-
     // 閿洏楂樺害
     const height = e.detail.height;
     const className = e.target.dataset.class;
@@ -750,6 +763,9 @@
       } catch (error) {}
     }
   },
+  changeParam(e) {
+    this.scrollToInput(0);
+  },
   /**
    * 椤甸潰涓婃媺瑙﹀簳浜嬩欢鐨勫鐞嗗嚱鏁�
    */

--
Gitblit v1.9.1