铝交易,微信公众号
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

146 lines
3.0 KiB

11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
  1. <template>
  2. <view class="list">
  3. <view class="item"
  4. v-for="(item, index) in 10"
  5. @click="immediatePurchase(item)"
  6. :key="index">
  7. <image
  8. class="image"
  9. src="https://img95.699pic.com/photo/50058/1378.jpg_wh860.jpg" mode=""></image>
  10. <view class="info">
  11. <view class="title">
  12. {{ $t('other.aluminumProducts') }}
  13. </view>
  14. <view class="price">
  15. <text>58</text>
  16. {{ $t('other.unitPrice2') }}
  17. </view>
  18. <!--<view class="favorable">-->
  19. <!-- <view class="t">-->
  20. <!-- 限时优惠-->
  21. <!-- </view>-->
  22. <!-- <view class="p">-->
  23. <!-- 48-->
  24. <!-- </view>-->
  25. <!--</view>-->
  26. <view class="num">
  27. 最多批发*快速下单
  28. </view>
  29. </view>
  30. <view class="btn">
  31. <view class="change">
  32. {{ $t('other.immediatePurchase') }}
  33. </view>
  34. </view>
  35. </view>
  36. </view>
  37. </template>
  38. <script>
  39. export default {
  40. name: "productList",
  41. data() {
  42. return {};
  43. },
  44. methods: {
  45. // 立即购买
  46. immediatePurchase(item) {
  47. console.log("====")
  48. var itemStr = encodeURIComponent(JSON.stringify(item));
  49. uni.navigateTo({
  50. url: `/pages_order/tradingPlatform/nowOrder?params=${itemStr}`,
  51. });
  52. }
  53. },
  54. }
  55. </script>
  56. <style scoped lang="scss">
  57. .list {
  58. display: flex;
  59. justify-content: center;
  60. flex-wrap: wrap;
  61. .item {
  62. position: relative;
  63. width: 300rpx;
  64. padding: 20rpx;
  65. background-color: #fff;
  66. border-radius: 20rpx;
  67. margin-top: 20rpx;
  68. &:nth-child(odd) {
  69. margin-right: 20rpx;
  70. }
  71. .image {
  72. width: 300rpx;
  73. height: 250rpx;
  74. border-radius: 20rpx;
  75. }
  76. .info {
  77. font-size: 26rpx;
  78. .title {
  79. font-size: 30rpx;
  80. color: #000;
  81. }
  82. .price {
  83. color: #D03F25;
  84. margin-top: 6rpx;
  85. text {
  86. font-size: 34rpx;
  87. font-weight: 900;
  88. }
  89. }
  90. .favorable {
  91. display: flex;
  92. background-image: url(/static/image/product/favorable.png);
  93. background-size: 100% 100%;
  94. width: fit-content;
  95. padding: 5rpx 10rpx;
  96. font-size: 18rpx;
  97. margin-top: 6rpx;
  98. .p {
  99. color: #fff;
  100. margin-left: 10rpx;
  101. }
  102. }
  103. .num {
  104. margin-top: 6rpx;
  105. font-size: 22rpx;
  106. color: #888;
  107. }
  108. }
  109. .btn {
  110. position: absolute;
  111. right: 0rpx;
  112. bottom: 0rpx;
  113. padding: 10rpx;
  114. border-radius: 50%;
  115. //background-color: $uni-color;
  116. .change {
  117. display: flex;
  118. align-items: center;
  119. justify-content: center;
  120. border-radius: 40rpx;
  121. color: white;
  122. font-size: 22rpx;
  123. //margin: 20rpx 10rpx 0 0;
  124. padding: 10rpx 10rpx;
  125. background: #2b467a;
  126. border: 1px solid #757986;
  127. //margin-top: 20rpx;
  128. //border-radius: 40rpx;
  129. }
  130. }
  131. }
  132. }
  133. </style>