index.wxml 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. <view
  2. class="list"
  3. wx:for="{{listData}}"
  4. wx:key="id"
  5. data-item="{{item}}"
  6. bind:tap="jumpGoodsDetail">
  7. <view class="goods-cover-wrap">
  8. <image
  9. class="goods-cover"
  10. mode="widthFix"
  11. src="{{item.product_img_url}}"></image>
  12. </view>
  13. <view class="goods-describe">
  14. <view class="name-wrap {{item.product_sale_at === 0 ? 'has-tag' : ''}}">
  15. <view class="name">{{item.product_title}}</view>
  16. <view class="tag" wx:if="{{item.product_sale_at === 0}}">预售</view>
  17. </view>
  18. <view class="price-wrap">
  19. <view class="now">
  20. <view class="unit">¥</view>
  21. <view class="yuan">{{tools.fen2YuanAndJiao(item.product_all_price).yuan}}</view>
  22. <view class="jiao">{{tools.fen2YuanAndJiao(item.product_all_price).jiao}}</view>
  23. </view>
  24. <view class="old">¥{{tools.fen2Yuan(item.product_price)}}</view>
  25. </view>
  26. <view class="star-words">{{item.product_desc}}</view>
  27. <view
  28. class="key-words-list"
  29. wx:if="{{tools.formatProductLable(item.product_recommend_lable).length > 0}}">
  30. <view
  31. class="key-words"
  32. wx:for="{{tools.formatProductLable(item.product_recommend_lable)}}"
  33. wx:key="item">
  34. <text class="value">{{item}}</text>
  35. </view>
  36. </view>
  37. </view>
  38. </view>
  39. <wxs src="../../components/wxs/index.wxs" module="tools"></wxs>