pay-status.vue 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132
  1. <template>
  2. <view class="ps">
  3. <view class="ps_status_icon"><image src="../../icon/shop/pay_success.png" mode=""></image></view>
  4. <text class="ps_status_text">支付成功</text>
  5. <text class="ps_status_tip">感谢你对大卫博士微店的支持,欢迎你下次购买</text>
  6. <view class="ps_control">
  7. <text>订单号:{{ order_no }}</text>
  8. <text class="copy_btn" @click="copy()">复制</text>
  9. </view>
  10. <view class="ps_goon_btn" @click="lookOrder">查看订单</view>
  11. <view class="ps_follow_code"><image src="../../static/logo.png" mode="aspectFit"></image></view>
  12. <text class="ps_follow_text">关注“大卫博士官网”公众号,查询订单</text>
  13. </view>
  14. </template>
  15. <script>
  16. import { handleClipboard } from '../../common/util/index.js';
  17. export default {
  18. data() {
  19. return {
  20. order_no: ''
  21. };
  22. },
  23. onLoad(ops) {
  24. if (ops.order_no) {
  25. this.order_no = ops.order_no;
  26. }
  27. },
  28. methods: {
  29. lookOrder() {
  30. uni.reLaunch({
  31. url: '../order-manage/order-manage?status=' + 1
  32. });
  33. },
  34. copy(data) {
  35. handleClipboard(
  36. this.order_no,
  37. event,
  38. () => {
  39. uni.showToast({
  40. icon: 'none',
  41. title: '复制成功'
  42. });
  43. },
  44. () => {
  45. uni.showToast({
  46. icon: 'none',
  47. title: '复制失败'
  48. });
  49. }
  50. );
  51. }
  52. }
  53. };
  54. </script>
  55. <style lang="scss" scoped>
  56. .ps {
  57. width: 100%;
  58. padding: 30rpx;
  59. display: flex;
  60. justify-content: flex-start;
  61. align-items: center;
  62. flex-direction: column;
  63. .ps_follow_text {
  64. font-size: 28rpx;
  65. line-height: 34rpx;
  66. color: #333333;
  67. }
  68. .ps_follow_code {
  69. display: flex;
  70. align-items: center;
  71. justify-content: center;
  72. margin-bottom: 30rpx;
  73. image {
  74. display: block;
  75. width: 276rpx;
  76. height: 276rpx;
  77. }
  78. }
  79. .ps_goon_btn {
  80. width: 530rpx;
  81. margin: 74rpx auto 212rpx auto;
  82. height: 88rpx;
  83. text-align: center;
  84. line-height: 88rpx;
  85. border-radius: 88rpx;
  86. background: $base-line-bg;
  87. color: #ffffff;
  88. font-size: 32rpx;
  89. }
  90. .ps_status_icon {
  91. width: 100%;
  92. display: flex;
  93. align-items: center;
  94. justify-content: center;
  95. image {
  96. width: 210rpx;
  97. height: 172rpx;
  98. }
  99. }
  100. .ps_status_text {
  101. display: block;
  102. width: 100%;
  103. color: #333333;
  104. font-size: 48rpx;
  105. text-align: center;
  106. margin: 30rpx auto 40rpx auto;
  107. }
  108. .ps_status_tip {
  109. display: block;
  110. width: 100%;
  111. color: #999999;
  112. font-size: 28rpx;
  113. text-align: center;
  114. margin-bottom: 14px;
  115. }
  116. .ps_control {
  117. width: 100%;
  118. display: flex;
  119. align-items: center;
  120. justify-content: center;
  121. text {
  122. &:nth-of-type(1) {
  123. color: #f76454;
  124. font-size: 28rpx;
  125. line-height: 34rpx;
  126. }
  127. }
  128. }
  129. }
  130. </style>