index.wxml 1.4 KB

12345678910111213141516171819202122232425262728293031
  1. <navigator class="product" url="/packageA/activity/detail?id={{item.sa_promotionid}}" wx:for="{{list}}" wx:key="sa_promotionid">
  2. <view class="image-box">
  3. <van-image width="100%" wx:if="{{item.attinfos[0]}}" height="100%" fit="cover" src="{{item.attinfos[0].subfiles[0].url||item.attinfos[0].url}}" use-loading-slot use-error-slot lazy-load>
  4. <van-loading slot="loading" type="spinner" size="20" vertical />
  5. <text slot="error">加载失败</text>
  6. </van-image>
  7. <text class="text" wx:else>暂无图片</text>
  8. </view>
  9. <view class="right-box">
  10. <view class="title line-1">{{item.promname||'--'}}</view>
  11. <view class="tags">
  12. <view wx:if="{{item.type}}" style="background: #FA8C16;">
  13. {{item.type}}
  14. </view>
  15. <view wx:if="{{item.brandname}}" style="background: #FA8C16;">
  16. {{item.brandname}}
  17. </view>
  18. <view wx:if="{{item.tradefield.length}}" style="background: #FA8C16;">
  19. {{item.tradefield}}
  20. </view>
  21. </view>
  22. <view class="type line-1">开始时间:{{item.begdate||'--'}}</view>
  23. <view class="type line-1">结束时间:{{item.enddate||'--'}}</view>
  24. <view wx:if="{{item.type=='返利促销'}}" class="type line-1">活动可用余额:{{item.canuseamount||'0'}}</view>
  25. <view wx:if="{{item.surplus}}" class="type line-1" style="display: flex;align-items: center;">
  26. 距结束:
  27. <van-count-down time="{{ item.surplus }}" format="DD 天 HH 时 mm 分 ss 秒" />
  28. </view>
  29. </view>
  30. </navigator>
  31. <Yl_Empty wx:if="{{list.length === 0}}" />