freeze.vue 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104
  1. <template>
  2. <view class="flex">
  3. <image src="../../static/new_index/top.png" mode="widthFix" style="width: 642rpx;margin-top: 76rpx;"></image>
  4. <image src="../../static/new_index/bottom.png" mode="widthFix" style="width: 310rpx;margin-top: 116rpx;">
  5. </image>
  6. <view class="title">{{ type == 1? list[0].title : list[1].title }}</view>
  7. <view class="tip">{{ type == 1? list[0].tip : list[1].tip }}</view>
  8. <view class="login_out flexC" @tap="logout">退出绑定</view>
  9. </view>
  10. </template>
  11. <script>
  12. import {
  13. _API_Logout
  14. } from '@/apis/verify.js'
  15. export default {
  16. data() {
  17. return {
  18. type: '',
  19. list: [{
  20. title: '您长时间未登录被冻结,请联系客服',
  21. tip: '温馨提示:您已被冻结,暂不能使用系统!如有疑问请及时联系客服'
  22. }, {
  23. title: '您的账号已被系统删除',
  24. tip: '温馨提示:您已被删除,暂不能使用系统!如有疑问请及时联系客服'
  25. }]
  26. }
  27. },
  28. onLoad(option) {
  29. this.type = option.type
  30. },
  31. methods: {
  32. // 退出登录
  33. logout() {
  34. uni.showLoading({
  35. mask: true
  36. })
  37. _API_Logout().then(() => {
  38. if (this.$store.state.app.token) {
  39. this.$store.commit('app/LOGOUT')
  40. // this.toWxchatLogin("/pages/login-reg/login-reg", null)
  41. uni.reLaunch({
  42. url: '../login-reg/login-reg'
  43. })
  44. } else {
  45. this.$store.commit('app/LOGOUT')
  46. // this.toWxchatLogin("/pages/login-reg/login-reg", null)
  47. uni.reLaunch({
  48. url: '../login-reg/login-reg'
  49. })
  50. }
  51. })
  52. uni.removeStorageSync('isHelper')
  53. },
  54. toWxchatLogin(url, state) {
  55. url = url || "/pages/index/index"
  56. state = state || "cli"
  57. const redirect_uri = encodeURIComponent(`${this.$config.redirect_uri}/api/gzh#${url}`)
  58. const auth = () => window.location.href =
  59. `${this.$config.wxURL}?appid=${this.$config.appid}&redirect_uri=${redirect_uri}&response_type=code&scope=snsapi_userinfo&state=${state}#wechat_redirect`
  60. auth()
  61. },
  62. }
  63. }
  64. </script>
  65. <style lang="scss">
  66. page {
  67. background-color: #fff;
  68. }
  69. .flex {
  70. display: flex;
  71. align-items: center;
  72. flex-direction: column;
  73. .title {
  74. color: #333333;
  75. font-size: 40rpx;
  76. font-weight: bold;
  77. margin-top: 136rpx;
  78. }
  79. .tip {
  80. width: 560rpx;
  81. font-size: 28rpx;
  82. font-weight: 400;
  83. color: #999999;
  84. margin-top: 40rpx;
  85. line-height: 44rpx;
  86. }
  87. }
  88. .login_out {
  89. width: 220rpx;
  90. height: 88rpx;
  91. // background: #007AFF;
  92. margin-top: 140rpx;
  93. color: #999;
  94. font-size: 30rpx;
  95. color: $base-color;
  96. }
  97. </style>