From 7974f3266c323e4cd4fdff7d457fe75f39b8c199 Mon Sep 17 00:00:00 2001
From: 闫增涛 <1829501689@qq.com>
Date: 星期三, 25 九月 2024 15:59:06 +0800
Subject: [PATCH] 云学习跳转逻辑修改

---
 pages/digitalCourses/digitalCoursesDetails/index.js |    9 ++++++---
 1 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/pages/digitalCourses/digitalCoursesDetails/index.js b/pages/digitalCourses/digitalCoursesDetails/index.js
index aaa522c..05c9f2d 100644
--- a/pages/digitalCourses/digitalCoursesDetails/index.js
+++ b/pages/digitalCourses/digitalCoursesDetails/index.js
@@ -179,6 +179,9 @@
     this.digitalCoursesDetailsGet(options.id)
     this.getPlayerList()
     this.getType()
+    this.setData({
+      userName: JSON.parse(wx.getStorageSync(app.config.userInfoKey)).name,
+    })
   },
 
   /**
@@ -192,11 +195,11 @@
    * 鐢熷懡鍛ㄦ湡鍑芥暟--鐩戝惉椤甸潰鏄剧ず
    */
   onShow() {
-    if (this.data.tabValue == 2) {
+    if (this.data.tabValue == 2 && this.data.selectActive == 'learn') {
       this.getPlayerList()
       this.getResource()
+      this.getRelationBook()
     }
-
   },
 
   /**
@@ -240,6 +243,7 @@
         keys: [this.data.bookId + '']
       })
       .then((res) => {
+        console.log(1, res);
         if (res.length > 0) {
           this.setData({
             playerList: JSON.parse(res[0].value)
@@ -545,7 +549,6 @@
               learnList: list,
               openTeachids: result,
             });
-            console.log(1, this.data.learnList, this.data.playerList)
           }
         } else {
           const data = test.filter(

--
Gitblit v1.9.1