1234567891011121314151617181920212223242526272829303132333435363738 |
- <!--pages/personal/personal.wxml-->
- <view class="personal-view">
- <t-cell title="头像" arrow hover>
- <view class="avatar" slot="note">
- <t-button wx:if="{{userInfo.avatarUrl}}" class="avatar-btn" variant="text" open-type="chooseAvatar" bind:chooseavatar="onChooseAvatar">
- <t-avatar image="{{userInfo.avatarUrl}}" class="avatar" size="medium" />
- </t-button>
- <t-button wx:else class="avatar-btn" variant="text" open-type="chooseAvatar" bind:chooseavatar="onChooseAvatar">
- <t-avatar image="{{avatar}}" class="avatar" size="medium" />
- </t-button>
- </view>
- </t-cell>
- <t-cell title="昵称" hover arrow>
- <t-input value="{{userInfo.nickName}}" bind:blur='updateNickName' type='nickname' class="nickname" placeholder="请输入昵称" slot='note'>
- </t-input>
- </t-cell>
- <t-cell title="性别" hover arrow>
- <view slot='note'>
- <text wx:if="{{userInfo.gender == 1}}" bind:tap="handleSexSelectShow">男性</text>
- <text wx:if="{{userInfo.gender == 2}}" bind:tap="handleSexSelectShow">女性</text>
- <t-button wx:if="{{userInfo.gender == 0}}" class="phone" variant="text" size="small" bind:tap="handleSexSelectShow">点击选择</t-button>
- </view>
- </t-cell>
- <t-cell title="绑定手机" hover arrow>
- <view slot='note'>
- <text wx:if="{{userInfo.phoneNumber}}">{{userInfo.phoneNumber}}</text>
- <t-button wx:else class="phone" variant="text" size="small" open-type="getPhoneNumber" bindgetphonenumber="handleGetPhoneNumber">点击绑定</t-button>
- </view>
- </t-cell>
- <view class="btn-container" wx:if="{{isLogin}}">
- <t-button block size="large" class="btn" bindtap="handleLogout">退出登录</t-button>
- </view>
- <t-action-sheet id="t-action-sheet" bind:selected="handleSelected" bind:cancel="handleCancel" />
- </view>
|