From bbba5d26e9e26c910ed337dcb65f462752ee6dce Mon Sep 17 00:00:00 2001
From: litian <C21AF165>
Date: 星期四, 12 九月 2024 09:11:47 +0800
Subject: [PATCH] fenxiang

---
 pages/home/home.js |   58 +++++++++++++++++++++++++++++++++++-----------------------
 1 files changed, 35 insertions(+), 23 deletions(-)

diff --git a/pages/home/home.js b/pages/home/home.js
index cfeb887..9bfbbab 100644
--- a/pages/home/home.js
+++ b/pages/home/home.js
@@ -446,11 +446,11 @@
     });
   },
   goSubjectDetail(e) {
-    return wx.showToast({
-      title: "寤鸿涓�",
-      icon: 'none',
-      duration: 1000
-    })
+    // return wx.showToast({
+    //   title: "寤鸿涓�",
+    //   icon: 'none',
+    //   duration: 1000
+    // })
     const item = e.currentTarget.dataset.book
     console.log(item);
     wx.navigateTo({
@@ -458,16 +458,18 @@
     });
   },
   goCourseDetail(e) {
-    return wx.showToast({
-      title: "寤鸿涓�",
-      icon: 'none',
-      duration: 1000
-    })
+    // return wx.showToast({
+    //   title: "寤鸿涓�",
+    //   icon: 'none',
+    //   duration: 1000
+    // })
+
     const {
       book
     } = e.currentTarget.dataset;
+    console.log(book);
     wx.navigateTo({
-      url: '/pages/digitalCourses/digitalCoursesDetails/index?id=' + book.id,
+      url: '/pages/digitalCourses/digitalCoursesDetails/index?id=' + book.id + '&path=' + book.idPath,
     });
   },
   goReadBookDetail(e) {
@@ -587,21 +589,21 @@
         url: '/pages/home/digitalRead/index'
       })
     } else if (type == "zhuantitaolun") {
-      return wx.showToast({
-        title: "寤鸿涓�",
-        icon: 'none',
-        duration: 1000
-      })
+      // return wx.showToast({
+      //   title: "寤鸿涓�",
+      //   icon: 'none',
+      //   duration: 1000
+      // })
       wx.navigateTo({
         url: '/pages/specialDiscussion/index'
       })
 
     } else if (type == "jingxuankecheng") {
-      return wx.showToast({
-        title: "寤鸿涓�",
-        icon: 'none',
-        duration: 1000
-      })
+      // return wx.showToast({
+      //   title: "寤鸿涓�",
+      //   icon: 'none',
+      //   duration: 1000
+      // })
       wx.navigateTo({
         url: '/pages/digitalCourses/index?courseTypeActive=' + this.data.courseTypeActive
       })
@@ -641,12 +643,16 @@
     if (this.data.scoll) {
       if (e.detail.scrollTop < 20) {
         this.data.scoll = false
-        this.isChange(false);
+        // 閬垮厤棰戠箒璋冪敤 setData
+        if (this.data.isWhite)
+          this.isChange(false);
       }
     } else {
       if (e.detail.scrollTop > 20) {
         this.data.scoll = true
-        this.isChange(true);
+        // 閬垮厤棰戠箒璋冪敤 setData
+        if (!this.data.isWhite)
+          this.isChange(true);
       }
     }
   },
@@ -680,4 +686,10 @@
 
 
   },
+
+  /**
+   * 鐢ㄦ埛鐐瑰嚮鍙充笂瑙掑垎浜�
+   */
+  onShareAppMessage() {},
+  onShareTimeline() {}
 });
\ No newline at end of file

--
Gitblit v1.9.1