goodsDetail.wxml 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495
  1. <!-- 轮播 -->
  2. <view class="page-section">
  3. <swiper
  4. indicator-dots="{{true}}"
  5. indicator-color="rgba(130, 130, 130, 1)"
  6. indicator-active-color="#FFF"
  7. autoplay="{{false}}">
  8. <block wx:for="{{background}}" wx:key="*this">
  9. <swiper-item>
  10. <view class="swiper-item {{item}}">
  11. <image src=""></image>
  12. </view>
  13. </swiper-item>
  14. </block>
  15. </swiper>
  16. </view>
  17. <view class="main-information">
  18. <view class="tag-list">
  19. <text>蔬菜</text>
  20. </view>
  21. <text
  22. class="name"
  23. user-select>名字</text>
  24. <view class="unit-price">
  25. <text class="price">¥23.00</text>
  26. <text class="unit">/ kg</text>
  27. </view>
  28. </view>
  29. <customer-tab
  30. nav="{{nav}}"
  31. active="{{active}}"
  32. bind:change="handleNav"/>
  33. <!--描述-->
  34. <view
  35. class="business-info"
  36. hidden="{{active === '2'}}">
  37. <text class="introduce" user-select>一段描述</text>
  38. <block wx:if="{{false}}">
  39. <view class="subtitle">预计上架时间</view>
  40. <view class="date">2022年09月10日</view>
  41. </block>
  42. <block wx:if="{{true}}">
  43. <view class="subtitle">相关产品</view>
  44. <scroll-view
  45. class="goods-scroll"
  46. scroll-x>
  47. <view
  48. class="item"
  49. wx:for="{{[1, 2, 3, 4]}}"
  50. wx:key="item">
  51. <view>
  52. <view class="photo">
  53. <image src=""></image>
  54. </view>
  55. <view class="info">
  56. <text
  57. class="name">名字名字名字名字名字名字名字名字</text>
  58. <view class="unit-price">
  59. <text class="price">¥23.00</text>
  60. <text class="unit">/ kg</text>
  61. </view>
  62. </view>
  63. </view>
  64. </view>
  65. </scroll-view>
  66. </block>
  67. </view>
  68. <!-- todo 供应商-->
  69. <view
  70. class="business-info"
  71. hidden="{{active === '1'}}">
  72. 供应商
  73. </view>
  74. <view
  75. class="fixed-bottom"
  76. hidden="{{active === '2'}}">
  77. <view>
  78. <button
  79. class="btn-collection"
  80. type="primary"
  81. wx:if="{{false}}">预约并收藏
  82. </button>
  83. <block wx:if="{{true}}">
  84. <button
  85. class="btn-collection"
  86. type="primary">添加购物车
  87. </button>
  88. <button
  89. class="btn-collection"
  90. type="primary">添加收藏夹
  91. </button>
  92. </block>
  93. </view>
  94. </view>