Commit 13488bd2 authored by mengcuiguang's avatar mengcuiguang

Merge branch 'dev_helixiaogushi_weixin_240717' of...

Merge branch 'dev_helixiaogushi_weixin_240717' of http://gitlab.mints-id.com/android/uniapp_vedio into dev_helixiaogushi_weixin_240717
parents 97cd2616 88f26997
{ {
"name" : "reader", "name" : "reader",
"appid" : "__UNI__F7F50FF", "appid" : "__UNI__1EF86FE",
"description" : "", "description" : "",
"versionName" : "1.0.0", "versionName" : "1.0.0",
"versionCode" : 1000, "versionCode" : 1000,
......
...@@ -90,18 +90,28 @@ ...@@ -90,18 +90,28 @@
} }
}, },
onShow() { onShow() {
// try { try {
// // 在子组件重写show()代替onShow() // 在子组件重写show()代替onShow()
// if (this.currentPage == 0) { if (this.currentPage == 0) {
// this.$refs.index.show(); this.$refs.index.show();
// } else if (this.currentPage == 1) { } else if (this.currentPage == 1) {
// this.$refs.recommend.show(); this.$refs.recommend.show();
// } else if (this.currentPage == 2) { } else if (this.currentPage == 2) {
// this.$refs.user.show(); this.$refs.user.show();
// } }
// } catch (e) { } catch (e) {
// } }
let that = this
uni.$on('refreshPreviousPage', (data) => {
if (data.vipFlag == '1') {
// 开通vip刷新状态
if (that.currentPage == 2) {
that.$refs.user.show();
}
}
});
}, },
mounted() { mounted() {
// 渲染完成 初始化首页数据 // 渲染完成 初始化首页数据
...@@ -114,15 +124,7 @@ ...@@ -114,15 +124,7 @@
}) })
} }
uni.$on('refreshPreviousPage', (data) => {
if (data.vipFlag == '1') {
// 开通vip刷新状态
if (that.currentPage == 2) {
that.$refs.user.show();
}
}
});
}, },
methods: { methods: {
tabChange(index) { tabChange(index) {
......
...@@ -192,16 +192,7 @@ ...@@ -192,16 +192,7 @@
path: 'pages/index/index', path: 'pages/index/index',
extraData: wxData.params, extraData: wxData.params,
success(res) { success(res) {
message.notify('支付成功') uni.navigateBack()
setTimeout(() => {
uni.$emit('refreshPreviousPage', {
vipFlag: '1'
});
uni.navigateBack({
delta: 1,
});
}, 1000);
}, },
fail(res) { fail(res) {
// 未成功跳转到签约小程序 // 未成功跳转到签约小程序
...@@ -221,11 +212,11 @@ ...@@ -221,11 +212,11 @@
paySign: wxParams.paySign, paySign: wxParams.paySign,
success(res) { success(res) {
message.notify('支付成功') message.notify('支付成功')
uni.$emit('refreshPreviousPage', {
vipFlag: '1'
});
setTimeout(() => { setTimeout(() => {
uni.$emit('refreshPreviousPage', {
vipFlag: '1'
});
uni.navigateBack({ uni.navigateBack({
delta: 1, delta: 1,
}); });
......
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