handle.vue 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163
  1. <template>
  2. <view>
  3. <view class="cmain">
  4. <view class="box order_detail">
  5. <view>
  6. <view class="item ctt">订单确认</view>
  7. </view>
  8. <view class="expand" :style="{ height: expand ? 'auto' : '300px' }">
  9. <view class="item">
  10. <text class="label">订单编号</text>
  11. <text class="desc omit">{{ item.tradeNo }}</text>
  12. </view>
  13. <view class="item">
  14. <text class="label">结算单号</text>
  15. <text class="desc omit">{{ item.settleBillNo }}</text>
  16. </view>
  17. <view class="item">
  18. <text class="label">预申报编号</text>
  19. <text class="desc omit">{{ item.platSeqNo }}</text>
  20. </view>
  21. <view class="item">
  22. <text class="label">买家</text>
  23. <text class="desc omit">{{ item.buyUserName }}</text>
  24. </view>
  25. <view class="item">
  26. <text class="label">车牌号</text>
  27. <text class="desc">{{ item.veNo }}</text>
  28. </view>
  29. <view class="item">
  30. <text class="label">商品名称</text>
  31. <text class="desc">{{ item.goodsNames }}</text>
  32. </view>
  33. <view class="item">
  34. <text class="label">申报金额</text>
  35. <text class="desc">¥ {{ item.totalPrice }}</text>
  36. </view>
  37. <view class="item">
  38. <text class="label">净重</text>
  39. <text class="desc">{{ item.netWt }}</text>
  40. </view>
  41. <view class="item">
  42. <text class="label">毛重</text>
  43. <text class="desc">{{ item.grossWt }}</text>
  44. </view>
  45. <view class="item">
  46. <text class="label">申报数量</text>
  47. <text class="desc">{{ item.buyQty }}</text>
  48. </view>
  49. <view class="item">
  50. <text class="label">交易地区名称</text>
  51. <text class="desc">{{ item.tradeAreaName }}</text>
  52. </view>
  53. <view class="item">
  54. <text class="label">进口预申报号</text>
  55. <text class="desc">{{ item.preIeportNo }}</text>
  56. </view>
  57. <view class="item">
  58. <text class="label">批次预录入号</text>
  59. <text class="desc">{{ item.preNo }}</text>
  60. </view>
  61. </view>
  62. <view class="more" @click="expand = !expand">
  63. <text class="icon">&#xe649;</text>
  64. <text>{{ expand ? '收起' : '更多信息' }}</text>
  65. </view>
  66. </view>
  67. </view>
  68. <view class="mfooter">
  69. <view class="flex">
  70. <view class="f">
  71. <button class="btn" @click="ok()">确定</button>
  72. </view>
  73. </view>
  74. </view>
  75. </view>
  76. </template>
  77. <script>
  78. export default {
  79. data() {
  80. return {
  81. expand: false, //展开
  82. item: {},
  83. orderId: ''
  84. };
  85. },
  86. onLoad(e) {
  87. if (e.orderId) {
  88. this.orderId = e.orderId;
  89. this.getData();
  90. }
  91. //人脸认证回调
  92. uni.$on('face', res => {
  93. this.confirmFn()
  94. });
  95. },
  96. methods: {
  97. confirmFn(){
  98. this.http.request({
  99. url: '/level-one-server/app/TbOrder/confirmOrder',
  100. method: 'POST',
  101. data: { orderId: this.item.id },
  102. success: res => {
  103. uni.showToast({ title: '订单确认成功' });
  104. setTimeout(() => {
  105. uni.switchTab({ url: '/pages/index/index' });
  106. }, 1000);
  107. }
  108. });
  109. },
  110. getData() {
  111. this.http.request({
  112. url: '/level-one-server/app/TbOrder/orderDetail',
  113. data: { orderId: this.orderId },
  114. success: res => {
  115. this.item = res.data.data;
  116. }
  117. });
  118. },
  119. ok() {
  120. uni.showModal({
  121. title: '提示',
  122. content: '我已核对信息无误',
  123. success: res => {
  124. if (res.confirm) {
  125. this.confirmFn();
  126. //return;
  127. //跳转到人脸认证
  128. uni.navigateTo({url:'/pages/face/faceRegister?type=2'})
  129. }
  130. }
  131. });
  132. }
  133. },
  134. destroyed() {
  135. uni.$off('face');
  136. }
  137. };
  138. </script>
  139. <style lang="scss">
  140. page {
  141. background-color: $pg;
  142. }
  143. .cmain {
  144. padding-bottom: 100px;
  145. }
  146. .expand {
  147. overflow: hidden;
  148. }
  149. .more {
  150. text-align: center;
  151. padding: 10px 10px 15px 10px;
  152. .icon {
  153. padding-right: 3px;
  154. }
  155. }
  156. .ctt {
  157. text-align: center;
  158. font-weight: bold;
  159. }
  160. </style>