rechargeRes.vue 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156
  1. <template>
  2. <view>
  3. <u-navbar title="充值结果"></u-navbar>
  4. <view class="paySuccess">
  5. <u-icon name="chenggong" custom-prefix="custom-icon" size="180" color="#00B962"></u-icon>
  6. <view class="title oldTextjp" oldstyle="font-size: 20px;">{{detail.payStatusStr}}</view>
  7. <view class="payPrice">
  8. <font>{{detail.totalFee}}</font><span>元</span>
  9. </view>
  10. <p class="oldTextjp2" oldstyle="font-size: 16px;">{{detail.payNameStr}}</p>
  11. </view>
  12. <view class="paySuccess-btn">
  13. <u-button class="success-btn1 oldTextjp2" oldstyle="font-size: 18px;" shape="circle" type="" @click="rechargeContinue">
  14. <span>继续充值</span>
  15. </u-button>
  16. <u-button class="success-btn2 oldTextjp2" oldstyle="font-size: 18px;"
  17. v-if="charge"
  18. shape="circle" type="success" @click="chargeLook">
  19. <span>前往充电</span>
  20. </u-button>
  21. <u-button class="success-btn2 oldTextjp2" oldstyle="font-size: 18px;"
  22. v-else
  23. shape="circle" type="success" @click="balanceLook">
  24. <span>查看余额</span>
  25. </u-button>
  26. </view>
  27. </view>
  28. </template>
  29. <script>
  30. import * as API from '@/apis/finance.js'
  31. export default {
  32. data() {
  33. return {
  34. detail: {},
  35. id: "",
  36. charge:false,
  37. chargeObj:{},
  38. }
  39. },
  40. onLoad(op) {
  41. if(op.id){
  42. this.id=op.id
  43. this.getInfo();
  44. }
  45. var obj=this.carhelp.getGunIdCharge();
  46. if(obj){
  47. this.charge=true
  48. this.chargeObj=obj
  49. }
  50. },
  51. onReady() {
  52. },
  53. methods: {
  54. getInfo() {
  55. uni.showLoading({
  56. title: "加载中",
  57. mask: true,
  58. })
  59. API.accountDetail({
  60. outOrderNo: this.id
  61. }).then((res) => {
  62. uni.hideLoading()
  63. this.detail = res.data.orderInfo;
  64. }).catch(error => {
  65. uni.showToast({
  66. title: error,
  67. icon: "none"
  68. })
  69. })
  70. },
  71. rechargeContinue() {
  72. uni.redirectTo({
  73. url: '/pages/user/finance/recharge'
  74. })
  75. },
  76. chargeLook(){
  77. uni.redirectTo({
  78. url:'/pages/searchPile/chargeProcess/charge?isback=1&deviceNo='+this.chargeObj.deviceNo+"&gun="+this.chargeObj.channelNo+"&carNumber="+this.chargeObj.carNumber
  79. })
  80. },
  81. balanceLook() {
  82. uni.redirectTo({
  83. url: '/pages/user/finance/balance'
  84. })
  85. }
  86. }
  87. }
  88. </script>
  89. <style>
  90. page {
  91. background-color: #fff;
  92. }
  93. </style>
  94. <style lang="scss" scoped>
  95. .paySuccess {
  96. text-align: center;
  97. padding: 50px 0;
  98. .title {
  99. font-size: 20px;
  100. margin-top: 20px;
  101. }
  102. .payPrice {
  103. display: flex;
  104. align-items: flex-end;
  105. justify-content: center;
  106. font {
  107. font-size: 36px;
  108. line-height: 36px;
  109. }
  110. margin-top: 20px;
  111. }
  112. p {
  113. color: #999;
  114. margin-top: 4px;
  115. }
  116. }
  117. .paySuccess-btn {
  118. display: flex;
  119. justify-content: space-between;
  120. padding: 0 40px;
  121. }
  122. .success-btn1 {
  123. color: #BBBBBB !important;
  124. background-color: #fff !important;
  125. flex: 0.4;
  126. span {
  127. color: #333;
  128. }
  129. }
  130. .success-btn2 {
  131. background-color: #00B962 !important;
  132. flex: 0.4;
  133. border-color: #00B962 !important;
  134. color: #fff !important;
  135. }
  136. </style>