From d9a89d83c2048a964f16ca179feb2b7f21b9d33a Mon Sep 17 00:00:00 2001
From: jiangping <jp@doumee.com>
Date: 星期一, 29 七月 2024 16:28:47 +0800
Subject: [PATCH] 提交
---
wechat_staff/pages/homeId/index.js | 16 +++++++++++-----
1 files changed, 11 insertions(+), 5 deletions(-)
diff --git a/wechat_staff/pages/homeId/index.js b/wechat_staff/pages/homeId/index.js
index 95ecff5..0a7dded 100644
--- a/wechat_staff/pages/homeId/index.js
+++ b/wechat_staff/pages/homeId/index.js
@@ -53,22 +53,28 @@
itemClick(e) {
const item = e.currentTarget.dataset.item
console.log('item', item);
- actionDo({actionType: 'view',id: item.id})
if(item.contentType == 'video'){
wx.previewMedia({
sources: [{ url: item.content, type: 'video' }]
- })
+ })
+ actionDo({actionType: 'view',id: item.id})
}
if(item.contentType == 'link'){
wx.navigateTo({
- url: '/pages/webView/index?link=' + item.content,
- })
+ url: '/pages/webView/index',
+ success: function(res) {
+ // 閫氳繃eventChannel鍚戣鎵撳紑椤甸潰浼犻�佹暟鎹�
+ res.eventChannel.emit('data',{link:item.content} );
+ }
+ })
+ actionDo({actionType: 'view',id: item.id})
}
if(item.contentType == 'page'){
getApp().globalData.catalogCode=item.content
wx.switchTab({
url: '/pages/discover/discover'
- })
+ })
+ actionDo({actionType: 'view',id: item.id})
}
},
cateClick(e) {
--
Gitblit v1.9.3