|
@@ -108,11 +108,11 @@
|
|
|
<view class="tab-content" v-show="current >= 1">
|
|
|
<!-- 轮播 -->
|
|
|
<view class="swiper-group">
|
|
|
- <u-swiper :list="swiperTabList" indicator indicatorMode="line" circular></u-swiper>
|
|
|
+ <u-swiper :list="swiperTabList.length == 0?swiperList:swiperTabList" indicator indicatorMode="line" circular></u-swiper>
|
|
|
</view>
|
|
|
<!-- 商品列表 -->
|
|
|
<goodListMall @changeTab="changeTab" :iSshowH="true" @detail="goDetail" :currentId="currentId"
|
|
|
- :isSortType="isSortType"></goodListMall>
|
|
|
+ :isSortType="isSortType" ref="goodTablist"></goodListMall>
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
@@ -706,6 +706,18 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
|
+ pullResh(){
|
|
|
+ if(this.current == 0){
|
|
|
+ uni.showLoading({ title: '刷新中' });
|
|
|
+ this.getNoticeList()
|
|
|
+ this.getAdsList()
|
|
|
+ this.getBroGoodsInfo()
|
|
|
+ this.getAdsTabList()
|
|
|
+ this.getGoodsInfo()
|
|
|
+ }else{
|
|
|
+ this.$refs.goodTablist.getGoodsPage()
|
|
|
+ }
|
|
|
+ },
|
|
|
getGoodsInfo() {
|
|
|
getGoodsInfo({
|
|
|
current: 1,
|
|
@@ -713,6 +725,8 @@ export default {
|
|
|
isRecom: 1
|
|
|
}).then(res => {
|
|
|
this.tempArr = res.data
|
|
|
+ uni.stopPullDownRefresh()
|
|
|
+ uni.hideLoading();
|
|
|
})
|
|
|
},
|
|
|
getBroGoodsInfo() {
|
|
@@ -777,8 +791,8 @@ export default {
|
|
|
getAdsList({
|
|
|
type: 7
|
|
|
}).then(res => {
|
|
|
+ this.swiperTabList = []
|
|
|
if (res.data.length > 0) {
|
|
|
- this.swiperTabList = []
|
|
|
res.data.forEach(element => {
|
|
|
this.swiperTabList.push(element.imageUrl)
|
|
|
});
|