Эх сурвалжийг харах

Signed-off-by: liuboyan <632697560@qq.com>
bug

liuboyan 4 жил өмнө
parent
commit
9c7455a260

+ 11 - 6
pagesGood/shopDetails.vue

@@ -1,5 +1,5 @@
 <template>
-	<scroll-view id="shopBox" class="container" scroll-y="true">
+	<scroll-view id="shopBox" class="container" scroll-y="true" @scrolltolower="handleLoadMore()">
 		<view class="shop-bg"></view>
 		<view class="shop-info">
 			<view class="shop-icon">
@@ -9,7 +9,8 @@
 			<view class="shop-sell">已售商品{{shopData.soldCount}}</view>
 		</view>
 		<view class="shop-image" :style="{height: (swiperHeight / 2 + 30)+'px'}">
-			<swiper class="swiper" :style="{height: (swiperHeight / 2)+'px'}" :indicator-dots="false" :autoplay="true" :interval="3000" :duration="500">
+			<swiper class="swiper" :style="{height: (swiperHeight / 2)+'px'}" :indicator-dots="false" :autoplay="true" :interval="3000"
+			 :duration="500">
 				<swiper-item v-for="(item,index) in shopData.storeImgUrl" :key="index">
 					<image :src="item" mode="aspectFill" style="width: 100%;height: 100%;border-radius: 10px;" :style="{height: (swiperHeight / 2)+'px'}"></image>
 				</swiper-item>
@@ -26,7 +27,7 @@
 				<u-dropdown-item v-model="goodSort" title="销量" :options="options3" @change="changeSort()"></u-dropdown-item>
 			</u-dropdown>
 		</view>
-		<scroll-view class="shop-all-goods" v-show="!tabIndex" scroll-y="true" @scrolltolower="handleLoadMore()">
+		<view class="shop-all-goods" v-show="!tabIndex">
 			<view class="goods-row" v-for="(item,index) in allGoodsList" :key="index" @click="goToGoodDetails(item)">
 				<image class="goods-img" :src="item.imgPath" mode="aspectFill"></image>
 				<view class="goods-info">
@@ -40,7 +41,7 @@
 					</text>
 				</view>
 			</view>
-		</scroll-view>
+		</view>
 		<view class="shop-category" v-show="tabIndex">
 			<view class="category-col" v-for="(item,index) in categoryList" :key="index" :style="{width: item.width + '%'}">
 				<view class="category-button" :class="selectSort == item.productCategoryId ? 'category-button-active' : ''" :id="'categoryCol'+index"
@@ -176,7 +177,6 @@
 			},
 			//  懒加载
 			handleLoadMore() {
-				debugger
 				if (this.tabIndex == 0) {
 					if (!this.isOver1) {
 						this.pageIndex1++
@@ -249,7 +249,12 @@
 		},
 	}
 </script>
-
+<style>
+	page {
+		width: 100%;
+		height: 100%;
+	}
+</style>
 <style lang="less" scoped>
 	page {
 		width: 100%;