Sfoglia il codice sorgente

fix bug: 库存等于0时,显示下架。status 是否在商城显示,为0时,也显示下架(商城隐藏)

shizhongqi 11 mesi fa
parent
commit
b89ec3396e
1 ha cambiato i file con 9 aggiunte e 3 eliminazioni
  1. 9 3
      hdApp/src/admin/goods/list.vue

+ 9 - 3
hdApp/src/admin/goods/list.vue

@@ -25,8 +25,11 @@
               <view class="goods-list" v-for="(goodsItem, idx) in list.data" :key="idx">
                 <view class="goods-list-top" @click="edit(goodsItem.id)">
                   <view class="img-blo">
-                    <view v-if="goodsItem.stock <= 0" class="sold-out">
-                      <view class="sold-out-xj">已下架</view>
+                    <view v-if="goodsItem.stock <= 0 || goodsItem.status == 0" class="sold-out">
+                      <view class="sold-out-xj">
+                        已下架
+                        <view v-if="goodsItem.stock != 0 && goodsItem.status == 0">(商城隐藏)</view>
+                      </view>
                     </view>
                     <img :src="goodsItem.smallCover" mode="aspectFit" />
                   </view>
@@ -432,7 +435,10 @@ page {
           color:white;
           text-align:center;
           .sold-out-xj{
-            line-height:130upx;
+            display: flex;
+            flex-direction: column;
+            justify-content: center;
+            height: 130upx;
             font-size:24upx;
           }
         }