Kaynağa Gözat

Merge branch 'master' of http://git.liuniu946.com/hwq/mnsx

hwq 2 yıl önce
ebeveyn
işleme
93007d4939
3 değiştirilmiş dosya ile 449 ekleme ve 360 silme
  1. 64 15
      pages/index/Vipgift.vue
  2. 0 1
      pages/index/index.vue
  3. 385 344
      pages/product/search.vue

+ 64 - 15
pages/index/Vipgift.vue

@@ -1,44 +1,55 @@
 <template>
 	<view class="content padding-t-20">
-		<view class="flex item padding-v-20 padding-c-20">
+		<view class="flex item padding-v-20 padding-c-20" v-for="(item,index) in goodsList">
 			<view class="imgbox">
-				<image class="img" src="" mode="scaleToFill"></image>
+				<image class="img" :src="item.image" mode="scaleToFill"></image>
 			</view>
 			<view class="contentbox padding-l-20 flex">
 				<view class="clamp2 title">
-					法国空运高端82年拉菲陈酿 红葡萄酒...
+					{{item.store_name}}
 				</view>
 				<view class="oldMoneyBox ">
 					<view class="flex-start padding-b-10">
-						<text class="oldMoney">¥200</text>
+						<text class="oldMoney">¥{{item.price}}</text>
 						<image class="icon padding-l-10" src="../../static/img/domIcon.png" mode="scaleToFill"></image>
 						<text class="domMoney font-size-sm">
-							直降40
+							直降{{item.sales}}
 						</text>
 					</view>
 					<view class="flex">
-						<view class="money">¥200</view>
-						<view class="buttomPay">立即购买</view>
+						<view class="money">¥{{item.price}}</view>
+						<view class="buttomPay" @click="navto('/')">立即购买</view>
 					</view>
 				</view>
 			</view>
 		</view>
+		<uni-load-more :status="loadingType"></uni-load-more>
 	</view>
 </template>
 
 <script>
+	import {
+		getProducts
+	} from '@/api/product.js';
 	export default {
 		data() {
 			return {
-				
-				
-				
+				// 列表
+				goodsList: [],
+				limit: 6, //每次加载数据条数
+				page: 1, //当前页数
+				loadingType: 'more', //加载更多状态
+
+
 			};
 		},
-		onLoad() {},
+		onLoad() {
+			this.getProducts();
+		},
 		onShow() {},
-		onReachBottom() {},
-		onReady() {},
+		onPullDownRefresh() {
+			this.getProducts('refresh');
+		},
 		methods: {
 			navto(url) {
 				// #ifdef H5
@@ -51,8 +62,43 @@
 				uni.navigateTo({
 					url: url
 				});
-			}
-			
+			},
+			async getProducts(type) {
+				let obj = this;
+				// 判断是否为重新加载数据
+				if (type !== 'refresh') {
+					//没有更多数据直接跳出方法
+					if (obj.loadingType === 'nomore') {
+						return;
+					}
+					if (obj.loadingType === 'loading') {
+						//防止重复加载
+						return;
+					}
+					// 设置当前为数据载入中
+					obj.loadingType = 'loading';
+				} else {
+					this.page = 1;
+					obj.goodsList = [];
+					//当重新加载数据时更新状态为可继续添加数据
+					obj.loadingType = 'more';
+				}
+				let data = {
+					page: obj.page,
+					limit: obj.limit,
+				};
+				getProducts(data).then(e => {
+					obj.goodsList = obj.goodsList.concat(e.data);
+					//判断是否还有下一页,有是more  没有是nomore
+					if (obj.limit == e.data.length) {
+						obj.page++;
+						obj.loadingType = 'more';
+					} else {
+						obj.loadingType = 'nomore';
+					}
+				});
+			},
+
 		}
 	};
 </script>
@@ -73,8 +119,11 @@
 		line-height: 1;
 
 		.imgbox {
+			line-height: 0;
 			background-color: #EE2F72;
 			border-radius: 10rpx;
+			overflow: hidden;
+			flex-shrink: 0;
 			.img {
 				height: 246rpx;
 				width: 246rpx;

+ 0 - 1
pages/index/index.vue

@@ -17,7 +17,6 @@
 					</view>
 				</view>
 				<view class="config text-white ">某娘粉丝</view>
-				s
 			</view>
 			<view class="upVipBox flex margin-t-20" @click="navto(item.url)">
 				<image class="upViewTip" src="../../static/img/indexUpVipIcon.png" mode="scaleToFill"></image>

+ 385 - 344
pages/product/search.vue

@@ -26,23 +26,30 @@
 					<view class="nav-item" :class="{ current: searchType === 1 }" @click="sortTab(1)">
 						<text>销量优先</text>
 						<view class="p-box">
-							<text :class="{ active: searchType === 1 && numberOrder === 1 }" class="iconfont iconfold"></text>
-							<text :class="{ active: searchType === 1 && numberOrder === 2 }" class="iconfont iconfold xia"></text>
+							<text :class="{ active: searchType === 1 && numberOrder === 1 }"
+								class="iconfont iconfold"></text>
+							<text :class="{ active: searchType === 1 && numberOrder === 2 }"
+								class="iconfont iconfold xia"></text>
 						</view>
 					</view>
 					<view class="nav-item" :class="{ current: searchType === 2 }" @click="sortTab(2)">
 						<text>价格</text>
 						<view class="p-box">
-							<text :class="{ active: searchType === 2 && priceOrder === 1 }" class="iconfont iconfold"></text>
-							<text :class="{ active: searchType === 2 && priceOrder === 2 }" class="iconfont iconfold xia"></text>
+							<text :class="{ active: searchType === 2 && priceOrder === 1 }"
+								class="iconfont iconfold"></text>
+							<text :class="{ active: searchType === 2 && priceOrder === 2 }"
+								class="iconfont iconfold xia"></text>
 						</view>
 					</view>
 					<view class="nav-item" :class="{ current: newOrder == 1 }" @click="newGoodsTab()">新品</view>
 				</view>
 				<scroll-view scroll-y class="cate-list" @scrolltolower='getProducts'>
 					<view class="guess-section">
-						<view v-for="(item, index) in goodsList" :key="index" class="guess-item" @click="navToDetailPage(item)">
-							<view class="image-wrapper"><image :src="item.image" mode="aspectFill"></image></view>
+						<view v-for="(item, index) in goodsList" :key="index" class="guess-item"
+							@click="navToDetailPage(item)">
+							<view class="image-wrapper">
+								<image :src="item.image" mode="aspectFill"></image>
+							</view>
 							<text class="title clamp margin-c-20">{{ item.store_name }}</text>
 							<view class="cmy-hr"></view>
 							<view class="price margin-c-20 flex">
@@ -64,389 +71,423 @@
 </template>
 
 <script>
-import uniLoadMore from '@/components/uni-load-more/uni-load-more.vue';
-import { searchKeyword, getProducts } from '@/api/product.js';
-export default {
-	components: {
-		uniLoadMore
-	},
-	data() {
-		return {
-			arrlist: [], //热门关键词
-			keyword: '', //关键字
-			list: [], //搜索内容
-			tabCurrentIndex: 0, //切换
-			goodsList: [],
-			limit: 6, //每次加载数据条数
-			page: 1, //当前页数
-			loadingType: 'more', //加载更多状态
-			numberOrder: 1, //1 销量从低到高 2销量从高到低
-			priceOrder: 1, //1 价格从低到高 2价格从高到低
-			newOrder: 0, //0 不是新品 1是新品
-			searchType: 0 //0为默认查询 1为销量 2 为价格
-		};
-	},
-	// #ifndef MP
-	//点击导航栏 buttons 时触发
-	onNavigationBarButtonTap(e) {
-		const index = e.index;
-		if (index === 0) {
+	import uniLoadMore from '@/components/uni-load-more/uni-load-more.vue';
+	import {
+		searchKeyword,
+		getProducts
+	} from '@/api/product.js';
+	export default {
+		components: {
+			uniLoadMore
+		},
+		data() {
+			return {
+				arrlist: [], //热门关键词
+				keyword: '', //关键字
+				list: [], //搜索内容
+				tabCurrentIndex: 0, //切换
+				goodsList: [],
+				limit: 6, //每次加载数据条数
+				page: 1, //当前页数
+				loadingType: 'more', //加载更多状态
+				numberOrder: 1, //1 销量从低到高 2销量从高到低
+				priceOrder: 1, //1 价格从低到高 2价格从高到低
+				newOrder: 0, //0 不是新品 1是新品
+				searchType: 0 //0为默认查询 1为销量 2 为价格
+			};
+		},
+		// #ifndef MP
+		//点击导航栏 buttons 时触发
+		onNavigationBarButtonTap(e) {
+			const index = e.index;
+			if (index === 0) {
+				this.navTo();
+			}
+		},
+		// 点击键盘搜索事件
+		onNavigationBarSearchInputConfirmed(e) {
 			this.navTo();
-		}
-	},
-	// 点击键盘搜索事件
-	onNavigationBarSearchInputConfirmed(e) {
-		this.navTo();
-	},
-	// 搜索栏内容变化事件
-	onNavigationBarSearchInputChanged(e) {
-		this.keyword = e.text;
-	},
-	// #endif
-	onLoad() {
-		this.loadData();
-	},
-	//下拉刷新
+		},
+		// 搜索栏内容变化事件
+		onNavigationBarSearchInputChanged(e) {
+			this.keyword = e.text;
+		},
+		// #endif
+		onLoad() {
+			this.loadData();
+		},
+		//下拉刷新
 		onPullDownRefresh() {
-			this.page = 1
 			this.getProducts('refresh');
 		},
-	methods: {
-		// 加载商品
-		async getProducts(type, loading) {
-			let obj = this;
-			// 判断是否为加载数据
-			if (type !== 'refresh') {
-				//没有更多数据直接跳出方法
-				if (obj.loadingType === 'nomore') {
-					return;
-				} else {
+		methods: {
+			// 加载商品
+			async getProducts(type, loading) {
+				let obj = this;
+				// 判断是否为加载数据
+				if (type !== 'refresh') {
+					//没有更多数据直接跳出方法
+					if (obj.loadingType === 'nomore') {
+						return;
+					}
+					if (navItem.loadingType === 'loading') {
+						//防止重复加载
+						return;
+					}
 					// 设置当前为数据载入中
 					obj.loadingType = 'loading';
-				}
-			} else {
-				//当重新加载数据时更新状态为可继续添加数据
-				obj.loadingType = 'more';
-			}
-			let data = {
-				page: obj.page,
-				limit: obj.limit,
-				news: obj.newOrder,
-				keyword: this.keyword
-			};
-			// 判断是否为销售数量排序
-			if (this.searchType === 1) {
-				data.salesOrder = obj.numberOrder === 1 ? 'asc' : 'desc';
-			}
-			// 判断是否为金额排序
-			if (this.searchType === 2) {
-				data.priceOrder = obj.priceOrder === 1 ? 'asc' : 'desc';
-			}
-			getProducts(data).then(e => {
-				if (type === 'refresh') {
+				} else {
+					this.page = 1
 					obj.goodsList = [];
-				}
-				obj.goodsList = obj.goodsList.concat(e.data);
-				//判断是否还有下一页,有是more  没有是nomore
-				if (obj.limit == e.data.length) {
-					obj.page++;
+					//当重新加载数据时更新状态为可继续添加数据
 					obj.loadingType = 'more';
-				} else {
-					obj.loadingType = 'nomore';
 				}
-				// 判断是否为刷新数据
-				if (type === 'refresh') {
-					// 判断是否为点击搜索按钮跳转加载
-					if (loading == 1) {
-						uni.hideLoading();
+				let data = {
+					page: obj.page,
+					limit: obj.limit,
+					news: obj.newOrder,
+					keyword: this.keyword
+				};
+				// 判断是否为销售数量排序
+				if (this.searchType === 1) {
+					data.salesOrder = obj.numberOrder === 1 ? 'asc' : 'desc';
+				}
+				// 判断是否为金额排序
+				if (this.searchType === 2) {
+					data.priceOrder = obj.priceOrder === 1 ? 'asc' : 'desc';
+				}
+				getProducts(data).then(e => {
+					obj.goodsList = obj.goodsList.concat(e.data);
+					//判断是否还有下一页,有是more  没有是nomore
+					if (obj.limit == e.data.length) {
+						obj.page++;
+						obj.loadingType = 'more';
 					} else {
-						uni.stopPullDownRefresh();
+						obj.loadingType = 'nomore';
 					}
+					// 判断是否为刷新数据
+					if (type === 'refresh') {
+						// 判断是否为点击搜索按钮跳转加载
+						if (loading == 1) {
+							uni.hideLoading();
+						} else {
+							uni.stopPullDownRefresh();
+						}
+					}
+				});
+			},
+			// 点击关键词触发事件
+			clickHotText(e) {
+				this.keyword = e;
+				this.navTo();
+			},
+			// 加载搜索关键字
+			async loadData() {
+				searchKeyword({})
+					.then(e => {
+						this.list = e.data;
+					})
+					.catch(e => {
+						console.log(e);
+					});
+			},
+			// 点击触发搜索事件
+			navTo() {
+				this.tabCurrentIndex = 1;
+				this.infoData()
+			},
+			// 默认搜索
+			defaultSearch() {
+				// 初始化查询
+				this.numberOrder = '';
+				this.priceOrder = '';
+				this.newOrder = 0;
+				this.searchType = 0;
+				this.infoData();
+			},
+			// 是否为新品
+			newGoodsTab() {
+				this.newOrder = this.newOrder === 1 ? 0 : 1;
+				this.infoData();
+			},
+			// 排序
+			sortTab(nub) {
+				this.searchType = nub;
+				if (this.searchType === 1) {
+					this.numberOrder = this.numberOrder === 1 ? 2 : 1;
 				}
-			});
-		},
-		// 点击关键词触发事件
-		clickHotText(e) {
-			this.keyword = e;
-			this.navTo();
-		},
-		// 加载搜索关键字
-		async loadData() {
-			searchKeyword({})
-				.then(e => {
-					this.list = e.data;
-				})
-				.catch(e => {
-					console.log(e);
+				if (this.searchType === 2) {
+					this.priceOrder = this.priceOrder === 1 ? 2 : 1;
+				}
+				this.infoData();
+			},
+			// 查询切换后初始化
+			infoData() {
+				// 初始化页数
+				this.page = 1;
+				// 初始化数组
+				uni.pageScrollTo({
+					duration: 300,
+					scrollTop: 0
+				});
+				// 加载数据
+				this.getProducts('refresh', 1);
+				uni.showLoading({
+					title: '正在加载'
+				});
+			},
+			navToDetailPage(item) {
+				//测试数据没有写id,用title代替
+				let id = item.id;
+				uni.navigateTo({
+					url: '/pages/product/product?id=' + id
 				});
-		},
-		// 点击触发搜索事件
-		navTo() {
-			this.tabCurrentIndex = 1;
-			this.infoData()
-		},
-		// 默认搜索
-		defaultSearch() {
-			// 初始化查询
-			this.numberOrder = '';
-			this.priceOrder = '';
-			this.newOrder = 0;
-			this.searchType = 0;
-			this.infoData();
-		},
-		// 是否为新品
-		newGoodsTab() {
-			this.newOrder = this.newOrder === 1 ? 0 : 1;
-			this.infoData();
-		},
-		// 排序
-		sortTab(nub) {
-			this.searchType = nub;
-			if (this.searchType === 1) {
-				this.numberOrder = this.numberOrder === 1 ? 2 : 1;
-			}
-			if (this.searchType === 2) {
-				this.priceOrder = this.priceOrder === 1 ? 2 : 1;
 			}
-			this.infoData();
-		},
-		// 查询切换后初始化
-		infoData() {
-			// 初始化页数
-			this.page = 1;
-			// 初始化数组
-			uni.pageScrollTo({
-				duration: 300,
-				scrollTop: 0
-			});
-			// 加载数据
-			this.getProducts('refresh', 1);
-			uni.showLoading({
-				title: '正在加载'
-			});
-		},
-		navToDetailPage(item) {
-			//测试数据没有写id,用title代替
-			let id = item.id;
-			uni.navigateTo({
-				url: '/pages/product/product?id=' + id
-			});
 		}
-	}
-};
+	};
 </script>
 
 <style lang="scss">
-page,
-.content {
-	height: 100%;
-	background-color: $page-color-base;
-}
-/* #ifdef MP || APP-PLUS */
-.vheight{
-	height: var(--status-bar-height);
-	background-color: #FFFFFF;
-}
-.input-box {
-	padding: 25rpx;
-	background-color: #ffffff;
-	height: 44px;
-	.iconsearch {
-		font-size: 50rpx;
-	}
-	.input-content {
-		border-radius: 99rpx;
-		flex-grow: 1;
-		padding: 10rpx 30rpx;
-		background-color: rgba(231, 231, 231, 0.7);
-		.input {
-			flex-grow: 1;
-			input {
-				font-size: $font-lg;
-			}
-		}
-	}
-	.input-button {
-		padding-left: 20rpx;
-		font-size: $font-lg;
+	page,
+	.content {
 		height: 100%;
+		background-color: $page-color-base;
 	}
-}
-/* #endif */
 
-.swiper-box {
-	/* #ifndef MP */
-	height: 100%;
-	/* #endif */
-	/* #ifdef MP */
-	height: calc(100% - 44px);
-	/* #endif */
-	.search-hot {
+	/* #ifdef MP || APP-PLUS */
+	.vheight {
+		height: var(--status-bar-height);
+		background-color: #FFFFFF;
+	}
+
+	.input-box {
 		padding: 25rpx;
-		.title {
-			font-size: $font-lg;
-			color: $font-color-light;
+		background-color: #ffffff;
+		height: 44px;
+
+		.iconsearch {
+			font-size: 50rpx;
 		}
-		.hot-list {
-			display: flex;
-			flex-wrap: wrap;
-			margin-top: 30rpx;
-			.list-item {
-				padding: 10rpx 20rpx;
-				border: 1px solid $border-color-dark;
-				color: $font-color-dark;
-				font-size: $font-base;
-				margin-right: 20rpx;
-				margin-bottom: 20rpx;
+
+		.input-content {
+			border-radius: 99rpx;
+			flex-grow: 1;
+			padding: 10rpx 30rpx;
+			background-color: rgba(231, 231, 231, 0.7);
+
+			.input {
+				flex-grow: 1;
+
+				input {
+					font-size: $font-lg;
+				}
 			}
 		}
-	}
-}
-
-// 订单
-%icon {
-	margin-right: 10rpx;
-	display: inline-block;
-	padding: 2rpx 10rpx;
-	border: 1rpx solid $color-yellow;
-	color: $color-yellow;
-	line-height: 1;
-	font-size: $font-base;
-	border-radius: 10rpx;
-}
-.guess-section {
-	display: flex;
-	flex-wrap: wrap;
-	.guess-item {
-		overflow: hidden;
-		display: flex;
-		flex-direction: column;
-		width: 48%;
-		margin-bottom: 4%;
-		border-radius: $border-radius-sm;
-		background-color: white;
-		box-shadow: $box-shadow;
-		&:nth-child(2n + 1) {
-			margin-right: 4%;
-		}
-	}
-	.image-wrapper {
-		width: 100%;
-		height: 330rpx;
-		border-radius: 3px;
-		overflow: hidden;
-		image {
-			width: 100%;
+
+		.input-button {
+			padding-left: 20rpx;
+			font-size: $font-lg;
 			height: 100%;
-			opacity: 1;
 		}
 	}
-	.title {
-		font-size: $font-base;
-		color: $font-color-dark;
-		font-weight: bold;
-		line-height: 80rpx;
-	}
-	.price {
-		font-size: $font-lg;
-		color: $font-color-base;
-		font-weight: bold;
-		line-height: 1;
-		line-height: 80rpx;
-	}
 
-	.icon {
-		@extend %icon;
+	/* #endif */
+
+	.swiper-box {
+		/* #ifndef MP */
+		height: 100%;
+		/* #endif */
+		/* #ifdef MP */
+		height: calc(100% - 44px);
+
+		/* #endif */
+		.search-hot {
+			padding: 25rpx;
+
+			.title {
+				font-size: $font-lg;
+				color: $font-color-light;
+			}
+
+			.hot-list {
+				display: flex;
+				flex-wrap: wrap;
+				margin-top: 30rpx;
+
+				.list-item {
+					padding: 10rpx 20rpx;
+					border: 1px solid $border-color-dark;
+					color: $font-color-dark;
+					font-size: $font-base;
+					margin-right: 20rpx;
+					margin-bottom: 20rpx;
+				}
+			}
+		}
 	}
 
-	.detail {
+	// 订单
+	%icon {
+		margin-right: 10rpx;
+		display: inline-block;
+		padding: 2rpx 10rpx;
+		border: 1rpx solid $color-yellow;
+		color: $color-yellow;
 		line-height: 1;
+		font-size: $font-base;
+		border-radius: 10rpx;
 	}
-	.tip {
-		color: white;
-		background-color: $color-yellow;
-		line-height: 1.5;
-		font-size: $font-sm;
-		padding-left: 20rpx;
-	}
-}
-
-.navbar {
-	position: absolute;
-	top: 0;
-	left: 0;
-	display: flex;
-	width: 100%;
-	height: 40px;
-	background: #fff;
-	box-shadow: 0 2rpx 10rpx rgba(0, 0, 0, 0.06);
-	z-index: 10;
-	.nav-item {
-		flex: 1;
+
+	.guess-section {
 		display: flex;
-		justify-content: center;
-		align-items: center;
-		height: 100%;
-		font-size: 30rpx;
-		color: $font-color-dark;
-		position: relative;
-		&.current {
-			color: $base-color;
-			&:after {
-				content: '';
-				position: absolute;
-				left: 50%;
-				bottom: 0;
-				transform: translateX(-50%);
-				width: 120rpx;
-				height: 0;
-				border-bottom: 4rpx solid $base-color;
+		flex-wrap: wrap;
+
+		.guess-item {
+			overflow: hidden;
+			display: flex;
+			flex-direction: column;
+			width: 48%;
+			margin-bottom: 4%;
+			border-radius: $border-radius-sm;
+			background-color: white;
+			box-shadow: $box-shadow;
+
+			&:nth-child(2n + 1) {
+				margin-right: 4%;
 			}
 		}
+
+		.image-wrapper {
+			width: 100%;
+			height: 330rpx;
+			border-radius: 3px;
+			overflow: hidden;
+
+			image {
+				width: 100%;
+				height: 100%;
+				opacity: 1;
+			}
+		}
+
+		.title {
+			font-size: $font-base;
+			color: $font-color-dark;
+			font-weight: bold;
+			line-height: 80rpx;
+		}
+
+		.price {
+			font-size: $font-lg;
+			color: $font-color-base;
+			font-weight: bold;
+			line-height: 1;
+			line-height: 80rpx;
+		}
+
+		.icon {
+			@extend %icon;
+		}
+
+		.detail {
+			line-height: 1;
+		}
+
+		.tip {
+			color: white;
+			background-color: $color-yellow;
+			line-height: 1.5;
+			font-size: $font-sm;
+			padding-left: 20rpx;
+		}
 	}
-	.p-box {
+
+	.navbar {
+		position: absolute;
+		top: 0;
+		left: 0;
 		display: flex;
-		flex-direction: column;
-		.iconfont {
+		width: 100%;
+		height: 40px;
+		background: #fff;
+		box-shadow: 0 2rpx 10rpx rgba(0, 0, 0, 0.06);
+		z-index: 10;
+
+		.nav-item {
+			flex: 1;
 			display: flex;
-			align-items: center;
 			justify-content: center;
-			width: 30rpx;
-			height: 14rpx;
-			line-height: 1;
-			margin-left: 4rpx;
-			font-size: 26rpx;
-			color: #888;
-			&.active {
+			align-items: center;
+			height: 100%;
+			font-size: 30rpx;
+			color: $font-color-dark;
+			position: relative;
+
+			&.current {
 				color: $base-color;
+
+				&:after {
+					content: '';
+					position: absolute;
+					left: 50%;
+					bottom: 0;
+					transform: translateX(-50%);
+					width: 120rpx;
+					height: 0;
+					border-bottom: 4rpx solid $base-color;
+				}
 			}
 		}
-		.xia {
-			transform: scaleY(-1);
+
+		.p-box {
+			display: flex;
+			flex-direction: column;
+
+			.iconfont {
+				display: flex;
+				align-items: center;
+				justify-content: center;
+				width: 30rpx;
+				height: 14rpx;
+				line-height: 1;
+				margin-left: 4rpx;
+				font-size: 26rpx;
+				color: #888;
+
+				&.active {
+					color: $base-color;
+				}
+			}
+
+			.xia {
+				transform: scaleY(-1);
+			}
+		}
+
+		.cate-item {
+			display: flex;
+			justify-content: center;
+			align-items: center;
+			height: 100%;
+			width: 80rpx;
+			position: relative;
+			font-size: 44rpx;
+
+			&:after {
+				content: '';
+				position: absolute;
+				left: 0;
+				top: 50%;
+				transform: translateY(-50%);
+				border-left: 1px solid #ddd;
+				width: 0;
+				height: 36rpx;
+			}
 		}
 	}
-	.cate-item {
-		display: flex;
-		justify-content: center;
-		align-items: center;
+
+	.cate-list {
 		height: 100%;
-		width: 80rpx;
-		position: relative;
-		font-size: 44rpx;
-		&:after {
-			content: '';
-			position: absolute;
-			left: 0;
-			top: 50%;
-			transform: translateY(-50%);
-			border-left: 1px solid #ddd;
-			width: 0;
-			height: 36rpx;
-		}
+		padding-top: 40px;
 	}
-}
-.cate-list {
-	height: 100%;
-	padding-top: 40px;
-}
 </style>