index.vue 2.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. <template>
  2. <view class="layout-page" :style="themeStyle">
  3. <v-header :title="$t('auth.a0')"></v-header>
  4. <view class="rounded-md overflow-hidden m-lg bg-panel-3 box-shadow">
  5. <v-link to="/pages/auth/primary" class="d-flex align-center p-md border-b link-active ">
  6. <view class="flex-fill color-light fn-lg">
  7. {{$t('auth.a1')}}
  8. </view>
  9. <view class="status" v-if="detail.primary_status==0">
  10. <van-icon class="fn-middle" name="info-o" />
  11. {{$t('auth.a2')}}
  12. </view>
  13. <view class="status color-buy" v-else>
  14. <van-icon class="fn-middle" name="passed" />
  15. {{$t('auth.a3')}}
  16. </view>
  17. <van-icon class="m-l-xs" name="arrow" />
  18. </v-link>
  19. <v-link tag="view" :to="detail.status!=2?'/pages/auth/senior':''" class="d-flex align-center p-md border-b link-active">
  20. <view class="flex-fill color-light fn-lg ">
  21. {{$t('auth.a4')}}
  22. </view>
  23. <view class="status " v-if="detail.status==0">
  24. <van-icon class="fn-middle" name="info-o" />
  25. {{$t('auth.a2')}}
  26. </view>
  27. <view class="status color-yellows" v-else-if="detail.status==1">
  28. <van-icon class="fn-middle" name="clock-o" />
  29. {{$t('auth.a5')}}
  30. </view>
  31. <view class="status color-buy" v-else-if="detail.status==2">
  32. <van-icon class="fn-middle" name="passed" />
  33. {{$t('auth.a3')}}
  34. </view>
  35. <view class="status color-sell" v-else-if="detail.status==3">
  36. <van-icon class="fn-middle" name="close" />
  37. {{$t('auth.a6')}}
  38. </view>
  39. <van-icon class="m-l-xs" name="arrow" />
  40. </v-link>
  41. </view>
  42. </view>
  43. </template>
  44. <script>
  45. import { mapState,mapGetters} from "vuex";
  46. import Profile from "@/api/profile";
  47. export default {
  48. name:'auth',
  49. data(){
  50. return {
  51. detail:{}
  52. }
  53. },
  54. computed:{
  55. ...mapState({
  56. user:'user'
  57. }),
  58. ...mapGetters(['themeStyle'])
  59. },
  60. methods:{
  61. getAuthInfo(){
  62. Profile.getAuthInfo().then(res=>{
  63. this.detail = res.data
  64. })
  65. }
  66. },
  67. onShow(){
  68. this.getAuthInfo()
  69. }
  70. // created(){
  71. // this.getAuthInfo()
  72. // }
  73. }
  74. </script>
  75. <style lang="scss" scoped>
  76. </style>