From 39b5a36b556e4208c2ab4a78e59357e9ac19849e Mon Sep 17 00:00:00 2001 From: mixtan <424491071@qq.com> Date: Mon, 8 Sep 2025 15:20:53 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BC=98=E5=8C=96=E5=BA=97=E9=93=BA?= =?UTF-8?q?=E5=88=86=E7=B1=BBUI?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/category/storeCategory.vue | 52 ++++++++++++++++++++++++++++---- 1 file changed, 46 insertions(+), 6 deletions(-) diff --git a/pages/category/storeCategory.vue b/pages/category/storeCategory.vue index 40dd26e..60bfcb6 100644 --- a/pages/category/storeCategory.vue +++ b/pages/category/storeCategory.vue @@ -14,8 +14,8 @@ {{ item.name }} - - + + {{ item.name }} @@ -26,6 +26,11 @@ 该分类暂无店铺数据 + 暂无分类数据 @@ -62,14 +67,16 @@ export default { success(data, status, msg, code) { const items = data.items _this.categoryMenu = items; - _this.categoryList = items[_this.categoryMenuIndex]?.sub; + _this.categoryList = items[_this.categoryMenuIndex]?.sub || []; }, }); }, methods: { categoryMenuClick(index) { this.categoryMenuIndex = index; - this.categoryList = this.categoryMenu[index]?.sub; + this.categoryList = this.categoryMenu[index]?.sub || []; + console.log(this.categoryList,'categoryList'); + }, }, }; @@ -92,13 +99,24 @@ export default { text-overflow: ellipsis; color: #333; font-size: 28rpx; - padding: 16rpx 0; + padding: 24rpx 0; box-sizing: border-box; text-align: center; &.current { color: #fe411b; background: #f4f4f4; font-weight: bold; + position: relative; + &::after{ + display: block; + content: " "; + width: 4rpx; + height: 100%; + position: absolute; + left:0; + top: 0; + background: #fe411b; + } } } } @@ -146,12 +164,34 @@ export default { text-overflow: ellipsis; } } + } + .nodata{ text-align: center; color: #999; padding: 50rpx; font-size: 24rpx; + background: #fff; } - } } + .nodata2{ + width: calc(100vw - 212rpx - 10rpx); + position: absolute; + top: 12rpx; + bottom: 12rpx; + left: 212rpx; + z-index: 1; + display: flex; + justify-content: center; + align-items: center; + flex-direction: column; + color: #999; + font-size: 24rpx; + background: #fff; + .icon_nodata{ + display: block; + width: 300rpx; + } + } +