auth_result.vue 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. <template>
  2. <view >
  3. <view class="content" >
  4. <view style="padding-top: 150rpx;">
  5. <text class="cuIcon-roundcheckfill" :class="success?'text-success':'text-error'" style="font-size: 150rpx;"></text>
  6. </view>
  7. <view class="tips">
  8. <text class="title" v-text="success?'授权成功':'授权失败'"></text>
  9. <text class="desc" v-text="success?'请打开小程序继续助力':response.message"></text>
  10. </view>
  11. <view class="cu-btn btn radius line-gray" @click.stop="confirm">
  12. 确认
  13. </view>
  14. </view>
  15. </view>
  16. </template>
  17. <script>
  18. export default {
  19. data() {
  20. return {
  21. response:{},
  22. success:false
  23. }
  24. },
  25. onLoad(options) {
  26. this.response = JSON.parse(decodeURIComponent(options.response))
  27. if (this.response.resultCode == '0000') {
  28. this.success=true
  29. }else{
  30. this.success=false
  31. }
  32. },
  33. methods: {
  34. confirm(){
  35. location.href = "weixin://dl/business/?t=X2CyIQDbgtm"
  36. }
  37. }
  38. }
  39. </script>
  40. <style>
  41. page {
  42. background-color: #FFFFFF;
  43. }
  44. </style>
  45. <style lang="scss" scoped>
  46. .text-success{
  47. color: #19be6b;
  48. }
  49. .text-error{
  50. color: #de5454;
  51. }
  52. .content {
  53. display: flex;
  54. flex-direction: column;
  55. display: flex;
  56. justify-content: center;
  57. align-items: center;
  58. image {
  59. width: 150rpx;
  60. height: 150rpx;
  61. }
  62. .tips {
  63. margin-top: 20rpx;
  64. display: flex;
  65. flex-direction: column;
  66. text-align: center;
  67. .title {
  68. font-size: 36rpx;
  69. }
  70. .desc {
  71. margin-top: 20rpx;
  72. font-size: 28rpx;
  73. color: #969696;
  74. }
  75. }
  76. .btn {
  77. margin-top: 40rpx;
  78. width: 50%;
  79. padding: 42rpx;
  80. }
  81. }
  82. </style>