首页删掉一个类别:促销

wechat_user_type
Ge Hao 8 years ago
parent 30268ecdf4
commit cab6ffb912
  1. 1
      pages/index/index.js
  2. 13
      pages/index/index.wxml

@ -50,7 +50,6 @@ Page({
popularity_products: data.filter(product => product.flag === '最热'),
new_products: data.filter(product => product.flag === '新品'),
hot_products: data.filter(product => product.flag === '火爆'),
promotions: data.filter(product => product.flag === '促销'),
})
wx.setStorageSync('products', data)
})

@ -59,18 +59,5 @@
</block>
</view>
<view class="separate"></view>
<view>
<view class="category-title">
<view class="icon"><image src="../../images/1.png"></image></view>
<view><text class="name">促销</text></view>
</view>
<block wx:for="{{promotions}}" wx:for-item="item">
<view class="item" bindtap="bindShowProduct" data-id="{{item.id}}">
<image class="head-img" src="{{item['image-url']}}" mode="aspectFit"></image>
</view>
</block>
</view>
</scroll-view>
</view>

Loading…
Cancel
Save