list.wxml 3.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. <view class="content">
  2. <view class="navbar" style="{{'position:'+headerPosition+';'+'top:'+headerTop+';'}}">
  3. <view bindtap="__e" class="{{['nav-item',filterIndex===0?'current':'']}}" data-event-opts="{{[ [ 'tap',[ [ 'tabClick',[0] ] ] ] ]}}">综合排序</view>
  4. <view bindtap="__e" class="{{['nav-item',filterIndex===1?'current':'']}}" data-event-opts="{{[ [ 'tap',[ [ 'tabClick',[1] ] ] ] ]}}">
  5. <text>销量优先</text>
  6. <view class="p-box">
  7. <text class="{{['iconfont iconfold',numberOrder===1&&filterIndex===1?'active':'']}}"></text>
  8. <text class="{{['iconfont iconfold xia',numberOrder===2&&filterIndex===1?'active':'']}}"></text>
  9. </view>
  10. </view>
  11. <view bindtap="__e" class="{{['nav-item',filterIndex===2?'current':'']}}" data-event-opts="{{[ [ 'tap',[ [ 'tabClick',[2] ] ] ] ]}}">
  12. <text>价格</text>
  13. <view class="p-box">
  14. <text class="{{['iconfont iconfold',priceOrder===1&&filterIndex===2?'active':'']}}"></text>
  15. <text class="{{['iconfont iconfold xia',priceOrder===2&&filterIndex===2?'active':'']}}"></text>
  16. </view>
  17. </view>
  18. <text bindtap="__e" class="cate-item iconfont iconapps" data-event-opts="{{[ [ 'tap',[ [ 'toggleCateMask',['show'] ] ] ] ]}}"></text>
  19. </view>
  20. <view class="goods-list">
  21. <view bindtap="__e" class="goods-item" data-event-opts="{{[ [ 'tap',[ [ 'navToDetailPage',['$0'],[ [ ['goodsList','',index] ] ] ] ] ] ]}}" wx:for="{{goodsList}}" wx:key="index">
  22. <view class="image-wrapper">
  23. <image mode="aspectFill" src="{{item.image}}"></image>
  24. </view>
  25. <text class="title clamp">{{item.title}}</text>
  26. <view class="price-box">
  27. <text class="price">{{item.price}}</text>
  28. <text>{{'已售 '+item.sales}}</text>
  29. </view>
  30. </view>
  31. </view>
  32. <uni-load-more bind:__l="__l" status="{{loadingType}}" vueId="504effa2-1"></uni-load-more>
  33. <view bindtap="__e" class="{{['cate-mask',cateMaskState===0?'none':cateMaskState===1?'show':'']}}" data-event-opts="{{[ [ 'tap',[ [ 'toggleCateMask',['$event'] ] ] ] ]}}">
  34. <view catchtap="__e" catchtouchmove="__e" class="cate-content" data-event-opts="{{[ [ 'tap',[ [ 'stopPrevent',['$event'] ] ] ],[ 'touchmove',[ [ 'stopPrevent',['$event'] ] ] ] ]}}">
  35. <scroll-view class="cate-list" scrollY="{{true}}">
  36. <view wx:for="{{cateList}}" wx:for-index="__i0__" wx:key="id">
  37. <view class="cate-item b-b two">{{item.cate_name}}</view>
  38. <view bindtap="__e" class="{{['cate-item b-b',tItem.id==cateId?'active':'']}}" data-event-opts="{{[ [ 'tap',[ [ 'changeCate',['$0'],[ [ ['cateList','id',item.id],['children','id',tItem.id] ] ] ] ] ] ]}}" wx:for="{{item.children}}" wx:for-index="__i1__" wx:for-item="tItem" wx:key="id">{{''+tItem.cate_name+''}}</view>
  39. </view>
  40. </scroll-view>
  41. </view>
  42. </view>
  43. </view>