partner-order-item.vue 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160
  1. <template>
  2. <view class="order-item">
  3. <view class="order-no">
  4. 订单编号:{{ order.orderId }}
  5. <text class="status">{{ statusList[order.status] }}</text>
  6. </view>
  7. <view class="book-list">
  8. <image
  9. v-for="(book, index) in order.detailCoverList"
  10. :key="index"
  11. :src="book"
  12. mode="aspectFill"
  13. class="book-cover"
  14. />
  15. </view>
  16. <view class="order-info">
  17. <view class="info-row">
  18. <text>买书订单状态</text>
  19. <text>{{ orderStatusList[order.orderStatus] || "-" }}</text>
  20. </view>
  21. <view class="info-row">
  22. <text>买书订单预估金额</text>
  23. <text class="amount">¥{{ order.orderExpectMoney }}</text>
  24. </view>
  25. <view class="info-row">
  26. <text>我的预估佣金</text>
  27. <text class="commission">¥{{ order.expectSettlementMoney }}</text>
  28. </view>
  29. <view class="info-row" v-if="order.status == 2 || order.status == 3">
  30. <text>买书订单核算金额</text>
  31. <text class="amount">¥{{ order.orderFinalMoney || "-" }}</text>
  32. </view>
  33. <view class="info-row" v-if="order.status == 2 || order.status == 3">
  34. <text>我的结算佣金</text>
  35. <text class="commission">¥{{ order.settlementMoney || "-" }}</text>
  36. </view>
  37. </view>
  38. <view class="order-time">创建时间:{{ order.createTime }}</view>
  39. </view>
  40. </template>
  41. <script>
  42. export default {
  43. name: "partner-order-item",
  44. props: {
  45. order: {
  46. type: Object,
  47. default: () => ({}),
  48. },
  49. },
  50. data() {
  51. return {
  52. statusList: {
  53. 1: "未结算",
  54. 2: "已结算",
  55. 3: "已到账",
  56. 4: "已失效",
  57. },
  58. //-1-已取消 0-待提交 1-已删除 2-待初审 3-待取件 4-初审未通过 5-待签收 6-待收货 7-待收货 8-待审核 9-审核中 10-待到款 11-已完成
  59. orderStatusList: {
  60. "-1": "已取消",
  61. 0: "待提交",
  62. 1: "已删除",
  63. 2: "待初审",
  64. 3: "待取件",
  65. 4: "初审未通过",
  66. 5: "待签收",
  67. 6: "待收货",
  68. 7: "待收货",
  69. 8: "待审核",
  70. 9: "审核中",
  71. 10: "待到款",
  72. 11: "已完成",
  73. },
  74. };
  75. },
  76. };
  77. </script>
  78. <style lang="scss" scoped>
  79. .order-item {
  80. background: #ffffff;
  81. border-radius: 8px;
  82. padding: 16px;
  83. margin-bottom: 12px;
  84. .order-no {
  85. display: flex;
  86. justify-content: space-between;
  87. margin-bottom: 12px;
  88. font-size: 28rpx;
  89. color: #333333;
  90. line-height: 36rpx;
  91. font-family: PingFang SC;
  92. font-weight: bold;
  93. .status {
  94. color: #ff0000;
  95. }
  96. }
  97. .book-list {
  98. width: 100%;
  99. display: flex;
  100. gap: 16rpx;
  101. margin-bottom: 20rpx;
  102. overflow-x: auto;
  103. .book-cover {
  104. width: 132rpx;
  105. height: 185rpx;
  106. border-radius: 10rpx;
  107. }
  108. }
  109. .order-info {
  110. background: #f8f8f8;
  111. border-radius: 4px;
  112. width: 630rpx;
  113. border: 1px solid #ebebeb;
  114. .info-row {
  115. display: flex;
  116. justify-content: space-between;
  117. font-size: 14px;
  118. height: 60rpx;
  119. line-height: 60rpx;
  120. border-bottom: 1px solid #ebebeb;
  121. color: #666;
  122. &:last-child {
  123. border-bottom: none;
  124. }
  125. &:last-child {
  126. margin-bottom: 0;
  127. }
  128. text {
  129. flex: 1;
  130. padding-left: 20rpx;
  131. }
  132. text:last-child {
  133. border-left: 1px solid #ebebeb;
  134. background-color: #ffffff;
  135. }
  136. .amount {
  137. color: #333;
  138. }
  139. .commission {
  140. color: #ff0000;
  141. }
  142. }
  143. }
  144. .order-time {
  145. margin-top: 12px;
  146. font-size: 13px;
  147. color: #999;
  148. }
  149. }
  150. </style>