|
@@ -1,5 +1,5 @@
|
|
<template>
|
|
<template>
|
|
- <!-- 首页 -->
|
|
|
|
|
|
+ <!-- 首页 -->
|
|
<view v-if="pageShow" class="page"
|
|
<view v-if="pageShow" class="page"
|
|
:class="bgTabVal==2?'fullsize noRepeat':bgTabVal==1?'repeat ysize':'noRepeat ysize'"
|
|
:class="bgTabVal==2?'fullsize noRepeat':bgTabVal==1?'repeat ysize':'noRepeat ysize'"
|
|
:style="'background-color:'+bgColor+';background-image: url('+bgPic+');min-height:'+windowHeight+'px;'">
|
|
:style="'background-color:'+bgColor+';background-image: url('+bgPic+');min-height:'+windowHeight+'px;'">
|
|
@@ -9,16 +9,17 @@
|
|
<!-- #ifdef H5 -->
|
|
<!-- #ifdef H5 -->
|
|
<view v-for="(item, index) in styleConfig" :key="index">
|
|
<view v-for="(item, index) in styleConfig" :key="index">
|
|
<component :is="item.name" :index="index" :dataConfig="item" @changeBarg="changeBarg"
|
|
<component :is="item.name" :index="index" :dataConfig="item" @changeBarg="changeBarg"
|
|
- @detail="goDetail" :isSortType="isSortType" @bindSortId="bindSortId"
|
|
|
|
- @bindHeight="bindHeight" :isFixed="isFixed" :productVideoStatus='product_video_status' :isScrolled="isScrolled">
|
|
|
|
|
|
+ @detail="goDetail" :isSortType="isSortType" @bindSortId="bindSortId" @bindHeight="bindHeight"
|
|
|
|
+ :isFixed="isFixed" :productVideoStatus='product_video_status' :isScrolled="isScrolled">
|
|
</component>
|
|
</component>
|
|
</view>
|
|
</view>
|
|
<!-- #endif -->
|
|
<!-- #endif -->
|
|
-
|
|
|
|
|
|
+
|
|
<!-- #ifdef MP || APP-PLUS -->
|
|
<!-- #ifdef MP || APP-PLUS -->
|
|
- <!-- 自定义样式 -->
|
|
|
|
|
|
+ <!-- 自定义样式 -->
|
|
<block v-for="(item, index) in styleConfig" :key="index">
|
|
<block v-for="(item, index) in styleConfig" :key="index">
|
|
- <homeComb v-if="item.name == 'homeComb'" :dataConfig="item" @bindSortId="bindSortId" :isScrolled="isScrolled"></homeComb>
|
|
|
|
|
|
+ <homeComb v-if="item.name == 'homeComb'" :dataConfig="item" @bindSortId="bindSortId"
|
|
|
|
+ :isScrolled="isScrolled"></homeComb>
|
|
<shortVideo v-if="item.name == 'shortVideo'" :dataConfig="item" :isSortType="isSortType">
|
|
<shortVideo v-if="item.name == 'shortVideo'" :dataConfig="item" :isSortType="isSortType">
|
|
</shortVideo>
|
|
</shortVideo>
|
|
<userInfor v-if="item.name == 'userInfor'" :dataConfig="item" :isSortType="isSortType">
|
|
<userInfor v-if="item.name == 'userInfor'" :dataConfig="item" :isSortType="isSortType">
|
|
@@ -27,7 +28,7 @@
|
|
</newVip>
|
|
</newVip>
|
|
<activeParty v-if="item.name == 'activeParty'" :dataConfig="item" :isSortType="isSortType">
|
|
<activeParty v-if="item.name == 'activeParty'" :dataConfig="item" :isSortType="isSortType">
|
|
</activeParty>
|
|
</activeParty>
|
|
- <!-- 文章列表 -->
|
|
|
|
|
|
+ <!-- 文章列表 -->
|
|
<articleList v-if="item.name == 'articleList'" :dataConfig="item" :isSortType="isSortType">
|
|
<articleList v-if="item.name == 'articleList'" :dataConfig="item" :isSortType="isSortType">
|
|
</articleList>
|
|
</articleList>
|
|
<bargain v-if="item.name == 'bargain'" :dataConfig="item" @changeBarg="changeBarg"
|
|
<bargain v-if="item.name == 'bargain'" :dataConfig="item" @changeBarg="changeBarg"
|
|
@@ -35,38 +36,39 @@
|
|
<blankPage v-if="item.name == 'blankPage'" :dataConfig="item" :isSortType="isSortType"></blankPage>
|
|
<blankPage v-if="item.name == 'blankPage'" :dataConfig="item" :isSortType="isSortType"></blankPage>
|
|
<combination v-if="item.name == 'combination'" :dataConfig="item" :isSortType="isSortType">
|
|
<combination v-if="item.name == 'combination'" :dataConfig="item" :isSortType="isSortType">
|
|
</combination>
|
|
</combination>
|
|
- <!-- 优惠券 -->
|
|
|
|
|
|
+ <!-- 优惠券 -->
|
|
<coupon v-if="item.name == 'coupon'" :dataConfig="item" :isSortType="isSortType"></coupon>
|
|
<coupon v-if="item.name == 'coupon'" :dataConfig="item" :isSortType="isSortType"></coupon>
|
|
- <!-- 客户服务 -->
|
|
|
|
|
|
+ <!-- 客户服务 -->
|
|
<customerService v-if="item.name == 'customerService'" :dataConfig="item" :isSortType="isSortType">
|
|
<customerService v-if="item.name == 'customerService'" :dataConfig="item" :isSortType="isSortType">
|
|
</customerService>
|
|
</customerService>
|
|
- <!-- 商品列表 -->
|
|
|
|
|
|
+ <!-- 商品列表 -->
|
|
<goodList v-if="item.name == 'goodList'" :dataConfig="item" @detail="goDetail"
|
|
<goodList v-if="item.name == 'goodList'" :dataConfig="item" @detail="goDetail"
|
|
:isSortType="isSortType"></goodList>
|
|
:isSortType="isSortType"></goodList>
|
|
<guide v-if="item.name == 'guide'" :dataConfig="item" :isSortType="isSortType"></guide>
|
|
<guide v-if="item.name == 'guide'" :dataConfig="item" :isSortType="isSortType"></guide>
|
|
- <!-- 顶部搜索框 -->
|
|
|
|
|
|
+ <!-- 顶部搜索框 -->
|
|
<headerSerch v-if="item.name == 'headerSerch'" :dataConfig="item"></headerSerch>
|
|
<headerSerch v-if="item.name == 'headerSerch'" :dataConfig="item"></headerSerch>
|
|
- <!-- 直播模块 -->
|
|
|
|
|
|
+ <!-- 直播模块 -->
|
|
<liveBroadcast v-if="item.name == 'liveBroadcast'" :dataConfig="item" :isSortType="isSortType">
|
|
<liveBroadcast v-if="item.name == 'liveBroadcast'" :dataConfig="item" :isSortType="isSortType">
|
|
</liveBroadcast>
|
|
</liveBroadcast>
|
|
<menus v-if="item.name == 'menus'" :dataConfig="item" :isSortType="isSortType"></menus>
|
|
<menus v-if="item.name == 'menus'" :dataConfig="item" :isSortType="isSortType"></menus>
|
|
- <!-- 实时消息 -->
|
|
|
|
|
|
+ <!-- 实时消息 -->
|
|
<news v-if="item.name == 'news'" :dataConfig="item" :isSortType="isSortType"></news>
|
|
<news v-if="item.name == 'news'" :dataConfig="item" :isSortType="isSortType"></news>
|
|
- <!-- 图片库 -->
|
|
|
|
|
|
+ <!-- 图片库 -->
|
|
<pictureCube v-if="item.name == 'pictureCube'" :dataConfig="item" :isSortType="isSortType">
|
|
<pictureCube v-if="item.name == 'pictureCube'" :dataConfig="item" :isSortType="isSortType">
|
|
</pictureCube>
|
|
</pictureCube>
|
|
- <!-- 促销列表 -->
|
|
|
|
- <promotionList v-if="item.name == 'promotionList'" :dataConfig="item" @detail="goDetail" :isSortType="isSortType" :productVideoStatus='product_video_status'>
|
|
|
|
|
|
+ <!-- 促销列表 -->
|
|
|
|
+ <promotionList v-if="item.name == 'promotionList'" :dataConfig="item" @detail="goDetail"
|
|
|
|
+ :isSortType="isSortType" :productVideoStatus='product_video_status'>
|
|
</promotionList>
|
|
</promotionList>
|
|
<richText v-if="item.name == 'richText'" :dataConfig="item" :isSortType="isSortType"></richText>
|
|
<richText v-if="item.name == 'richText'" :dataConfig="item" :isSortType="isSortType"></richText>
|
|
<seckill v-if="item.name == 'seckill'" :dataConfig="item" :isSortType="isSortType"></seckill>
|
|
<seckill v-if="item.name == 'seckill'" :dataConfig="item" :isSortType="isSortType"></seckill>
|
|
- <!-- 轮播图-->
|
|
|
|
|
|
+ <!-- 轮播图-->
|
|
<swiperBg v-if="item.name == 'swiperBg'" :dataConfig="item" :isSortType="isSortType"></swiperBg>
|
|
<swiperBg v-if="item.name == 'swiperBg'" :dataConfig="item" :isSortType="isSortType"></swiperBg>
|
|
<swipers v-if="item.name == 'swipers'" :dataConfig="item" :isSortType="isSortType"></swipers>
|
|
<swipers v-if="item.name == 'swipers'" :dataConfig="item" :isSortType="isSortType"></swipers>
|
|
- <!-- 顶部选项卡 -->
|
|
|
|
|
|
+ <!-- 顶部选项卡 -->
|
|
<tabNav v-if="item.name == 'tabNav'" :dataConfig="item" @bindHeight="bindHeighta"
|
|
<tabNav v-if="item.name == 'tabNav'" :dataConfig="item" @bindHeight="bindHeighta"
|
|
@bindSortId="bindSortId" :isFixed="isFixed"></tabNav>
|
|
@bindSortId="bindSortId" :isFixed="isFixed"></tabNav>
|
|
- <!-- 标题 -->
|
|
|
|
|
|
+ <!-- 标题 -->
|
|
<titles v-if="item.name == 'titles'" :dataConfig="item" :isSortType="isSortType"></titles>
|
|
<titles v-if="item.name == 'titles'" :dataConfig="item" :isSortType="isSortType"></titles>
|
|
</block>
|
|
</block>
|
|
<!-- #endif -->
|
|
<!-- #endif -->
|
|
@@ -83,7 +85,7 @@
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</scroll-view>
|
|
</scroll-view>
|
|
- <!-- 首页商品列表 -->
|
|
|
|
|
|
+ <!-- 首页商品列表 -->
|
|
<view class="product-list" v-if="goodList.length">
|
|
<view class="product-list" v-if="goodList.length">
|
|
<view class="product-item" v-for="(item, index) in goodList" @click="goGoodsDetail(item)">
|
|
<view class="product-item" v-for="(item, index) in goodList" @click="goGoodsDetail(item)">
|
|
<image :src="item.image" mode="aspectFill"></image>
|
|
<image :src="item.image" mode="aspectFill"></image>
|
|
@@ -113,7 +115,7 @@
|
|
</view>
|
|
</view>
|
|
<!-- #endif -->
|
|
<!-- #endif -->
|
|
<!-- #ifndef APP-PLUS -->
|
|
<!-- #ifndef APP-PLUS -->
|
|
- <!-- 商品排序 -->
|
|
|
|
|
|
+ <!-- 商品排序 -->
|
|
<view class="sort-product" v-if="isSortType == 1" :style="{ marginTop: sortMpTop + 'px' }">
|
|
<view class="sort-product" v-if="isSortType == 1" :style="{ marginTop: sortMpTop + 'px' }">
|
|
<scroll-view scroll-x="true" class="sort-scroll">
|
|
<scroll-view scroll-x="true" class="sort-scroll">
|
|
<view class="sort-box" v-if="sortList.children && sortList.children.length">
|
|
<view class="sort-box" v-if="sortList.children && sortList.children.length">
|
|
@@ -125,7 +127,7 @@
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</scroll-view>
|
|
</scroll-view>
|
|
- <!-- 首页底部商品列表 -->
|
|
|
|
|
|
+ <!-- 首页底部商品列表 -->
|
|
<view class="product-list" v-if="goodList.length">
|
|
<view class="product-list" v-if="goodList.length">
|
|
<view class="product-item" v-for="(item, index) in goodList" @click="goGoodsDetail(item)">
|
|
<view class="product-item" v-for="(item, index) in goodList" @click="goGoodsDetail(item)">
|
|
<view class="pictrue">
|
|
<view class="pictrue">
|
|
@@ -136,7 +138,8 @@
|
|
v-if="item.activity && item.activity.type === '2'">砍价</span>
|
|
v-if="item.activity && item.activity.type === '2'">砍价</span>
|
|
<span class="pictrue_log_big pictrue_log_class"
|
|
<span class="pictrue_log_big pictrue_log_class"
|
|
v-if="item.activity && item.activity.type === '3'">拼团</span>
|
|
v-if="item.activity && item.activity.type === '3'">拼团</span>
|
|
- <view class="activityFrame" v-if="item.activity_frame.image" :style="'background-image: url('+item.activity_frame.image+');'"></view>
|
|
|
|
|
|
+ <view class="activityFrame" v-if="item.activity_frame.image"
|
|
|
|
+ :style="'background-image: url('+item.activity_frame.image+');'"></view>
|
|
</view>
|
|
</view>
|
|
<view class="info">
|
|
<view class="info">
|
|
<view class="title line1">{{ item.store_name }}</view>
|
|
<view class="title line1">{{ item.store_name }}</view>
|
|
@@ -253,7 +256,7 @@
|
|
getCategoryList,
|
|
getCategoryList,
|
|
getProductslist,
|
|
getProductslist,
|
|
getProductHot,
|
|
getProductHot,
|
|
- diyProduct
|
|
|
|
|
|
+ diyProduct
|
|
} from '@/api/store.js';
|
|
} from '@/api/store.js';
|
|
import {
|
|
import {
|
|
goShopDetail
|
|
goShopDetail
|
|
@@ -261,7 +264,9 @@
|
|
import {
|
|
import {
|
|
toLogin
|
|
toLogin
|
|
} from '@/libs/login.js';
|
|
} from '@/libs/login.js';
|
|
- import {HTTP_REQUEST_URL} from '@/config/app';
|
|
|
|
|
|
+ import {
|
|
|
|
+ HTTP_REQUEST_URL
|
|
|
|
+ } from '@/config/app';
|
|
import pageFooter from '@/components/pageFooter/index.vue';
|
|
import pageFooter from '@/components/pageFooter/index.vue';
|
|
import Loading from '@/components/Loading/index.vue';
|
|
import Loading from '@/components/Loading/index.vue';
|
|
import recommend from '@/components/recommend';
|
|
import recommend from '@/components/recommend';
|
|
@@ -274,7 +279,7 @@
|
|
Loading,
|
|
Loading,
|
|
pageFooter,
|
|
pageFooter,
|
|
couponWindow,
|
|
couponWindow,
|
|
-
|
|
|
|
|
|
+
|
|
// #ifdef H5
|
|
// #ifdef H5
|
|
...mConfig,
|
|
...mConfig,
|
|
// #endif
|
|
// #endif
|
|
@@ -355,9 +360,9 @@
|
|
bgTabVal: '',
|
|
bgTabVal: '',
|
|
pageShow: true,
|
|
pageShow: true,
|
|
windowHeight: 0,
|
|
windowHeight: 0,
|
|
- imgHost:HTTP_REQUEST_URL,
|
|
|
|
|
|
+ imgHost: HTTP_REQUEST_URL,
|
|
// isShowAuth: false,
|
|
// isShowAuth: false,
|
|
- isScrolled:false,
|
|
|
|
|
|
+ isScrolled: false,
|
|
product_video_status: false,
|
|
product_video_status: false,
|
|
confirm_video_status: false
|
|
confirm_video_status: false
|
|
};
|
|
};
|
|
@@ -376,7 +381,7 @@
|
|
state,
|
|
state,
|
|
scope
|
|
scope
|
|
} = options;
|
|
} = options;
|
|
-
|
|
|
|
|
|
+
|
|
this.diyData();
|
|
this.diyData();
|
|
this.getIndexData();
|
|
this.getIndexData();
|
|
// #ifdef H5
|
|
// #ifdef H5
|
|
@@ -413,7 +418,7 @@
|
|
});
|
|
});
|
|
});
|
|
});
|
|
},
|
|
},
|
|
- onUnload(){
|
|
|
|
|
|
+ onUnload() {
|
|
// 清除监听
|
|
// 清除监听
|
|
uni.$off('activeFn');
|
|
uni.$off('activeFn');
|
|
// #ifdef MP
|
|
// #ifdef MP
|
|
@@ -451,7 +456,7 @@
|
|
if (this.cartNum > 0) {
|
|
if (this.cartNum > 0) {
|
|
uni.setTabBarBadge({
|
|
uni.setTabBarBadge({
|
|
index: 3,
|
|
index: 3,
|
|
- text: this.cartNum>99?'99+':this.cartNum+''
|
|
|
|
|
|
+ text: this.cartNum > 99 ? '99+' : this.cartNum + ''
|
|
})
|
|
})
|
|
} else {
|
|
} else {
|
|
uni.hideTabBarRedDot({
|
|
uni.hideTabBarRedDot({
|
|
@@ -463,7 +468,7 @@
|
|
if (this.isLogin) {
|
|
if (this.isLogin) {
|
|
this.getCoupon();
|
|
this.getCoupon();
|
|
}
|
|
}
|
|
- this.getdiyProduct()
|
|
|
|
|
|
+ this.getdiyProduct()
|
|
},
|
|
},
|
|
onReady() {},
|
|
onReady() {},
|
|
methods: {
|
|
methods: {
|
|
@@ -472,29 +477,32 @@
|
|
// authColse: function(e) {
|
|
// authColse: function(e) {
|
|
// this.isShowAuth = e
|
|
// this.isShowAuth = e
|
|
// },
|
|
// },
|
|
- // div商品详情
|
|
|
|
- getdiyProduct() {
|
|
|
|
- diyProduct().then(res=>{
|
|
|
|
- uni.setStorageSync('diyProduct',JSON.stringify(res.data.product_detail))
|
|
|
|
- uni.setStorageSync('product_video_status',JSON.stringify(res.data.product_video_status))
|
|
|
|
- this.$eventHub.$emit('product_video_status', res.data.product_video_status);
|
|
|
|
- this.product_video_status = res.data.product_video_status;
|
|
|
|
- })
|
|
|
|
- },
|
|
|
|
- getCopyRight(){
|
|
|
|
|
|
+ // div商品详情
|
|
|
|
+ getdiyProduct() {
|
|
|
|
+ diyProduct().then(res => {
|
|
|
|
+ uni.setStorageSync('diyProduct', JSON.stringify(res.data.product_detail))
|
|
|
|
+ uni.setStorageSync('product_video_status', JSON.stringify(res.data.product_video_status))
|
|
|
|
+ this.$eventHub.$emit('product_video_status', res.data.product_video_status);
|
|
|
|
+ this.product_video_status = res.data.product_video_status;
|
|
|
|
+ })
|
|
|
|
+ },
|
|
|
|
+ getCopyRight() {
|
|
copyRight().then(res => {
|
|
copyRight().then(res => {
|
|
let data = res.data;
|
|
let data = res.data;
|
|
uni.setStorageSync('wechatStatus', data.wechat_status)
|
|
uni.setStorageSync('wechatStatus', data.wechat_status)
|
|
// #ifndef APP-PLUS
|
|
// #ifndef APP-PLUS
|
|
this.site_config = data.record_No;
|
|
this.site_config = data.record_No;
|
|
// #endif
|
|
// #endif
|
|
- if(!data.copyrightContext && !data.copyrightImage){
|
|
|
|
|
|
+ if (!data.copyrightContext && !data.copyrightImage) {
|
|
data.copyrightImage = '/static/images/support.png'
|
|
data.copyrightImage = '/static/images/support.png'
|
|
}
|
|
}
|
|
uni.setStorageSync('copyNameInfo', data.copyrightContext);
|
|
uni.setStorageSync('copyNameInfo', data.copyrightContext);
|
|
uni.setStorageSync('copyImageInfo', data.copyrightImage);
|
|
uni.setStorageSync('copyImageInfo', data.copyrightImage);
|
|
// #ifdef MP
|
|
// #ifdef MP
|
|
- uni.setStorageSync('MPSiteData', JSON.stringify({site_logo:data.site_logo,site_name:data.site_name}));
|
|
|
|
|
|
+ uni.setStorageSync('MPSiteData', JSON.stringify({
|
|
|
|
+ site_logo: data.site_logo,
|
|
|
|
+ site_name: data.site_name
|
|
|
|
+ }));
|
|
// #endif
|
|
// #endif
|
|
}).catch(err => {
|
|
}).catch(err => {
|
|
return this.$util.Tips({
|
|
return this.$util.Tips({
|
|
@@ -502,16 +510,20 @@
|
|
});
|
|
});
|
|
});
|
|
});
|
|
},
|
|
},
|
|
- getOptions(options){
|
|
|
|
|
|
+ getOptions(options) {
|
|
let that = this;
|
|
let that = this;
|
|
// #ifdef MP
|
|
// #ifdef MP
|
|
if (options.scene) {
|
|
if (options.scene) {
|
|
let value = that.$util.getUrlParams(decodeURIComponent(options.scene));
|
|
let value = that.$util.getUrlParams(decodeURIComponent(options.scene));
|
|
//记录推广人uid
|
|
//记录推广人uid
|
|
- if (value.spid) app.globalData.spid = value.spid;
|
|
|
|
|
|
+ if (value.spid) {
|
|
|
|
+ app.globalData.spid = value.spid;
|
|
|
|
+ }
|
|
}
|
|
}
|
|
// #endif
|
|
// #endif
|
|
- if (options.spid) app.globalData.spid = options.spid;
|
|
|
|
|
|
+ if (options.spid) {
|
|
|
|
+ app.globalData.spid = options.spid;
|
|
|
|
+ }
|
|
},
|
|
},
|
|
// 重新链接
|
|
// 重新链接
|
|
reconnect() {
|
|
reconnect() {
|
|
@@ -616,7 +628,7 @@
|
|
});
|
|
});
|
|
}
|
|
}
|
|
},
|
|
},
|
|
- // 商品列表
|
|
|
|
|
|
+ // 商品列表
|
|
getGoodsList() {
|
|
getGoodsList() {
|
|
if (this.loading || this.loaded) return;
|
|
if (this.loading || this.loaded) return;
|
|
this.loading = true;
|
|
this.loading = true;
|
|
@@ -755,7 +767,7 @@
|
|
}
|
|
}
|
|
temp = arr;
|
|
temp = arr;
|
|
});
|
|
});
|
|
-
|
|
|
|
|
|
+
|
|
function sortNumber(a, b) {
|
|
function sortNumber(a, b) {
|
|
return a.timestamp - b.timestamp;
|
|
return a.timestamp - b.timestamp;
|
|
}
|
|
}
|
|
@@ -791,12 +803,12 @@
|
|
let diyVersion = uni.getStorageSync('diyVersion');
|
|
let diyVersion = uni.getStorageSync('diyVersion');
|
|
if ((res.data.version + '0') === diyVersion) {
|
|
if ((res.data.version + '0') === diyVersion) {
|
|
this.setDiyData(JSON.parse(diyData));
|
|
this.setDiyData(JSON.parse(diyData));
|
|
- } else{
|
|
|
|
|
|
+ } else {
|
|
uni.setStorageSync('diyVersion', (res.data.version + '0'));
|
|
uni.setStorageSync('diyVersion', (res.data.version + '0'));
|
|
this.getDiyData();
|
|
this.getDiyData();
|
|
}
|
|
}
|
|
});
|
|
});
|
|
- } else{
|
|
|
|
|
|
+ } else {
|
|
this.getDiyData();
|
|
this.getDiyData();
|
|
}
|
|
}
|
|
// getDiy(0).then(res => {
|
|
// getDiy(0).then(res => {
|
|
@@ -835,7 +847,7 @@
|
|
// }
|
|
// }
|
|
// temp = arr;
|
|
// temp = arr;
|
|
// });
|
|
// });
|
|
-
|
|
|
|
|
|
+
|
|
// function sortNumber(a, b) {
|
|
// function sortNumber(a, b) {
|
|
// return a.timestamp - b.timestamp;
|
|
// return a.timestamp - b.timestamp;
|
|
// }
|
|
// }
|
|
@@ -880,14 +892,14 @@
|
|
// 微信分享;
|
|
// 微信分享;
|
|
setOpenShare: function() {
|
|
setOpenShare: function() {
|
|
let that = this;
|
|
let that = this;
|
|
- let uid = this.uid?this.uid:0;
|
|
|
|
|
|
+ let uid = this.uid ? this.uid : 0;
|
|
if (that.$wechat.isWeixin()) {
|
|
if (that.$wechat.isWeixin()) {
|
|
getShare().then(res => {
|
|
getShare().then(res => {
|
|
let data = res.data;
|
|
let data = res.data;
|
|
let configAppMessage = {
|
|
let configAppMessage = {
|
|
desc: data.synopsis,
|
|
desc: data.synopsis,
|
|
title: data.title,
|
|
title: data.title,
|
|
- link: location.href+'?spid='+uid,
|
|
|
|
|
|
+ link: location.href + '?spid=' + uid,
|
|
imgUrl: data.img
|
|
imgUrl: data.img
|
|
};
|
|
};
|
|
that.$wechat.wechatEvevt(['updateAppMessageShareData', 'updateTimelineShareData',
|
|
that.$wechat.wechatEvevt(['updateAppMessageShareData', 'updateTimelineShareData',
|
|
@@ -900,8 +912,7 @@
|
|
// #endif
|
|
// #endif
|
|
},
|
|
},
|
|
onReachBottom: function() {
|
|
onReachBottom: function() {
|
|
- if (this.isSortType == 0) {
|
|
|
|
- } else {
|
|
|
|
|
|
+ if (this.isSortType == 0) {} else {
|
|
this.getGoodsList();
|
|
this.getGoodsList();
|
|
}
|
|
}
|
|
},
|
|
},
|
|
@@ -920,18 +931,18 @@
|
|
this.isFixed = false
|
|
this.isFixed = false
|
|
}
|
|
}
|
|
// #endif
|
|
// #endif
|
|
- if(e.scrollTop>10){
|
|
|
|
|
|
+ if (e.scrollTop > 10) {
|
|
this.isScrolled = true;
|
|
this.isScrolled = true;
|
|
- }else{
|
|
|
|
|
|
+ } else {
|
|
this.isScrolled = false;
|
|
this.isScrolled = false;
|
|
}
|
|
}
|
|
},
|
|
},
|
|
//#ifdef MP
|
|
//#ifdef MP
|
|
onShareAppMessage() {
|
|
onShareAppMessage() {
|
|
- let uid = this.uid?this.uid:0;
|
|
|
|
|
|
+ let uid = this.uid ? this.uid : 0;
|
|
return {
|
|
return {
|
|
title: this.shareInfo.title,
|
|
title: this.shareInfo.title,
|
|
- path: '/pages/index/index?spid='+uid,
|
|
|
|
|
|
+ path: '/pages/index/index?spid=' + uid,
|
|
imageUrl: this.shareInfo.img,
|
|
imageUrl: this.shareInfo.img,
|
|
desc: this.shareInfo.synopsis
|
|
desc: this.shareInfo.synopsis
|
|
};
|
|
};
|
|
@@ -1089,9 +1100,11 @@
|
|
border-radius: 120rpx;
|
|
border-radius: 120rpx;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
-.sort-scroll {
|
|
|
|
- background-color: #fff;
|
|
|
|
-}
|
|
|
|
|
|
+
|
|
|
|
+ .sort-scroll {
|
|
|
|
+ background-color: #fff;
|
|
|
|
+ }
|
|
|
|
+
|
|
.sort-product {
|
|
.sort-product {
|
|
margin-top: 20rpx;
|
|
margin-top: 20rpx;
|
|
|
|
|
|
@@ -1164,8 +1177,8 @@
|
|
border-radius: 10rpx;
|
|
border-radius: 10rpx;
|
|
margin-bottom: 20rpx;
|
|
margin-bottom: 20rpx;
|
|
overflow: hidden;
|
|
overflow: hidden;
|
|
-
|
|
|
|
- .pictrue{
|
|
|
|
|
|
+
|
|
|
|
+ .pictrue {
|
|
position: relative;
|
|
position: relative;
|
|
}
|
|
}
|
|
|
|
|
|
@@ -1200,10 +1213,12 @@
|
|
.empty-box {
|
|
.empty-box {
|
|
text-align: center;
|
|
text-align: center;
|
|
padding-top: 50rpx;
|
|
padding-top: 50rpx;
|
|
- .tips{
|
|
|
|
|
|
+
|
|
|
|
+ .tips {
|
|
color: #aaa;
|
|
color: #aaa;
|
|
font-size: 26rpx;
|
|
font-size: 26rpx;
|
|
}
|
|
}
|
|
|
|
+
|
|
image {
|
|
image {
|
|
width: 414rpx;
|
|
width: 414rpx;
|
|
height: 304rpx;
|
|
height: 304rpx;
|
|
@@ -1223,4 +1238,4 @@
|
|
width: 100%;
|
|
width: 100%;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
-</style>
|
|
|
|
|
|
+</style>
|