Commit 9462e83a by 高淑倩

跳转this

parent af470e8f
......@@ -89,7 +89,7 @@ Component({
this.triggerEvent('getAuth', res);
},
handelToPage(event) {
utilLink.currentLinkRouter(event)
utilLink.currentLinkRouter(event, this)
}
}
})
......@@ -126,7 +126,7 @@ Component({
})
},
preview(event) {
utilLink.currentLinkRouter(event)
utilLink.currentLinkRouter(event, this)
}
}
})
......@@ -96,7 +96,7 @@ Component({
})
},
preview(event) {
utilLink.currentLinkRouter(event)
utilLink.currentLinkRouter(event, this)
},
activeTocard(e) {
if (e.detail) {
......
const wxService = require('./wxService')
const app = getApp()
function currentLinkRouter(event) {
function currentLinkRouter(event, _this) {
const ev = event.currentTarget.dataset;
let curItemType = ev.item
const userInfo = wx.getStorageSync('_baseUserInfo')
......@@ -12,11 +12,10 @@ function currentLinkRouter(event) {
if (curItemType.link.type == 1) {
// 触发父组件更新页面 外部小程序
} else if (curItemType.link.type == 2) {
// 触发父组件更新页面
wxService.nextTick(() => {
this.triggerEvent('updatePage', { pageId: currentClickType.url })
_this.triggerEvent('updatePage', { pageId: currentClickType.url })
})
} else if (curItemType.link.type == 3) {
// 预览
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment