search.wxml 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110
  1. <!--pages/search/search.wxml-->
  2. <view class="container" style="position: relative; padding-bottom: {{safeBottom}}px;">
  3. <!-- TopView -->
  4. <view class="top-view">
  5. <!-- 导航栏 -->
  6. <van-nav-bar custom-style="background-color: #E92020">
  7. <van-icon slot="left" name="arrow-left" size="25px" color="white" bind:click="backToParent"/>
  8. <text slot="title" style="color: white;">钻石搜索</text>
  9. </van-nav-bar>
  10. <!-- tabs -->
  11. <view class="tab-view">
  12. <van-tabs swipeable bind:change="onTabChange">
  13. <van-tab wx:for="{{tabs}}" wx:for-item="itm" wx:key="id" id="{{itm.id}}" title="{{itm.name}}"/>
  14. </van-tabs>
  15. </view>
  16. </view>
  17. <!-- 形状 -->
  18. <view class="cell-view shape">
  19. <text>形状</text>
  20. <view class="content shape">
  21. <button wx:for="{{shapes}}" wx:for-item="itm" wx:for-index="idx" class="{{itm.isCheck ? 'active' : ''}}" id="shape {{itm.id}}" wx:key="id" bindtap="onButtonPressed">{{itm.name}}</button>
  22. </view>
  23. </view>
  24. <!-- 颜色 -->
  25. <view class="cell-view color">
  26. <text>颜色</text>
  27. <view class="content color">
  28. <button wx:for="{{colors}}" wx:for-item="itm" wx:for-index="idx" wx:key="id" class="{{itm.isCheck ? 'active' : ''}}" id="color {{itm.id}}" bindtap="onButtonPressed">{{itm.name}}</button>
  29. </view>
  30. </view>
  31. <!-- 净度 -->
  32. <view class="cell-view neatness">
  33. <text>净度</text>
  34. <view class="content neatness">
  35. <button wx:for="{{neatness}}" wx:for-item="itm" wx:for-index="idx" wx:key="id" class="{{itm.isCheck ? 'active' : ''}}" id="neatness {{itm.id}}" bindtap="onButtonPressed">{{itm.name}}</button>
  36. </view>
  37. </view>
  38. <!-- 切工 -->
  39. <view class="cell-view qiegong">
  40. <text>切工</text>
  41. <view class="content qiegong">
  42. <button wx:for="{{qiegongs}}" wx:for-item="itm" wx:for-index="idx" wx:key="id" class="{{itm.isCheck ? 'active' : ''}}" id="qiegong {{itm.id}}" bindtap="onButtonPressed">{{itm.name}}</button>
  43. </view>
  44. </view>
  45. <!-- 对称 -->
  46. <view class="cell-view duicheng">
  47. <text>对称</text>
  48. <view class="content duicheng">
  49. <button wx:for="{{duichengs}}" wx:for-item="itm" wx:for-index="idx" wx:key="id" class="{{itm.isCheck ? 'active' : ''}}" id="duicheng {{itm.id}}" bindtap="onButtonPressed">{{itm.name}}</button>
  50. </view>
  51. </view>
  52. <!-- 抛光 -->
  53. <view class="cell-view polishing">
  54. <text>抛光</text>
  55. <view class="content polishing">
  56. <button wx:for="{{paoguangs}}" wx:for-item="itm" wx:for-index="idx" wx:key="id" class="{{itm.isCheck ? 'active' : ''}}" id="polishing {{itm.id}}" bindtap="onButtonPressed">{{itm.name}}</button>
  57. </view>
  58. </view>
  59. <!-- 荧光 -->
  60. <view class="cell-view yingguang">
  61. <text>荧光</text>
  62. <view class="content yingguang">
  63. <button wx:for="{{yingguangs}}" wx:for-item="itm" wx:for-index="idx" wx:key="id" class="{{itm.isCheck ? 'active' : ''}}" id="yingguang {{itm.id}}" bindtap="onButtonPressed">{{itm.name}}</button>
  64. </view>
  65. </view>
  66. <!-- 货币 -->
  67. <view class="cell-view currency">
  68. <text>货币</text>
  69. <view class="content currency">
  70. <button wx:for="{{currencys}}" wx:for-item="itm" wx:for-index="idx" wx:key="id" class="{{itm.isCheck ? 'active' : ''}}" id="currency {{itm.id}}" bindtap="onButtonPressed">{{itm.name}}</button>
  71. </view>
  72. </view>
  73. <!-- 证书 -->
  74. <view class="cell-view certificate">
  75. <text>证书</text>
  76. <view class="content certificate">
  77. <button wx:for="{{certificates}}" wx:for-item="itm" wx:for-index="idx" wx:key="id" class="{{itm.isCheck ? 'active' : ''}}" id="certificate {{itm.id}}" bindtap="onButtonPressed">{{itm.name}}</button>
  78. </view>
  79. </view>
  80. <!-- 克拉重量 -->
  81. <view class="cell-view ctweight">
  82. <text class="label">克拉重量</text>
  83. <num-range min="{{minweight}}" max="{{maxweight}}" bind:sync="syncNumRange"></num-range>
  84. </view>
  85. <!-- 底部视图 -->
  86. <view class="buttom_view">
  87. <button bindtap="onButtonPressed" id="clear">清空</button>
  88. <button bindtap="onButtonPressed" id="search">搜索</button>
  89. </view>
  90. </view>