You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
38 lines
610 B
38 lines
610 B
<template>
|
|
<view class="my-container">
|
|
<my-login v-if="!token"></my-login>
|
|
|
|
<my-userinfo v-else></my-userinfo>
|
|
</view>
|
|
</template>
|
|
|
|
<script>
|
|
import {mapState} from "vuex"
|
|
import {
|
|
mapMutations
|
|
} from 'vuex'
|
|
export default {
|
|
data() {
|
|
return {
|
|
|
|
};
|
|
},
|
|
onLoad(){
|
|
this.updatetoken(uni.getStorageSync('token'))
|
|
},
|
|
methods:{
|
|
...mapMutations('m_user', ['updateUserInfo', 'updatetoken','savetokentostorage'])
|
|
},
|
|
computed: {
|
|
...mapState('m_user',['token'])
|
|
}
|
|
}
|
|
</script>
|
|
|
|
<style lang="scss">
|
|
page,
|
|
.my-container {
|
|
height: 100%;
|
|
}
|
|
</style>
|