index.wxml 4.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. <!-- 头部视图 -->
  2. <view class="top-view" style="position: sticky; top: 0; z-index: 999;">
  3. <!-- 导航视图 -->
  4. <view class="nav-view" style="height: {{ statusBarHeight + navHeight + 10}}px;">
  5. <!-- tabs -->
  6. <view class="tab-view" style="padding-top: {{ statusBarHeight }}px; height: {{ navHeight }}px;">
  7. <van-tabs custom-class="van-tabs" nav-class="van-tabs__nav" sticky animated bind:change="onTabChange" color="#fff" line-width="20px" title-active-color="#fff" title-inactive-color="#CAE5FF">
  8. <van-tab wx:for="{{ tabs }}" wx:for-item="itm" wx:key="id" id="{{ itm.id }}" title="{{ itm.name }}"/>
  9. </van-tabs>
  10. <!-- 功能区 -->
  11. <view class="gird-view">
  12. <view class="gird-view__item" wx:for="{{ menus }}" wx:for-index="idx" wx:for-item="itm" wx:key="id" id="{{ itm.id }}" bindtap="onIconClick">
  13. <image src="{{ itm.icon }}.png" mode="heightFix"></image>
  14. <text style="color: #CAE5FF; font-size: 12px;">{{ itm.title }}</text>
  15. </view>
  16. </view>
  17. </view>
  18. </view>
  19. <!-- 下拉菜单 -->
  20. <van-dropdown-menu custom-class="dropdown-menu" active-color="#1989fa">
  21. <van-dropdown-item id="categorys" value="{{ category }}" options="{{ categorys }}" bind:change="onDropdownChange" />
  22. <van-dropdown-item id="shapes" value="{{ shape }}" options="{{ shapes }}" bind:change="onDropdownChange" />
  23. <van-dropdown-item id="claritys" value="{{ clarity }}" options="{{ claritys }}" bind:change="onDropdownChange" />
  24. <van-dropdown-item id="cuts" value="{{ cut }}" options="{{ cuts }}" bind:change="onDropdownChange" />
  25. <van-dropdown-item id="fluorescences" value="{{ fluorescence }}" options="{{ fluorescences }}" bind:change="onDropdownChange"/>
  26. </van-dropdown-menu>
  27. <!-- 搜索框 -->
  28. <van-search model:value="{{ zsallproperties }}" use-action-slot="{{ true }}" wx:if="{{ active != 0 }}" shape="round" input-align="center" background="#407DB8" placeholder="请输入商品属性 支持模糊查询">
  29. <view slot="action" style="color: #fff;" bind:tap="onClick">搜索</view>
  30. </van-search>
  31. </view>
  32. <!-- 内容滚动视图 -->
  33. <scroll-view class="content-view" style="padding-bottom: 10px;">
  34. <!-- 数据 -->
  35. <van-swipe-cell wx:for="{{ active === 0 ? sellOrders : askOrders }}" wx:for-item="itm" wx:for-index="idx" wx:key="wrtradeorderid" right-width="50">
  36. <view class="vanSwipeCell-item">
  37. <view class="vanSwipeCell-item__top">
  38. <text>{{ itm.zsshapetypedisplay }}</text>
  39. <tetx>{{ active === 0 ? itm.remainqty+"ct"+"|"+itm.zscolortype1display+"|"+itm.zsclaritytype1display : itm.zstabledisplay }}</tetx>
  40. <text>{{ active === 0 ? itm.zscurrencytypedisplayunit+itm.price : '' }}</text>
  41. </view>
  42. <view class="vanSwipeCell-item__mid">
  43. <view class="vanSwipeCell-item__mid__left">
  44. <text>切工:{{ active === 0 ? itm.zscuttype1display : itm.zscuttypedisplay }}</text>
  45. <text>抛光:{{ active === 0 ? itm.zspolishtype1display : itm.zspolishtypedisplay }}</text>
  46. <text>尺寸:--</text>
  47. </view>
  48. <view class="vanSwipeCell-item__mid__mid">
  49. <text>对称:{{ active === 0 ? itm.zssymmetrytype1display : itm.zssymmetrytypedisplay }}</text>
  50. <text>荧光:{{ active === 0 ? itm.zsfluorescencetype1display : itm.zsfluorescencetypedisplay }}</text>
  51. <text wx:if="{{ active === 0 }}">证书:--</text>
  52. </view>
  53. <view class="vanSwipeCell-item__mid__right" id="favorite {{ idx }}" wx:if="{{ active === 0 }}" bindtap="onButtonPressed">
  54. <van-icon name="star" color="#407DB8"></van-icon>
  55. <text>已收藏</text>
  56. </view>
  57. </view>
  58. <view class="vanSwipeCell-item__dwn">
  59. <text>{{ active === 0 ? itm.sellusername : itm.buyusername }}</text>
  60. <text>{{ itm.ordertime }}</text>
  61. </view>
  62. </view>
  63. <!-- 左滑按钮 -->
  64. <view slot="right" class="vanSwipeCell-right ">
  65. <view class="item detail" id="detail {{ idx }}" style="background-color: yellowgreen;" bindtap="onButtonPressed">详情</view>
  66. </view>
  67. </van-swipe-cell>
  68. <!-- 求购大厅 -->
  69. </scroll-view>
  70. <!-- 无数据 -->
  71. <van-empty wx:if="{{ isEmpty }}" class="custom-image" description="无数据"/>
  72. <!-- toast -->
  73. <van-toast id="van-toast" />