|
@@ -61,10 +61,11 @@
|
|
|
const that = this;
|
|
|
that.$set(that, `id`, e.id || '634fa595e4ed552882f05a6f');
|
|
|
},
|
|
|
- onShow: function() {
|
|
|
+ onShow: async function() {
|
|
|
const that = this;
|
|
|
that.searchConfig();
|
|
|
- that.searchAct();
|
|
|
+ await that.searchAct();
|
|
|
+ await that.configShare();
|
|
|
},
|
|
|
methods: {
|
|
|
// 查询基本设置
|
|
@@ -86,7 +87,7 @@
|
|
|
let res = await that.$api(`/platformAct/${that.id}`, 'GET');
|
|
|
if (res.errcode == '0') {
|
|
|
uni.setNavigationBarTitle({
|
|
|
- title: res.data.title
|
|
|
+ title: res.data.act_time.title
|
|
|
});
|
|
|
that.$set(that, `info`, res.data);
|
|
|
that.search()
|
|
@@ -149,6 +150,18 @@
|
|
|
that.$set(that, `skip`, 0)
|
|
|
that.$set(that, `limit`, 6)
|
|
|
that.$set(that, `page`, 0)
|
|
|
+ },
|
|
|
+ // 配置分享内容
|
|
|
+ configShare() {
|
|
|
+ const that = this;
|
|
|
+ let info = that.info;
|
|
|
+ let imageUrl = that.config.config.logo[0].url;
|
|
|
+ if (info.share.length > 0) imageUrl = info.share[0].url;
|
|
|
+ that.$config.share = {
|
|
|
+ title: info.act_time.title,
|
|
|
+ path: `/pagesRest/activity/info?id=${that.id}`,
|
|
|
+ imageUrl: imageUrl
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
}
|