铝交易,微信公众号
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.

218 lines
4.3 KiB

6 months ago
4 months ago
3 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
6 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
3 months ago
4 months ago
4 months ago
6 months ago
4 months ago
6 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
4 months ago
6 months ago
  1. <template>
  2. <view class="page">
  3. <view v-if="list.length>0" class="item"
  4. @click="toDetail(item)"
  5. v-for="(item, index) in list" :key="index">
  6. <view class="top">
  7. <view class="service">
  8. <text>{{ item.specsName }}</text>
  9. </view>
  10. <view class="status">
  11. <text>库存{{ item.num }}</text>
  12. </view>
  13. </view>
  14. <view class="zhuti">
  15. <view class="left">
  16. <image :src="item.pic" style="width: 100%;height: 100%;"
  17. mode="aspectFill"/>
  18. </view>
  19. <view class="right">
  20. <view class="text-hidden-1">
  21. 单价 {{ item.price }}
  22. </view>
  23. <view class="text-hidden-1">
  24. {{ $t('other.pickupAddress') }}{{ item.address }}
  25. </view>
  26. <view class="text-hidden-1">
  27. {{ $t('other.pickupDate') }}{{ item.createTime }}
  28. </view>
  29. </view>
  30. <!--审核状态 0审核中 1 审核通过 2审核未通过-->
  31. <!-- <view class="tip" v-if="item.showStatus == 0">
  32. <img v-if="item.auditStatus==0" src="/pages_order/static/order/3.svg" style="width: 100%;height: 100%;" />
  33. <img v-if="item.auditStatus==1" src="/pages_order/static/order/1.svg" style="width: 100%;height: 100%;" />
  34. <img v-if="item.auditStatus==2" src="/pages_order/static/order/2.svg" style="width: 100%;height: 100%;" />
  35. </view> -->
  36. </view>
  37. <!--撤单按钮-->
  38. <view class="bottom">
  39. <view @click.stop="showVideo(item)" class="btn"
  40. v-if="item.reportVideo"
  41. >
  42. 检测视频
  43. </view>
  44. <view @click.stop="showImage(item)" class="btn"
  45. v-if="item.report"
  46. >
  47. 检测报告
  48. </view>
  49. <view @click.stop="immediatePurchase(item)" class="btn a"
  50. >
  51. 立即下单
  52. </view>
  53. </view>
  54. </view>
  55. <!--无历史记录-->
  56. <view style="padding: 100rpx 0;" v-else>
  57. <uv-empty mode="history" textSize="28rpx" iconSize="100rpx" />
  58. </view>
  59. </view>
  60. </template>
  61. <script>
  62. export default {
  63. name: "orderList",
  64. props: {
  65. list: {
  66. type: Array,
  67. default: false
  68. },
  69. showBackOrder: {
  70. type: Boolean,
  71. default: false
  72. }
  73. },
  74. data() {
  75. return {}
  76. },
  77. methods: {
  78. // 立即购买
  79. immediatePurchase(item) {
  80. console.log("====")
  81. // var itemStr = encodeURIComponent(JSON.stringify(item));
  82. this.$store.state.productDetail = item
  83. uni.navigateTo({
  84. url: `/pages_order/tradingPlatform/nowOrder`,
  85. });
  86. },
  87. showImage(item){
  88. uni.previewImage({
  89. urls : item.report.split(','),
  90. current : 0,
  91. })
  92. },
  93. showVideo(item, index = 0){
  94. this.$emit('previewVideo', {
  95. urls : item.reportVideo.split(','), // 需要预览的资源列表
  96. index, // 当前显示的资源序号
  97. })
  98. },
  99. toDetail(item){
  100. this.$store.state.productDetail = item
  101. uni.navigateTo({
  102. url: '/pages_order/product/productDetail'
  103. })
  104. },
  105. }
  106. }
  107. </script>
  108. <style scoped lang="scss">
  109. .page {
  110. display: flex;
  111. flex-direction: column;
  112. gap: 20rpx;
  113. // height: calc(90vh - 180rpx);
  114. .item {
  115. margin: 0 20rpx;
  116. padding: 20rpx;
  117. border-radius: 40rpx;
  118. background-color: #fff;
  119. //overflow: hidden;
  120. //height:300px;
  121. .top {
  122. display: flex;
  123. justify-content: space-between;
  124. align-items: center;
  125. font-size: 30rpx;
  126. .service {
  127. color: #000;
  128. }
  129. .status {
  130. color: #8d8d8d;
  131. font-size: 26rpx;
  132. font-weight: 600;
  133. }
  134. }
  135. .zhuti {
  136. display: flex;
  137. margin: 10rpx 0;
  138. position: relative;
  139. .left {
  140. width: 150rpx;
  141. height: 150rpx;
  142. border-radius: 10rpx;
  143. image {
  144. width: 150rpx;
  145. height: 150rpx;
  146. border-radius: 10rpx;
  147. }
  148. }
  149. .right {
  150. width: calc(100% - 160rpx);
  151. color: #777;
  152. font-size: 24rpx;
  153. padding-left: 20rpx;
  154. line-height: 40rpx;
  155. background-color: #f8f8f8;
  156. }
  157. .tip {
  158. width: 80rpx;
  159. height: 80rpx;
  160. position: absolute;
  161. bottom: -20rpx;
  162. right: -20rpx;
  163. }
  164. }
  165. .bottom {
  166. display: flex;
  167. justify-content: flex-end;
  168. .btn {
  169. display: flex;
  170. align-items: center;
  171. justify-content: center;
  172. // width: ;
  173. padding: 0 24rpx;
  174. height: 50rpx;
  175. border-radius: 40rpx;
  176. color: $uni-color;
  177. font-size: 24rpx;
  178. margin: 20rpx 10rpx 0 0;
  179. background: #ffffff;
  180. border: 1px solid $uni-color;
  181. //margin-top: 20rpx;
  182. border-radius: 40rpx;
  183. }
  184. .a{
  185. background-color: $uni-color;
  186. color: #fff;
  187. }
  188. }
  189. }
  190. }
  191. </style>