Browse Source

暂无花店写法

shish 11 months ago
parent
commit
5bac158032
1 changed files with 10 additions and 9 deletions
  1. 10 9
      mallApp/src/pages/home/recent.vue

+ 10 - 9
mallApp/src/pages/home/recent.vue

@@ -13,7 +13,7 @@
     
     <!-- 已登录状态 -->
     <block v-else>
-      <view class="main-content" v-if="!$util.isEmpty(list.data)">
+      <view class="main-content">
         <!-- 个人中心版块 -->
         <view class="profile-section">
           <view class="profile-header" @click="">
@@ -67,7 +67,7 @@
          </view>
         
         <!-- 花店列表 -->
-        <view class="shop-list">
+        <view class="shop-list" v-if="!$util.isEmpty(list.data)">
           <view class="shop-card" v-for="(item, index) in list.data" :key="item.id">
             <!-- 更多选项按钮 -->
             <view class="more-btn" @click.stop="showMoreOptions(index)">
@@ -148,14 +148,15 @@
             </view>
           </view>
         </view>
+
+        <view v-else class="empty-state">
+          <text class="empty-icon">🏪</text>
+          <text class="empty-title">暂无花店</text>
+          <text class="empty-subtitle">您还没有关联花店</text>
+        </view>
+
       </view>
-      
-      <!-- 空状态 -->
-      <view v-else class="empty-state">
-        <text class="empty-icon">🏪</text>
-        <text class="empty-title">暂无花店</text>
-        <text class="empty-subtitle">您还没有关联任何花店</text>
-      </view>
+
     </block>
   </view>
 </template>