12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758 |
- <template>
- <view>
- <u-navbar :border-bottom="false" :is-back="true" title="设置">
- </u-navbar>
- <view>
- <u-cell-group>
- <u-cell-item title="个人信息" @click="profile"></u-cell-item>
- <u-cell-item title="修改密码" @click="changePassword"></u-cell-item>
- </u-cell-group>
- </view>
- <view class="btn">
- <u-button plain type="default" @click="logout">退出登录</u-button>
- </view>
- <view class="version">Version {{ vuex_version }}</view>
- </view>
- </template>
- <script>
- export default {
- data() {
- return {}
- },
- onLoad() {
- },
- methods: {
- profile() {
- this.$u.route('/pages/profile/profile')
- },
- logout() {
- // 登录成功修改token与用户信息
- this.$u.vuex('vuex_token', '');
- this.$u.vuex('vuex_user', {});
- return uni.reLaunch({
- url: '../index/index'
- })
- },
- changePassword() {
- this.$u.route('/pages/profile/password')
- }
- }
- }
- </script>
- <style lang="scss">
- .btn {
- margin: 20 rpx;
- }
- .version {
- position: absolute;
- bottom: 20 rpx;
- width: 100%;
- text-align: center;
- }
- </style>
|