优化:极大部分页面添加支持分享给好友和分享朋友圈功能

This commit is contained in:
wuhui_zzw 2023-11-21 18:06:30 +08:00
parent 0d39f486e9
commit 786267f036
74 changed files with 2481 additions and 281 deletions

View File

@ -50,6 +50,7 @@
import authorize from '@/components/Authorize';
// #ifndef H5
import passwordPopup from '@/components/passwordPopup';
import spread from "../../../libs/spread";
// #endif
export default {
components: {
@ -88,22 +89,31 @@
withShareTicket: true,
menus: ['shareAppMessage', 'shareTimeline']
})
return {
title: '助力活动',
path: 'pages/activity/assist/index',
}
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '助力活动',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
onShareTimeline: function() {
return {
title: '助力活动',
query: {
key: ''
},
imageUrl: ''
}
let shareData = {
title: '助力活动',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
computed: configMap({statusBarHeight:0},mapGetters(['isLogin','viewColor','keyColor'])),
computed: configMap({statusBarHeight:0},mapGetters(['isLogin','uid','viewColor','keyColor'])),
watch:{
isLogin:{
handler:function(newV,oldV){
@ -115,11 +125,14 @@
deep:true
}
},
onLoad() {
onLoad(options) {
this.getAssistProductList();
if (this.isLogin) {
this.getUserInfo();
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
goBack: function() {

View File

@ -743,6 +743,18 @@
that.addShareAssist();
return share;
},
onShareTimeline: function() {
let that = this;
let shareData = {
title: '您的好友' + that.userInfo.nickname + '邀请您帮他助力' + that.bargainInfo.product.store_name + ' 快去帮忙吧!',
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
shareData.query.id = this.id;
return shareData
},
//#endif
}
</script>

View File

@ -84,8 +84,9 @@
import { mapGetters } from "vuex";
import easyLoadimage from '@/components/easy-loadimage/easy-loadimage.vue';
import { HTTP_REQUEST_URL } from '@/config/app';
import spread from "../../../libs/spread";
export default {
computed: mapGetters(['viewColor']),
computed: mapGetters(['isLogin','uid','viewColor']),
components: {
easyLoadimage
},
@ -100,8 +101,11 @@
limit: 15,
}
},
onLoad: function() {
onLoad: function(options) {
this.statusClick(-1)
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
parsePrice(price){
@ -160,7 +164,35 @@
},
onReachBottom: function() {
this.getList();
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '领劵中心',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '领劵中心',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -75,6 +75,7 @@
import passwordPopup from '@/components/passwordPopup';
// #endif
import { mapGetters } from "vuex";
import spread from "../../../libs/spread";
let app = getApp();
export default {
components: {
@ -85,7 +86,7 @@
tabNav,
userNameSwiper
},
computed: configMap({statusBarHeight:0},mapGetters(['viewColor','keyColor'])),
computed: configMap({statusBarHeight:0},mapGetters(['isLogin','uid','viewColor','keyColor'])),
data() {
return {
domain: HTTP_REQUEST_URL,
@ -123,22 +124,30 @@
withShareTicket: true,
menus: ['shareAppMessage', 'shareTimeline']
})
return {
title: '拼团',
path: 'pages/activity/combination/index',
}
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '拼团活动',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
onShareTimeline: function() {
return {
title: '拼团活动',
query: {
key: ''
},
imageUrl: ''
}
let shareData = {
title: '拼团活动',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
onLoad() {
onLoad(options) {
var pages = getCurrentPages();
uni.setNavigationBarTitle({
title: "拼团列表"
@ -147,6 +156,9 @@
this.getCombinationProductList('');
this.getIndexConfig();
this.getCombinationUser();
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
goBack: function() {

View File

@ -79,6 +79,7 @@
import { mapGetters } from "vuex";
import { configMap } from "@/utils";
import { HTTP_REQUEST_URL } from '@/config/app';
import spread from "../../../libs/spread";
export default {
components: {
// #ifndef H5
@ -86,7 +87,7 @@
// #endif
home
},
computed: configMap({statusBarHeight:0},mapGetters(['viewColor','keyColor'])),
computed: configMap({statusBarHeight:0},mapGetters(['isLogin','uid','viewColor','keyColor'])),
data() {
return {
domain: HTTP_REQUEST_URL,
@ -115,23 +116,34 @@
withShareTicket: true,
menus: ['shareAppMessage', 'shareTimeline']
})
return {
title: '秒杀活动',
path: 'pages/activity/goods_seckill/index',
}
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '秒杀活动',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
onShareTimeline: function() {
return {
title: '秒杀活动',
query: {
key: ''
},
imageUrl: ''
}
let shareData = {
title: '秒杀活动',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
onLoad() {
onLoad(options) {
this.getSeckillConfig();
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
goBack: function() {

View File

@ -93,6 +93,7 @@
import { mapGetters } from "vuex";
import { goShopDetail } from '@/libs/order.js'
import { HTTP_REQUEST_URL } from '@/config/app';
import spread from "../../../libs/spread";
const app = getApp();
export default {
data() {
@ -174,7 +175,7 @@
}
})
},
...mapGetters(['viewColor']),
...mapGetters(['isLogin','uid','viewColor']),
},
onLoad: function(options) {
this.mer_id = options.mer_id;
@ -192,6 +193,9 @@
}
}
});
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
//
@ -356,7 +360,38 @@
this.sotreParam.page += 1
this.getServiceList()
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '本地服务',
path: page.$page.fullPath || '/' + page.route,
};
shareData.path = shareData.path + '?mer_id=' + this.mer_id;
//
if (this.isLogin) shareData.path = shareData.path + '&spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '本地服务',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
shareData.query.mer_id = this.mer_id;
return shareData
},
// #endif
}
</script>
<style lang="scss" scoped>

View File

@ -59,6 +59,7 @@
} from '../../../api/store.js';
import home from '@/components/home/index.vue'
import { HTTP_REQUEST_URL } from '@/config/app';
import spread from "../../../libs/spread";
export default {
components: {
home
@ -82,6 +83,7 @@
domain: HTTP_REQUEST_URL,
}
},
computed: mapGetters(['isLogin','uid']),
/**
* 用户点击右上角分享
*/
@ -90,24 +92,34 @@
wx.showShareMenu({
withShareTicket: true,
menus: ['shareAppMessage', 'shareTimeline']
})
return {
title: '直播',
path: 'pages/activity/liveBroadcast/index',
}
})
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '直播列表',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
onShareTimeline: function() {
return {
title: '直播',
query: {
key: ''
},
imageUrl: ''
}
let shareData = {
title: '直播列表',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
onLoad() {
onLoad(options) {
this.getBroadcastList();
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
getBroadcastList() {

View File

@ -81,8 +81,9 @@
import { configMap } from "@/utils";
import { mapGetters } from "vuex";
import { HTTP_REQUEST_URL } from '@/config/app';
import spread from "../../../libs/spread";
export default {
computed: configMap({statusBarHeight:0},mapGetters(['viewColor','keyColor'])),
computed: configMap({statusBarHeight:0},mapGetters(['isLogin','uid','viewColor','keyColor'])),
components: {
// #ifndef H5
passwordPopup,
@ -119,24 +120,34 @@
wx.showShareMenu({
withShareTicket: true,
menus: ['shareAppMessage', 'shareTimeline']
})
return {
title: '预售活动',
path: 'pages/activity/presell/index',
}
})
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '预售活动',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
onShareTimeline: function() {
return {
title: '预售活动',
query: {
key: ''
},
imageUrl: ''
}
let shareData = {
title: '预售活动',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
onLoad() {
onLoad(options) {
this.getPresellProductList();
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
goBack: function() {

View File

@ -46,6 +46,8 @@
import { spuTop,spuTopList } from '@/api/activity.js';
import { HTTP_REQUEST_URL } from '@/config/app';
import spread from "../../../libs/spread";
import { mapGetters } from "vuex";
export default {
data() {
return {
@ -61,8 +63,11 @@
domain: HTTP_REQUEST_URL,
}
},
computed: mapGetters(['isLogin','uid']),
onLoad(option) {
this.spuTop(option.cate_id || 0)
//
if(option.spread) spread(option.spread, this.isLogin)
},
methods: {
spuTop(cate_id) {
@ -104,7 +109,34 @@
}
}
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '热卖排行',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '热卖排行',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -36,6 +36,7 @@
import { HTTP_REQUEST_URL } from '@/config/app';
// #ifndef H5
import passwordPopup from '@/components/passwordPopup';
import spread from "../../../libs/spread";
// #endif
export default {
components: {
@ -45,7 +46,7 @@
home,
emptyPage
},
computed: mapGetters(['viewColor']),
computed: mapGetters(['isLogin','uid','viewColor']),
data() {
return {
domain: HTTP_REQUEST_URL,
@ -58,8 +59,11 @@
}
},
onLoad() {
onLoad(options) {
this.getTopicList();
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
getTopicList: function() {
@ -89,7 +93,34 @@
*/
onReachBottom: function() {
this.getTopicList();
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '活动专场',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '活动专场',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -70,6 +70,7 @@
// #endif
import easyLoadimage from '@/components/easy-loadimage/easy-loadimage.vue';
import authorize from '@/components/Authorize';
import spread from "../../../libs/spread";
const app = getApp();
export default {
computed: mapGetters(['isLogin','uid','viewColor']),
@ -108,6 +109,9 @@
onLoad(options) {
this.group_id = options.id
this.getTopicDetail();
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
/**
@ -211,7 +215,39 @@
onPageScroll(e) {
// scrollTopeasy-loadimage
uni.$emit('scroll');
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '主题活动',
path: page.$page.fullPath || '/' + page.route,
};
shareData.path = shareData.path + '?id=' + this.group_id;
//
if (this.isLogin) shareData.path = shareData.path + '&spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '主题活动',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
shareData.query.id = this.group_id;
return shareData
},
// #endif
}
</script>

View File

@ -133,6 +133,7 @@
import { openPaySubscribe } from '@/utils/SubscribeMessage.js';
import dayjs from '@/plugin/dayjs/dayjs.min.js';
import { HTTP_REQUEST_URL } from '@/config/app';
import spread from "../../../libs/spread";
export default {
components: {
payment,
@ -214,8 +215,8 @@
watch: {
},
computed: mapGetters(['isLogin']),
onLoad() {
computed: mapGetters(['isLogin','uid']),
onLoad(options) {
this.getCouponLst();
if (this.isLogin) {
this.getMemberCard();
@ -225,6 +226,9 @@
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
onShow(){
@ -617,7 +621,34 @@
onPageScroll(e) {
// scrollTopeasy-loadimage
uni.$emit('scroll');
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '会员中心',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '会员中心',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>
<style lang="scss" scoped>

View File

@ -55,6 +55,8 @@
import home from '@/components/home/index.vue'
import { getlevelInfo, getRandCode } from '@/api/user.js';
import { storeListApi } from "@/api/store";
import spread from "../../../libs/spread";
import { mapGetters } from "vuex";
export default {
components: {
home
@ -86,13 +88,17 @@
storeList: []
};
},
onLoad() {
computed: mapGetters(['isLogin','uid']),
onLoad(options) {
this.levelInfo();
this.getCode();
try {
this.user_latitude = uni.getStorageSync('user_latitude');
this.user_longitude = uni.getStorageSync('user_longitude');
} catch (e) {}
//
if(options.spread) spread(options.spread, this.isLogin)
},
onReady() {},
onShow() {
@ -191,7 +197,35 @@
},
},
onReachBottom() {
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '会员卡',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '会员卡',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -86,6 +86,7 @@
openPaySubscribe
} from '@/utils/SubscribeMessage.js';
import dayjs from '@/plugin/dayjs/dayjs.min.js';
import spread from "../../../libs/spread";
export default {
components: {
payment,
@ -162,8 +163,8 @@
}
},
watch: {},
computed: mapGetters(['isLogin']),
onLoad() {
computed: mapGetters(['isLogin','uid']),
onLoad(options) {
if (this.isLogin) {
this.memberEquity();
this.getMemberCard();
@ -172,6 +173,9 @@
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
onShow(){
uni.removeStorageSync('form_type_cart');
@ -561,7 +565,35 @@
onPageScroll(e) {
// scrollTopeasy-loadimage
uni.$emit('scroll');
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '开通会员',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '开通会员',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -128,6 +128,7 @@
import {
goShopDetail
} from '@/libs/order.js'
import spread from "../../../libs/spread";
const app = getApp();
export default {
computed: configMap({hide_mer_status: 1,recommend_switch:0},mapGetters(['uid','isLogin','scrollTop','viewColor','keyColor'])),
@ -220,6 +221,9 @@
this.$set(this.where, 'keyword', options.searchValue || '');
this.get_product_list(true);
this.get_host_product();
//
if(options.spread) spread(options.spread, this.isLogin)
},
onReady(){},
mounted: function() {
@ -429,9 +433,6 @@
that.loadTitle = '加载更多';
});
},
},
onPullDownRefresh() {
},
onReachBottom() {
if (this.productList.length > 0) {
@ -447,7 +448,34 @@
this.productList = newList;
uni.stopPullDownRefresh();
},500)
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '优惠券商品',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '优惠券商品',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>
<style lang="scss" scoped>

View File

@ -125,6 +125,7 @@
goShopDetail
} from '@/libs/order.js'
import { HTTP_REQUEST_URL } from '@/config/app';
import spread from "../../../libs/spread";
const app = getApp();
export default {
computed: configMap({hide_mer_status: 1,recommend_switch: 0}, mapGetters(['uid','isLogin','scrollTop','viewColor','keyColor'])),
@ -226,6 +227,9 @@
this.$set(this.where, 'keyword', options.searchValue || '');
this.get_product_list(true);
this.get_host_product();
//
if(options.spread) spread(options.spread, this.isLogin)
},
onReady(){
@ -468,9 +472,6 @@
that.loadTitle = '加载更多';
});
},
},
onPullDownRefresh() {
},
onReachBottom() {
if(this.tabIndex == 1){
@ -490,7 +491,36 @@
this.productList = newList;
uni.stopPullDownRefresh();
},500)
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '商品列表',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '商品列表',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>
<style lang="scss" scoped>

View File

@ -58,6 +58,7 @@
import passwordPopup from '@/components/passwordPopup';
// #endif
import authorize from '@/components/Authorize';
import spread from "../../../libs/spread";
export default {
computed: mapGetters(['isLogin', 'uid']),
components: {
@ -93,6 +94,9 @@
},
onLoad(options) {
this.searchValue = options.searchVal || ''
//
if(options.spread) spread(options.spread, this.isLogin)
},
onShow: function() {
try {
@ -222,7 +226,34 @@
}
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '搜索商品',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '搜索商品',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -230,6 +230,7 @@
import {
getconfig,
} from '@/api/public.js';
import spread from "../../../libs/spread";
const app = getApp();
export default {
components: {
@ -364,6 +365,9 @@
this.get_host_product();
this.getClassfication();
this.getStoreType();
//
if(options.spread) spread(options.spread, this.isLogin)
},
onReady() {
},
@ -790,9 +794,6 @@
})
}
}
},
onPullDownRefresh() {
},
onReachBottom() {
if (this.tabIndex == 1) {
@ -823,7 +824,42 @@
this.productList = newList;
uni.stopPullDownRefresh();
},500)
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '搜索结果',
path: page.$page.fullPath || '/' + page.route,
};
shareData.path = shareData.path + '?id=' + this.where.cate_id;
shareData.path = shareData.path + '&searchValue=' + this.where.keyword;
//
if (this.isLogin) shareData.path = shareData.path + '&spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '搜索结果',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
shareData.query.id = this.where.cate_id;
shareData.query.searchValue =this.where.keyword;
return shareData
},
// #endif
}
</script>

View File

@ -57,7 +57,9 @@
</template>
<script>
let app = getApp();
import spread from "../../libs/spread";
let app = getApp();
import { getCategoryList } from '@/api/store.js';
import { getNavigation } from '@/api/public.js'
import { configMap } from '@/utils/index';
@ -76,7 +78,7 @@
passwordPopup,
// #endif
},
computed: configMap({navigation: {}},mapGetters(['viewColor','keyColor'])),
computed: configMap({navigation: {}},mapGetters(['isLogin','uid','viewColor','keyColor'])),
data() {
let active = 0;
// #ifdef H5
@ -169,6 +171,9 @@
});
// #endif
this.getAllCategory();
//
if(options.spread) spread(options.spread, this.isLogin)
},
/**
* 用户点击右上角分享
@ -179,16 +184,31 @@
withShareTicket: true,
menus: ['shareAppMessage', 'shareTimeline']
})
return {
path: '/pages/goods_cate/goods_cate?activceCate=' + this.productList[this.navActive] ? this.productList[this.navActive].store_category_id : 0
}
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '商品分类',
path: page.$page.fullPath || '/' + page.route,
};
shareData.path = shareData.path + '?activceCate=' + this.productList[this.navActive] ? this.productList[this.navActive].store_category_id : 0;
//
if (this.isLogin) shareData.path = shareData.path + '&spread=' + this.uid;
//
return shareData
},
onShareTimeline: function() {
return {
query: {
activceCate: this.productList[this.navActive] ? this.productList[this.navActive].store_category_id : 0,
}
}
let shareData = {
title: '商品分类',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
shareData.query.activceCate = this.productList[this.navActive] ? this.productList[this.navActive].store_category_id : 0;
return shareData;
},
// #endif
onShow() {

View File

@ -42,6 +42,8 @@
} from '@/api/api.js';
import shareInfo from '@/components/shareInfo';
import home from '@/components/home';
import spread from "../../libs/spread";
import { mapGetters } from "vuex";
export default {
components: {
shareInfo,
@ -60,6 +62,7 @@
},
};
},
computed: mapGetters(['isLogin','uid']),
/**
* 生命周期函数--监听页面加载
*/
@ -76,6 +79,9 @@
history.back();
// #endif
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
onShow: function() {
this.getArticleOne();
@ -119,7 +125,36 @@
};
this.$wechat.wechatEvevt(["updateAppMessageShareData", "updateTimelineShareData"], configAppMessage);
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '资讯详情',
path: page.$page.fullPath || '/' + page.route,
};
shareData.path = shareData.path + '?id=' + this.id;
//
if (this.isLogin) shareData.path = shareData.path + '&spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '资讯详情',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
shareData.query.id = this.id;
return shareData
},
// #endif
}
</script>

View File

@ -56,6 +56,8 @@
getArticleBannerList
} from '@/api/api.js';
import home from '@/components/home';
import spread from "../../libs/spread";
import { mapGetters } from "vuex";
export default {
components: {
home
@ -77,6 +79,7 @@
scrollLeft: 0
};
},
computed: mapGetters(['isLogin','uid']),
/**
* 生命周期函数--监听页面显示
*/
@ -84,11 +87,13 @@
/**
* 生命周期函数--监听页面显示
*/
onLoad: function() {
onLoad: function(options) {
this.getArticleCate();
this.status = false;
this.page = 1;
this.articleList = [];
this.articleList = [];
//
if(options.spread) spread(options.spread, this.isLogin)
},
/**
* 页面上拉触底事件的处理函数
@ -147,7 +152,34 @@
this.getCidArticle();
}
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '资讯',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '资讯',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -151,6 +151,7 @@
import authorize from '@/components/Authorize';
import { configMap } from '@/utils';
import { HTTP_REQUEST_URL } from '@/config/app';
import spread from "../../libs/spread";
const app = getApp();
export default {
props: {
@ -217,11 +218,13 @@
activeRouter: '',
};
},
computed: configMap({hide_mer_status: 1,recommend_switch:0,navigation: {}}, mapGetters(['isLogin','viewColor'])),
computed: configMap({hide_mer_status: 1,recommend_switch:0,navigation: {}}, mapGetters(['isLogin','uid','viewColor'])),
onReady(){},
mounted: function() {},
onLoad: function(options) {
//
if(options.spread) spread(options.spread, this.isLogin)
},
onShow: function() {
let that = this
@ -803,7 +806,33 @@
onPageScroll(e) {
// scrollTopeasy-loadimage
uni.$emit('scroll');
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '购物车',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '购物车',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -241,7 +241,7 @@
//#endif
that.getDetail();
that.getReplyList();
},
onShow() {
uni.hideLoading();
@ -544,7 +544,41 @@
onReachBottom() {
this.getReplyList()
},
onPullDownRefresh(){}
onPullDownRefresh(){},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '详情',
path: page.$page.fullPath || '/' + page.route,
};
shareData.path = shareData.path + '?id=' + this.id;
shareData.path = shareData.path + '&type=' + this.type;
//
if (this.isLogin) shareData.path = shareData.path + '&spid=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '详情',
query: {},
};
//
if (this.isLogin) shareData.query.spid = this.uid;
//
shareData.query.id = this.id;
shareData.query.type = this.type;
return shareData
},
// #endif
}
</script>

View File

@ -82,6 +82,7 @@
import { mapGetters } from "vuex";
import authorize from '@/components/Authorize';
import productConSwiper from '@/components/productConSwiper';
import spread from "../../../libs/spread";
const app = getApp();
export default {
components: {
@ -113,7 +114,7 @@
},
computed: {
...mapGetters(['isLogin']),
...mapGetters(['isLogin','uid']),
},
watch: {
@ -121,6 +122,9 @@
onLoad: function(options) {
this.where.topic_id = options.id
this.getList();
//
if(options.spread) spread(options.spread, this.isLogin)
},
onShow() {
@ -213,7 +217,39 @@
},
onPullDownRefresh(){
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '为你精选',
path: page.$page.fullPath || '/' + page.route,
};
shareData.path = shareData.path + '?id=' + this.where.topic_id;
//
if (this.isLogin) shareData.path = shareData.path + '&spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '为你精选',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
shareData.query.id = this.where.topic_id;
return shareData
},
// #endif
}
</script>

View File

@ -34,6 +34,7 @@
import { mapGetters } from "vuex";
import authorize from '@/components/Authorize';
import emptyPage from '@/components/emptyPage.vue'
import spread from "../../../libs/spread";
const app = getApp();
export default {
components: {
@ -71,6 +72,9 @@
this.where.spu_id = options.spu_id
this.getGoods();
this.getProDetail();
//
if(options.spread) spread(options.spread, this.isLogin)
},
onShow() {},
mounted: function() {},
@ -137,7 +141,38 @@
onPageScroll(e) {
// scrollTopeasy-loadimage
uni.$emit('scroll');
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '种草秀',
path: page.$page.fullPath || '/' + page.route,
};
shareData.path = shareData.path + '?spu_id=' + this.where.spu_id;
//
if (this.isLogin) shareData.path = shareData.path + '&spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '种草秀',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
shareData.query.spu_id = this.where.spu_id;
return shareData
},
// #endif
}
</script>

View File

@ -34,11 +34,13 @@
<script>
let app = getApp();
import spread from "../../../libs/spread";
let app = getApp();
import { getTopicList } from '@/api/community.js';
import { mapGetters } from "vuex";
export default {
computed: mapGetters(['viewColor']),
computed: mapGetters(['viewColor','isLogin','uid']),
data() {
return {
productList: [],
@ -60,6 +62,9 @@
that.winHeight = res.windowHeight
},
});
//
if(options.spread) spread(options.spread, this.isLogin)
},
onShow() {
if (!this.productList.length) {
@ -84,7 +89,35 @@
}
})
},
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '话题筛选',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '话题筛选',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>
<style scoped lang="scss">

View File

@ -8,7 +8,7 @@
<text>{{userInfo.nickname || ''}}</text>
<image v-if="userInfo.member_icon" class="level_icon" :src="userInfo.member_icon" alt="">
</view>
<view class="user_id">ID: {{userInfo.uid || ''}}</view>
<view class="user_id">ID: {{userInfo.current_uid || ''}}</view>
</view>
</view>
<view class="plant_info acea-row">
@ -44,7 +44,7 @@
<view class="tab-cont">
<view v-if="goods.length > 0" class="goods-wrap">
<view class="goods">
<WaterfallsFlow :wfList='goods' :isAuth="1" :uid="parseInt(uid)" :tab="tab"/>
<WaterfallsFlow :wfList='goods' :isAuth="1" :uid="parseInt(current_uid)" :tab="tab"/>
</view>
</view>
<view v-if="goods.length == 0 && !loading" class="empty">
@ -69,6 +69,7 @@
import { mapGetters } from "vuex";
import authorize from '@/components/Authorize';
import { HTTP_REQUEST_URL } from '@/config/app';
import spread from "../../../libs/spread";
const app = getApp();
export default {
components: {
@ -90,24 +91,28 @@
limit: 30
},
tab: 0,
uid: ''
current_uid: ''
}
},
created() {},
computed: {
...mapGetters(['isLogin','viewColor']),
...mapGetters(['isLogin','uid','viewColor']),
},
watch: {},
onLoad: function(options) {
let that = this;
that.uid = options.id
that.current_uid = options.id
if (that.isLogin) {
that.getAuthorInfo(that.uid);
that.getList(that.uid);
that.getAuthorInfo(that.current_uid);
that.getList(that.current_uid);
} else {
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
onShow() {},
onReady() {},
@ -116,8 +121,8 @@
//
onLoadFun() {
this.isShowAuth = false
this.getAuthorInfo(this.uid);
this.getList(this.uid);
this.getAuthorInfo(this.current_uid);
this.getList(this.current_uid);
},
//
authColse: function(e) {
@ -145,7 +150,7 @@
this.isShowAuth = true
} else {
let status = this.userInfo.is_start ? false : true
followAuthorApi(this.userInfo.uid,{status: status}).then(res => {
followAuthorApi(this.userInfo.current_uid,{status: status}).then(res => {
if (res.status === 200) {
this.userInfo.is_start = this.userInfo.is_start ? false : true
}
@ -160,18 +165,18 @@
this.where.page = 1
this.loaded = this.loading = false
this.goods = []
let uid = this.userInfo.is_self ? this.uid : this.userInfo.uid
this.getList(uid)
let current_uid = this.userInfo.is_self ? this.current_uid : this.userInfo.current_uid
this.getList(current_uid)
},
//
getList: function(uid) {
getList: function(current_uid) {
let that = this;
if (that.loaded || that.loading) return;
that.loading = true;
that.loadTitle = '';
that.tab == 1 ? this.where.is_type = 1 : this.where.is_type = ''
that.tab == 0 ?
userArticleLst(uid,that.where).then(res => {
userArticleLst(current_uid,that.where).then(res => {
let list = res.data.list;
let goods = that.$util.SplitArray(list, that.goods);
that.loaded = list.length < that.where.limit;
@ -205,15 +210,47 @@
}
},
onReachBottom() {
let uid = this.userInfo.is_self ? this.uid : this.userInfo.uid
this.getList(uid);
let current_uid = this.userInfo.is_self ? this.current_uid : this.userInfo.current_uid
this.getList(current_uid);
},
onPullDownRefresh(){},
//
onPageScroll(e) {
// scrollTopeasy-loadimage
uni.$emit('scroll');
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '用户主页',
path: page.$page.fullPath || '/' + page.route,
};
shareData.path = shareData.path + '?id=' + this.current_uid;
//
if (this.isLogin) shareData.path = shareData.path + '&spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '用户主页',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
shareData.query.id = this.current_uid;
return shareData
},
// #endif
}
</script>

View File

@ -59,6 +59,7 @@
import passwordPopup from '@/components/passwordPopup';
// #endif
import { mapGetters } from "vuex";
import spread from "../../libs/spread";
let app = getApp();
export default {
components: {
@ -67,7 +68,7 @@
// #endif
home,
},
computed: configMap({statusBarHeight:0},mapGetters(['viewColor','keyColor'])),
computed: configMap({statusBarHeight:0},mapGetters(['isLogin','uid','viewColor','keyColor'])),
data() {
return {
domain: HTTP_REQUEST_URL,
@ -89,23 +90,34 @@
withShareTicket: true,
menus: ['shareAppMessage', 'shareTimeline']
})
return {
title: '好物精选',
path: 'pages/points_mall/goodSelection',
}
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '好物精选',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
onShareTimeline: function() {
return {
title: '好物精选',
query: {
key: ''
},
imageUrl: ''
}
let shareData = {
title: '好物精选',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
onLoad() {
onLoad(options) {
this.getSelectionList('');
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
goBack: function() {

View File

@ -87,6 +87,7 @@
import { getIntegralHome, getIntegralScope, getIntegralGoodsList } from '@/api/points_mall.js'
import { goShopDetail } from '@/libs/order.js';
import {HTTP_REQUEST_URL} from '@/config/app';
import spread from "../../libs/spread";
export default {
components: {},
data() {
@ -113,11 +114,14 @@
}
}
},
computed: mapGetters(['isLogin','viewColor']),
onLoad() {
computed: mapGetters(['isLogin','uid','viewColor']),
onLoad(options) {
this.getIntegralHome();
this.getIntegralScope();
this.getIntegralGoods();
//
if(options.spread) spread(options.spread, this.isLogin)
},
watch: {
@ -234,6 +238,33 @@
onReachBottom() {
this.getIntegralGoods()
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '积分商城',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '积分商城',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -68,8 +68,9 @@
import { mapGetters } from "vuex";
import { goShopDetail } from '@/libs/order.js'
import {HTTP_REQUEST_URL} from '@/config/app';
import spread from "../../libs/spread";
export default {
computed: mapGetters(['uid','viewColor','keyColor']),
computed: mapGetters(['isLogin','uid','viewColor','keyColor']),
components: {
recommend,
},
@ -103,6 +104,9 @@
this.$set(this.where, 'cate_id', option.cate_id || '');
this.$set(this.where, 'keyword', option.searchValue || '');
this.get_product_list();
//
if(option.spread) spread(option.spread, this.isLogin)
},
onShow(){
uni.removeStorageSync('form_type_cart');
@ -187,7 +191,34 @@
onReachBottom() {
this.get_product_list();
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '积分商品列表',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '积分商品列表',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -84,6 +84,7 @@ import { mapGetters } from 'vuex';
import { configMap } from "@/utils";
import { getStoreDetail, followStore, unfollowStore, merchantQrcode } from '@/api/store.js';
import { HTTP_REQUEST_URL } from '@/config/app';
import spread from "../../../libs/spread";
let app = getApp();
export default {
computed: {
@ -120,6 +121,9 @@ export default {
this.id = options.mer_id || options.id;
this.getStore();
this.getStoreCode();
//
if(options.spread) spread(options.spread, this.isLogin)
},
onReady: function() {},
mounted: function() {},
@ -306,7 +310,38 @@ export default {
});
}
// #endif
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '店铺详情',
path: page.$page.fullPath || '/' + page.route,
};
shareData.path = shareData.path + '?id=' + this.id;
//
if (this.isLogin) shareData.path = shareData.path + '&spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '店铺详情',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
shareData.query.id = this.id;
return shareData
},
// #endif
};
</script>

View File

@ -125,6 +125,7 @@
import { mapGetters } from "vuex";
import { goShopDetail } from '@/libs/order.js'
import { HTTP_REQUEST_URL } from '@/config/app'
import spread from "../../../libs/spread";
const app = getApp();
export default {
computed: configMap({hide_mer_status:0, recommend_switch: 0},mapGetters(['uid','isLogin','viewColor','keyColor'])),
@ -221,6 +222,9 @@
this.$set(this.where, 'keyword', options.searchValue || '');
this.get_product_list();
this.get_host_product();
//
if(options.spread) spread(options.spread, this.isLogin)
},
onReady(){},
mounted: function() {},
@ -478,6 +482,34 @@
onPageScroll() {
uni.$emit('scroll');
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '商品列表',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '商品列表',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -147,6 +147,7 @@
import authorize from '@/components/Authorize';
import Verify from '@/components/verify/verify.vue';
import { HTTP_REQUEST_URL } from '@/config/app';
import spread from "../../../libs/spread";
const app = getApp();
export default {
components: {
@ -204,7 +205,7 @@
beforeDestroy() {
clearTimeout(this.timer)
},
computed: configMap({sys_intention_agree:''},mapGetters(['isLogin','viewColor','keyColor'])),
computed: configMap({sys_intention_agree:''},mapGetters(['isLogin','uid','viewColor','keyColor'])),
onLoad(options) {
if (this.isLogin) {
this.getClassfication();
@ -222,6 +223,9 @@
this.getGoodsDetails(options.mer_i_id)
})
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
onShow() {},
onReady() {},
@ -565,7 +569,34 @@
});
this.$refs.verify.show();
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '商家入驻',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '商家入驻',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -176,16 +176,15 @@
</template>
<script>
import { storeMerchantList, getGeocoder } from '@/api/store.js';
import recommend from '@/components/recommend';
import rightSlider from '@/components/rightSlider/index';
import { merClassifly, getStoreTypeApi } from '@/api/store.js';
import { mapGetters } from "vuex";
import { goShopDetail } from '@/libs/order.js'
import { configMap } from '@/utils';
import { HTTP_REQUEST_URL } from '@/config/app'
import easyLoadimage from '@/components/easy-loadimage/easy-loadimage.vue';
import spread from "../../../libs/spread";
const app = getApp();
export default {
components: {
@ -272,6 +271,9 @@
},500)
this.getClassfication();
this.getStoreType();
//
if(options.spread) spread(options.spread, this.isLogin)
},
computed: {
downMenus: function() {
@ -289,7 +291,7 @@
mer_location: 0,
store_street_theme: 1,
hide_mer_status: '',
}, mapGetters(['viewColor'])),
}, mapGetters(['isLogin','uid','viewColor'])),
},
methods: {
//
@ -540,7 +542,34 @@
onPageScroll(e) {
// scrollTopeasy-loadimage
uni.$emit('scroll');
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '附近商家',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '附近商家',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -208,7 +208,9 @@
</view>
</template>
<script>
let sysHeight = uni.getSystemInfoSync().statusBarHeight + 'px';
import spread from "../../libs/spread";
let sysHeight = uni.getSystemInfoSync().statusBarHeight + 'px';
import { getMenuList, getUserInfo, setVisit } from '@/api/user.js';
import { getVersion, getNavigation } from "@/api/public";
import { orderData } from '@/api/order.js'
@ -241,7 +243,7 @@
balance_func_status: 0,
svip_switch_status: 0,
navigation: {}
} , mapGetters(['isLogin','viewColor','keyColor'])),
} , mapGetters(['isLogin','uid','viewColor','keyColor'])),
filters: {
dateFormat: function(value) {
return dayjs(value * 1000).format('YYYY-MM-DD');
@ -327,10 +329,13 @@
swiperHeight: 0, // (px)
}
},
onLoad() {
onLoad(options) {
this.$nextTick(() => {
this.setSwiperHeight(); // swiper
});
//
if(options.spread) spread(options.spread, this.isLogin)
},
onReady() {
this.isNodes++;
@ -610,6 +615,33 @@
this.getMyMenus();
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '个人中心',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '个人中心',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -12,6 +12,8 @@
<script>
import {cacheLst} from '@/api/user.js';
import spread from "../../../libs/spread";
import { mapGetters } from "vuex";
export default{
name:'agreement-rules',
data(){
@ -19,8 +21,11 @@
listDta:''
}
},
onLoad: function() {
computed: mapGetters(['isLogin','uid']),
onLoad: function(options) {
this.getInfo()
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods:{
getInfo(){
@ -33,7 +38,33 @@
url: '/pages/users/user_about/index?from='+e
})
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '协议规则',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '协议规则',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -86,12 +86,13 @@
import { goShopDetail } from '@/libs/order.js'
import easyLoadimage from '@/components/easy-loadimage/easy-loadimage.vue';
import { mapGetters } from "vuex";
import spread from "../../../libs/spread";
export default{
components:{
emptyPage,
easyLoadimage
},
computed: mapGetters(['viewColor']),
computed: mapGetters(['isLogin','uid','viewColor']),
data(){
return {
list:[],
@ -104,6 +105,11 @@
total: 0
}
},
onLoad(options){
//
if(options.spread) spread(options.spread, this.isLogin)
},
onShow() {
this.list = [];
this.allArr = [];
@ -316,7 +322,34 @@
onPageScroll(e) {
// scrollTopeasy-loadimage
uni.$emit('scroll');
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '浏览记录',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '浏览记录',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -37,6 +37,7 @@
import { getBrokerageRank } from '@/api/user.js';
import { mapGetters } from "vuex";
import authorize from '@/components/Authorize';
import spread from "../../../libs/spread";
export default {
components: {
authorize,
@ -58,14 +59,17 @@
isShowAuth: false, //
};
},
computed: mapGetters(['isLogin','viewColor','keyColor']),
onLoad(){
computed: mapGetters(['isLogin','uid','viewColor','keyColor']),
onLoad(options){
if(this.isLogin){
this.getBrokerageRankList();
}else{
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
onLoadFun:function(){
@ -111,7 +115,33 @@
onReachBottom: function () {
this.page++;
this.getBrokerageRankList();
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '佣金排行',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '佣金排行',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -117,11 +117,12 @@
import ProductWindow from "@/components/productWindow";
import { mapGetters } from "vuex";
import { HTTP_REQUEST_URL } from '@/config/app';
import spread from "../../../libs/spread";
export default {
components: {
ProductWindow
},
computed: mapGetters(['viewColor','keyColor']),
computed: mapGetters(['isLogin','uid','viewColor','keyColor']),
data() {
return {
domain: HTTP_REQUEST_URL,
@ -152,7 +153,10 @@
openActivity: false,
}
},
onLoad() {},
onLoad(options) {
//
if(options.spread) spread(options.spread, this.isLogin)
},
onShow: function() {
this.bagExplain();
this.productBag();
@ -448,7 +452,34 @@
close() {
this.explainShow = false;
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '附近商家',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '附近商家',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -85,6 +85,7 @@
import { mapGetters } from "vuex";
import { HTTP_REQUEST_URL } from '@/config/app';
import { configMap } from '@/utils';
import spread from "../../../libs/spread";
export default {
data() {
return {
@ -108,22 +109,23 @@
}
},
computed:{
...configMap(['is_open_service'], mapGetters(['viewColor', 'keyColor']))
...configMap(['is_open_service'], mapGetters(['isLogin','uid','viewColor', 'keyColor']))
},
watch: {
uploadImg(nVal, oVal) {
this.isUpload = nVal.length < 6 ? true : false
}
},
onLoad() {
onLoad(options) {
this.hasService()
//
feedbackType().then(({
data
}) => {
feedbackType().then(({data}) => {
this.tabList = data
this.getFeedBack(data)
})
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
toChat(){
@ -236,7 +238,34 @@
})
})
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '问题反馈',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '问题反馈',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -21,11 +21,12 @@
import emptyPage from '@/components/emptyPage.vue'
import { feedbackList } from '@/api/user.js'
import { mapGetters } from "vuex";
import spread from "../../../libs/spread";
export default {
components:{
emptyPage
},
computed: mapGetters(['viewColor']),
computed: mapGetters(['isLogin','uid','viewColor']),
data(){
return {
list:[],
@ -34,8 +35,11 @@
isScroll:true
}
},
onLoad() {
onLoad(options) {
this.getList()
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods:{
getList(){
@ -58,7 +62,34 @@
},
onReachBottom() {
this.getList()
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '反馈记录',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '反馈记录',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -64,6 +64,7 @@
import {
mapGetters
} from "vuex";
import spread from "../../../libs/spread";
// import cookie from "@/utils/store/cookie";
const LONGITUDE = "user_longitude";
const LATITUDE = "user_latitude";
@ -73,7 +74,7 @@
components: {
Loading
},
// computed: mapGetters(["goName"]),
computed: mapGetters(['isLogin','uid']),
data() {
return {
page: 1,
@ -89,13 +90,16 @@
user_longitude: 0
};
},
onLoad() {
onLoad(options) {
try {
this.user_latitude = uni.getStorageSync('user_latitude');
this.user_longitude = uni.getStorageSync('user_longitude');
} catch (e) {
// error
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
mounted() {
if (this.user_latitude && this.user_longitude) {
@ -225,7 +229,33 @@
},
onReachBottom() {
this.getList();
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '门店列表',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '门店列表',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
};
</script>

View File

@ -254,7 +254,9 @@
<script>
let app = getApp();
import spread from "../../../libs/spread";
let app = getApp();
import {
getOrderList,
orderData,
@ -334,8 +336,13 @@
}
};
},
onLoad(options) {
//
if(options.spread) spread(options.spread, this.isLogin)
},
computed: {
...mapGetters(['isLogin','viewColor']),
...mapGetters(['isLogin','uid','viewColor']),
...configMap(['hide_mer_status', 'community_status', 'alipay_open', 'yue_pay_status']),
},
watch: {
@ -722,7 +729,34 @@
},
onReachBottom: function() {
this.getOrderList();
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '订单列表',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '订单列表',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -69,7 +69,9 @@
<script>
let app = getApp();
import spread from "../../../libs/spread";
let app = getApp();
import {
getOrderList,
orderData,
@ -139,8 +141,12 @@
isTimePay: false,
};
},
onLoad(options){
//
if(options.spread) spread(options.spread, this.isLogin)
},
computed: {
...mapGetters(['isLogin','viewColor']),
...mapGetters(['isLogin','uid','viewColor']),
...configMap(['hide_mer_status', 'community_status', 'alipay_open', 'yue_pay_status']),
},
onShow() {
@ -398,7 +404,35 @@
},
onReachBottom: function() {
this.getOrderList();
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '预售订单',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '预售订单',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -85,6 +85,7 @@
import authorize from '@/components/Authorize';
import { HTTP_REQUEST_URL } from '@/config/app';
import timeSlot from '@/components/timeSlot/index.vue';
import spread from "../../../libs/spread";
export default {
components: {
authorize,
@ -112,8 +113,8 @@
};
},
computed: mapGetters(['isLogin','viewColor','keyColor']),
onLoad() {
computed: mapGetters(['isLogin','uid','viewColor','keyColor']),
onLoad(options) {
if (this.isLogin) {
this.userSpreadNewList();
this.getUserInfo()
@ -121,6 +122,9 @@
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
onShow: function() {
if (this.is_show){
@ -217,7 +221,34 @@
},
onReachBottom: function() {
this.userSpreadNewList();
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '推广人统计',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '推广人统计',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -63,6 +63,7 @@
import authorize from '@/components/Authorize';
import emptyPage from '@/components/emptyPage.vue';
import timeSlot from '@/components/timeSlot/index.vue';
import spread from "../../../libs/spread";
export default {
components: {
authorize,
@ -88,14 +89,17 @@
times: [],
};
},
computed: mapGetters(['isLogin','viewColor']),
onLoad() {
computed: mapGetters(['isLogin','uid','viewColor']),
onLoad(options) {
if (this.isLogin) {
this.getRecordOrderList();
} else {
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
spreadInfo(){
@ -154,7 +158,33 @@
},
onReachBottom() {
this.getRecordOrderList();
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '推广人订单',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '推广人订单',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -56,6 +56,7 @@
import { getRankList } from '@/api/user.js';
import { mapGetters } from "vuex";
import authorize from '@/components/Authorize';
import spread from "../../../libs/spread";
export default {
components: {
authorize
@ -77,14 +78,17 @@
isShowAuth: false //
};
},
computed: mapGetters(['isLogin','viewColor']),
onLoad() {
computed: mapGetters(['isLogin','uid','viewColor']),
onLoad(options) {
if (this.isLogin) {
this.getRanklist();
} else {
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
onLoadFun() {
@ -139,7 +143,33 @@
},
onReachBottom: function() {
this.getRanklist();
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '推广人排行',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '推广人排行',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -55,7 +55,9 @@
<script>
const app = getApp();
import spread from "../../../libs/spread";
const app = getApp();
import sendVerifyCode from "@/mixins/SendVerifyCode";
import {
registerVerify,
@ -73,6 +75,7 @@
} from "@/utils/validate";
import { configMap } from '@/utils';
import Verify from '@/components/verify/verify.vue';
import { mapGetters } from "vuex";
export default {
name: "RetrievePassword",
components: {
@ -91,7 +94,12 @@
isShowCode: false,
};
},
computed: configMap(['login_logo']),
onLoad(options) {
//
if(options.spread) spread(options.spread, this.isLogin)
},
computed: configMap(['login_logo'],mapGetters(['isLogin','uid'])),
onReady() {
},
mounted: function() {
@ -183,7 +191,33 @@
handleVerify() {
this.$refs.verify.show();
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '忘记密码',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '忘记密码',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
};
</script>
<style scoped>

View File

@ -35,6 +35,7 @@
getLogout
} from '@/api/user.js'
import { mapGetters } from "vuex";
import spread from "../../../libs/spread";
export default {
name: 'user_about',
data() {
@ -49,10 +50,13 @@
},
}
},
computed: mapGetters(['viewColor']),
computed: mapGetters(['isLogin','uid','viewColor']),
onLoad: function(options) {
this.type = options.from;
this.setTitle(this.type)
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
toCancel(){
@ -161,7 +165,34 @@
break;
}
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '协议',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '协议',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -58,6 +58,7 @@
import areaWindow from '@/components/areaWindow';
import { getGeocoder } from '@/api/store.js';
import authorize from '@/components/Authorize';
import spread from "../../../libs/spread";
export default {
components: {
areaWindow,
@ -88,7 +89,7 @@
loading: false
};
},
computed: {...mapGetters(['isLogin','viewColor']),
computed: {...mapGetters(['isLogin','uid','viewColor']),
addressText(){
return this.addressInfo.map(v=>v.name).join('/');
}
@ -109,6 +110,9 @@
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
OnChangeAddress(address){
@ -347,7 +351,33 @@
ChangeIsDefault: function(e) {
this.$set(this.userAddress, 'is_default', !this.userAddress.is_default);
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '添加地址',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '添加地址',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -48,7 +48,9 @@
<script>
// #ifdef H5
const jweixin = require('@/plugin/jweixin-module/index.js')
import spread from "../../../libs/spread";
const jweixin = require('@/plugin/jweixin-module/index.js')
// #endif
import {getWechatConfig} from '@/api/public.js'
import {
@ -82,7 +84,7 @@
domain: HTTP_REQUEST_URL,
};
},
computed: mapGetters(['isLogin', 'viewColor']),
computed: mapGetters(['isLogin','uid', 'viewColor']),
onLoad(options) {
if (this.isLogin) {
this.cartId = options.cartId || '';
@ -99,6 +101,9 @@
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
onReady() {
@ -346,7 +351,42 @@
},
onReachBottom: function() {
this.getAddressList();
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '地址管理',
path: page.$page.fullPath || '/' + page.route,
};
shareData.path = shareData.path + '?cartId=' + this.cartId;
shareData.path = shareData.path + '&pinkId=' + this.pinkId;
shareData.path = shareData.path + '&couponId=' + this.couponId;
//
if (this.isLogin) shareData.path = shareData.path + '&spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '地址管理',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
shareData.query.cartId = this.cartId;
shareData.query.pinkId = this.pinkId;
shareData.query.couponId = this.couponId;
return shareData
},
// #endif
}
</script>

View File

@ -44,6 +44,7 @@
} from "vuex";
import authorize from '@/components/Authorize';
import emptyPage from '@/components/emptyPage.vue'
import spread from "../../../libs/spread";
export default {
components: {
authorize,
@ -62,7 +63,7 @@
isShowAuth: false //
};
},
computed: mapGetters(['isLogin','viewColor']),
computed: mapGetters(['isLogin','uid','viewColor']),
onShow() {
if (this.isLogin) {
this.getUserBillList();
@ -76,6 +77,9 @@
*/
onLoad: function(options) {
this.type = options.type || 0;
//
if(options.spread) spread(options.spread, this.isLogin)
},
/**
* 页面上拉触底事件的处理函数
@ -133,7 +137,33 @@
this.$set(this, 'userBillList', []);
this.getUserBillList();
},
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '账单明细',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '账单明细',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -132,6 +132,7 @@
import authorize from '@/components/Authorize';
import emptyPage from '@/components/emptyPage.vue';
import parser from "@/components/jyf-parser/jyf-parser";
import spread from "../../../libs/spread";
const app = getApp();
export default {
components: {
@ -159,8 +160,8 @@
type: ''
};
},
computed: mapGetters(['isLogin']),
onLoad() {
computed: mapGetters(['isLogin','uid']),
onLoad(options) {
if (this.isLogin) {
this.getUserInfo();
this.getGrade();
@ -170,6 +171,9 @@
this.isShowAuth = true
}
this.getAgreement();
//
if(options.spread) spread(options.spread, this.isLogin)
},
/**
* 页面上拉触底事件的处理函数
@ -278,7 +282,33 @@
}
return(s);
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '分销等级',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '分销等级',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -159,6 +159,7 @@
import authorize from '@/components/Authorize';
import cash from '@/components/cash';
import { configMap } from '@/utils';
import spread from "../../../libs/spread";
export default {
components: {
cash,
@ -211,7 +212,7 @@
};
},
computed: {
...mapGetters(['isLogin','viewColor']),
...mapGetters(['isLogin','uid','viewColor']),
... configMap(['sys_extension_type', 'withdraw_type'])
},
watch: {
@ -231,6 +232,9 @@
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
loadType(){
@ -417,7 +421,33 @@
(action && this[action]) && this[action](value);
this.currentTab = opt.type
},
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '提现',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '提现',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -65,7 +65,9 @@
<script>
let app = getApp();
import spread from "../../../libs/spread";
let app = getApp();
import {
getUserCoupons
} from '@/api/api.js';
@ -103,7 +105,7 @@
};
},
computed: configMap(['hide_mer_status'], mapGetters(['isLogin','viewColor','keyColor'])),
computed: configMap(['hide_mer_status'], mapGetters(['isLogin','uid','viewColor','keyColor'])),
filters: {
timeYMD: function (value) {
if(value){
@ -112,13 +114,16 @@
}
}
},
onLoad() {
onLoad(options) {
if (this.isLogin) {
this.getUseCoupons();
} else {
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
mounted: function() {
},
@ -168,7 +173,33 @@
},
onReachBottom() {
this.getUseCoupons()
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '我的优惠券',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '我的优惠券',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -40,6 +40,7 @@
import { mapGetters } from "vuex";
import authorize from '@/components/Authorize';
import { HTTP_REQUEST_URL } from '@/config/app';
import spread from "../../../libs/spread";
export default {
components: {
authorize
@ -58,7 +59,7 @@
};
},
computed: mapGetters(['isLogin']),
onLoad(){
onLoad(options){
if(this.isLogin){
// #ifdef H5
this.getUseCoupons();
@ -67,6 +68,9 @@
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
/**
* 页面上拉触底事件的处理函数
@ -115,7 +119,34 @@
that.loadTitle = '加载更多';
});
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '领取优惠券',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '领取优惠券',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -159,6 +159,7 @@
import { configMap } from '@/utils';
import authorize from '@/components/Authorize';
import parser from "@/components/jyf-parser/jyf-parser";
import spread from "../../../libs/spread";
export default {
components: {
recommend,
@ -195,8 +196,8 @@
upgradeInfo: {}
};
},
computed: configMap({hide_mer_status: 1,recommend_switch:0,svip_switch_status:0},mapGetters(['isLogin'])),
onLoad() {
computed: configMap({hide_mer_status: 1,recommend_switch:0,svip_switch_status:0},mapGetters(['isLogin','uid'])),
onLoad(options) {
if (this.isLogin) {
this.getInstructions();
this.getUserInfo();
@ -207,6 +208,9 @@
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
/**
@ -295,6 +299,32 @@
onPageScroll() {
uni.$emit('scroll');
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '我的等级',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '我的等级',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -28,6 +28,7 @@
import { growthValueRecord } from '@/api/user.js';
import { mapGetters } from "vuex";
import authorize from '@/components/Authorize';
import spread from "../../../libs/spread";
export default {
components: {
authorize
@ -44,14 +45,17 @@
isShowAuth: false //
};
},
computed: mapGetters(['isLogin']),
onLoad(){
computed: mapGetters(['isLogin','uid']),
onLoad(options){
if(this.isLogin){
this.getGrowthListList();
}else{
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
onReachBottom: function () {
this.getGrowthListList();
@ -91,7 +95,33 @@
that.loadtitle = '加载更多';
});
},
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '成长值记录',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '成长值记录',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -143,6 +143,7 @@
import authorize from '@/components/Authorize';
import Cache from '@/utils/cache';
import { HTTP_REQUEST_URL } from '@/config/app';
import spread from "../../../libs/spread";
export default {
components: {
authorize
@ -161,8 +162,8 @@
version: ''
};
},
computed: configMap({open_update_info: 0} ,mapGetters(['isLogin','viewColor','keyColor'])),
onLoad() {
computed: configMap({open_update_info: 0} ,mapGetters(['isLogin','uid','viewColor','keyColor'])),
onLoad(options) {
if (this.isLogin) {
this.getUserInfo();
} else {
@ -172,6 +173,9 @@
//#ifdef APP-PLUS
this.appVersionConfig()
//#endif
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
toggle(type) {
@ -357,7 +361,33 @@
}
});
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '个人资料',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '个人资料',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -160,6 +160,7 @@ import {
import authorize from '@/components/Authorize';
import emptyPage from '@/components/emptyPage.vue';
import parser from "@/components/jyf-parser/jyf-parser";
import spread from "../../../libs/spread";
const app = getApp();
export default {
@ -215,7 +216,7 @@ export default {
},
...mapGetters(['isLogin', 'userInfo', 'viewColor'])
},
onLoad() {
onLoad(options) {
if (this.isLogin) {
this.getUserInfo();
} else {
@ -223,6 +224,9 @@ export default {
this.isShowAuth = true
}
this.getAgreement();
//
if(options.spread) spread(options.spread, this.isLogin)
},
onReachBottom: function () {
this.getIntegralList();
@ -341,7 +345,33 @@ export default {
console.log("错误 catch",err);
})
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '积分详情',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '积分详情',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -67,6 +67,7 @@
import { invoice, invoiceDelete } from '@/api/user.js';
import { receiptOrder } from '@/api/order.js';
import { HTTP_REQUEST_URL } from '@/config/app';
import spread from "../../../libs/spread";
export default {
components: {
home
@ -98,7 +99,7 @@
orderPage:1
};
},
computed: mapGetters(['isLogin','viewColor']),
computed: mapGetters(['isLogin','uid','viewColor']),
watch: {
loading(value) {
if (value) {
@ -119,7 +120,9 @@
uni.removeStorageSync('user_invoice_list')
}catch(error){}
}
//
if(options.spread) spread(optios.spread, this.isLogin)
},
onShow() {
this.orderPage =1
@ -229,7 +232,34 @@
},
onReachBottom() {
this.receiptOrder()
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '发票管理',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '发票管理',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -41,6 +41,7 @@
} from "vuex";
import authorize from '@/components/Authorize';
import Verify from '@/components/verify/verify.vue';
import spread from "../../../libs/spread";
export default {
mixins: [sendVerifyCode],
components: {
@ -61,8 +62,8 @@
isShowCode: false
};
},
computed: mapGetters(['isLogin', 'viewColor']),
onLoad() {
computed: mapGetters(['isLogin','uid', 'viewColor']),
onLoad(options) {
let that = this
if (this.isLogin) {
this.getUserInfo()
@ -81,6 +82,9 @@
}
})
// #endif
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
onLoadFun:function(){
@ -175,7 +179,33 @@
handleVerify() {
this.$refs.verify.show();
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '修改手机号',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '修改手机号',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -41,6 +41,7 @@
} from "vuex";
import authorize from '@/components/Authorize';
import Verify from '@/components/verify/verify.vue';
import spread from "../../../libs/spread";
export default {
mixins: [sendVerifyCode],
components: {
@ -61,8 +62,8 @@
disabled: false,
};
},
computed: mapGetters(['isLogin', 'viewColor']),
onLoad() {
computed: mapGetters(['isLogin','uid', 'viewColor']),
onLoad(options) {
let that = this
if (this.isLogin) {
this.getUserInfo()
@ -81,6 +82,9 @@
}
})
// #endif
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
onLoadFun:function(){
@ -167,7 +171,33 @@
handleVerify() {
this.$refs.verify.show();
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '修改密码',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '修改密码',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -58,7 +58,9 @@
<script>
let app = getApp();
import spread from "../../../libs/spread";
let app = getApp();
import {
getProductHot
} from '@/api/store.js';
@ -95,8 +97,8 @@
hotLimit:10
};
},
computed: configMap(['recharge_switch', 'balance_func_status','recommend_switch'], mapGetters(['isLogin','viewColor','keyColor'])),
onLoad() {
computed: configMap(['recharge_switch', 'balance_func_status','recommend_switch'], mapGetters(['isLogin','uid','viewColor','keyColor'])),
onLoad(options) {
if (this.isLogin) {
this.getUserInfo()
this.get_host_product();
@ -104,6 +106,9 @@
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
onReady() {
},
@ -160,7 +165,33 @@
onPageScroll(e) {
// scrollTopeasy-loadimage
uni.$emit('scroll');
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '我的账户',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '我的账户',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -30,6 +30,7 @@
mapGetters
} from "vuex";
import authorize from '@/components/Authorize';
import spread from "../../../libs/spread";
export default {
components: {
authorize
@ -42,8 +43,8 @@
isShowAuth: false, //
};
},
computed: mapGetters(['isLogin', 'viewColor']),
onLoad() {
computed: mapGetters(['isLogin','uid', 'viewColor']),
onLoad(options) {
if (this.isLogin) {
this.getUserInfo();
@ -51,7 +52,8 @@
this.isAuto = true;
this.isShowAuth = true
};
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
@ -105,6 +107,33 @@
authColse: function(e) {
this.isShowAuth = e
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '昵称',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '昵称',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
}
</script>

View File

@ -55,7 +55,9 @@
<script>
var statusBarHeight = uni.getSystemInfoSync().statusBarHeight + 'px';
import spread from "../../../libs/spread";
var statusBarHeight = uni.getSystemInfoSync().statusBarHeight + 'px';
import {
spreadInfo,
rechargeRoutine,
@ -130,7 +132,7 @@
],
};
},
computed: mapGetters(['viewColor','isLogin']),
computed: mapGetters(['viewColor','isLogin','uid']),
onLoad(options) {
this.delta = options.delta || 1;
if (this.isLogin) {
@ -140,6 +142,9 @@
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
onUnload: function () {
uni.navigateBack({
@ -521,7 +526,33 @@
let value = opt.value != undefined ? opt.value : null;
action && this[action] && this[action](value);
},
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '余额充值',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '余额充值',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -33,6 +33,7 @@
import { configMap } from '@/utils/index';
import authorize from '@/components/Authorize';
import Verify from '@/components/verify/verify.vue';
import spread from "../../../libs/spread";
export default {
mixins: [sendVerifyCode],
components: {
@ -50,10 +51,10 @@
};
},
computed: {
...mapGetters(['isLogin', 'viewColor']),
...mapGetters(['isLogin','uid', 'viewColor']),
...configMap(['wechat_phone_switch'])
},
onLoad() {
onLoad(options) {
let that = this
if (this.isLogin) {
// verifyCode().then(res=>{
@ -74,6 +75,9 @@
}
})
// #endif
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
onLoadFun:function(){
@ -206,7 +210,33 @@
handleVerify() {
this.$refs.verify.show();
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '绑定手机',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '绑定手机',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -40,6 +40,7 @@
} from "vuex";
import authorize from '@/components/Authorize';
import Verify from '@/components/verify/verify.vue';
import spread from "../../../libs/spread";
export default {
mixins: [sendVerifyCode],
components: {
@ -57,14 +58,17 @@
isShowAuth: false //
};
},
computed: mapGetters(['isLogin']),
onLoad() {
computed: mapGetters(['isLogin','uid']),
onLoad(options) {
if (this.isLogin) {
this.getUserInfo();
} else {
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
/**
@ -153,7 +157,33 @@
handleVerify() {
this.$refs.verify.show();
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '修改密码',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '修改密码',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -31,13 +31,21 @@
<script>
export default{
import spread from "../../../libs/spread";
import { mapGetters } from "vuex";
export default{
name:'user-setting',
data(){
return{
}
},
computed: mapGetters(['isLogin','uid']),
onLoad(options) {
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods:{
/**
* 小程序设置
@ -63,8 +71,34 @@
uni.navigateTo({
url: '/pages/users/agreement_rules/index'
})
}
}
},
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '设置',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '设置',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -71,6 +71,7 @@
import { getSignUser, getSignList, setSignIntegral} from '@/api/user.js';
import authorize from '@/components/Authorize';
import { HTTP_REQUEST_URL } from '@/config/app';
import spread from "../../../libs/spread";
export default {
components: {
authorize
@ -93,8 +94,8 @@
disabled: false
};
},
computed: mapGetters(['isLogin','viewColor','keyColor']),
onLoad(){
computed: mapGetters(['isLogin','uid','viewColor','keyColor']),
onLoad(options){
if(this.isLogin){
this.getUserInfo();
this.getSignList();
@ -102,6 +103,9 @@
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
/**
@ -198,7 +202,33 @@
this.getSignList();
this.getUserInfo();
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '签到',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '签到',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -28,6 +28,7 @@
import { getSignMonthList } from '@/api/user.js';
import { mapGetters } from "vuex";
import authorize from '@/components/Authorize';
import spread from "../../../libs/spread";
export default {
components: {
authorize
@ -44,14 +45,17 @@
isShowAuth: false //
};
},
computed: mapGetters(['isLogin','viewColor']),
onLoad(){
computed: mapGetters(['isLogin','uid','viewColor']),
onLoad(options){
if(this.isLogin){
this.getSignMoneList();
}else{
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
onReachBottom: function () {
this.getSignMoneList();
@ -91,7 +95,33 @@
that.loadtitle = '加载更多';
});
},
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '签到记录',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '签到记录',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>
<style>

View File

@ -63,6 +63,7 @@
import home from '@/components/home';
// #ifdef APP-PLUS
import {HTTP_REQUEST_URL} from '@/config/app.js'
import spread from "../../../libs/spread";
// #endif
export default {
components: {
@ -114,10 +115,16 @@
hg: 500
};
},
onLoad(options) {
//
if(options.spread) spread(options.spread, this.isLogin)
},
computed: mapGetters({
'isLogin': 'isLogin',
'userData': 'userInfo',
'viewColor': 'viewColor'
'viewColor': 'viewColor',
'uid': 'uid'
}),
watch: {
isLogin: {
@ -296,15 +303,16 @@
downloadFilestoreImage(url) {
return new Promise((resolve, reject) => {
let that = this;
// console.log(' url',url);
uni.downloadFile({
url: url,
success: function(res) {
// console.log(" success",res);
resolve(res.tempFilePath);
},
fail: function() {
return that.$util.Tips({
title: ''
});
fail: function(err) {
resolve(url);
// console.log(" fail",err);
}
});
})
@ -344,7 +352,33 @@
uni.hideLoading();
});
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '分销海报',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '分销海报',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>

View File

@ -78,6 +78,7 @@
import authorize from '@/components/Authorize';
import emptyPage from '@/components/emptyPage.vue';
import timeSlot from '@/components/timeSlot/index.vue';
import spread from "../../../libs/spread";
export default {
components: {
authorize,
@ -103,7 +104,7 @@
stop: ""
};
},
computed: mapGetters(['isLogin','viewColor']),
computed: mapGetters(['isLogin','uid','viewColor']),
onLoad(options) {
if (this.isLogin) {
this.type = options.type;
@ -111,6 +112,10 @@
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
onShow: function() {
let type = this.type;
@ -210,7 +215,38 @@
},
onReachBottom: function() {
this.getRecordList();
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '佣金记录',
path: page.$page.fullPath || '/' + page.route,
};
shareData.path = shareData.path + '?type=' + this.type;
//
if (this.isLogin) shareData.path = shareData.path + '&spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '佣金记录',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
shareData.query.type = this.type;
return shareData
},
// #endif
}
</script>

View File

@ -78,6 +78,7 @@
} from "vuex";
import authorize from '@/components/Authorize';
import parser from "@/components/jyf-parser/jyf-parser";
import spread from "../../../libs/spread";
export default {
components: {
authorize,
@ -97,8 +98,8 @@
},
};
},
computed: mapGetters(['isLogin','viewColor']),
onLoad() {
computed: mapGetters(['isLogin','uid','viewColor']),
onLoad(options) {
if (this.isLogin) {
this.spreadInfo();
this.getCommissionDescription();
@ -106,6 +107,9 @@
this.isAuto = true;
this.isShowAuth = true
}
//
if(options.spread) spread(options.spread, this.isLogin)
},
methods: {
//
@ -155,7 +159,33 @@
},1000)
});
}
}
},
// #ifdef MP
//
onShareAppMessage () {
let pages = getCurrentPages();
let page = pages[pages.length - 1]
let shareData = {
title: '我的推广',
path: page.$page.fullPath || '/' + page.route,
};
//
if (this.isLogin) shareData.path = shareData.path + '?spread=' + this.uid;
//
return shareData
},
//
onShareTimeline() {
let shareData = {
title: '我的推广',
query: {},
};
//
if (this.isLogin) shareData.query.spread = this.uid;
//
return shareData
},
// #endif
}
</script>