first commit
This commit is contained in:
91
pages/usercenter/index.wxml
Normal file
91
pages/usercenter/index.wxml
Normal file
@@ -0,0 +1,91 @@
|
||||
<!--pages/usercenter/index.wxml-->
|
||||
<navigation-bar title="个人中心" back="{{false}}" color="black" background="#FFF"></navigation-bar>
|
||||
|
||||
<scroll-view class="usercenter-container" scroll-y>
|
||||
<!-- 用户信息 -->
|
||||
<view class="user-info">
|
||||
<image src="{{userInfo.avatarUrl}}" mode="aspectFill" class="user-avatar"></image>
|
||||
<view class="user-detail">
|
||||
<view class="user-name">{{userInfo.nickName}}</view>
|
||||
<view class="user-level">{{userInfo.level}}</view>
|
||||
<view class="user-phone">{{userInfo.phone}}</view>
|
||||
</view>
|
||||
<view class="user-points">
|
||||
<text class="points-value">{{userInfo.points}}</text>
|
||||
<text class="points-label">积分</text>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 我的预约 -->
|
||||
<view class="section my-appointments" wx:if="{{appointmentList.length > 0}}">
|
||||
<view class="section-header">
|
||||
<text class="section-title">我的预约</text>
|
||||
<view class="section-more" bindtap="goToFunction" data-url="/pages/appointment/index">
|
||||
<text>查看全部</text>
|
||||
<t-icon name="chevron-right" size="32rpx" color="#999" />
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="appointment-list">
|
||||
<view wx:for="{{appointmentList.slice(0, 2)}}" wx:key="id" class="appointment-card">
|
||||
<view class="appointment-header">
|
||||
<view class="appointment-service">{{item.service.name}}</view>
|
||||
<view class="appointment-status {{item.status === '已确认' ? 'confirmed' : ''}}">{{item.status}}</view>
|
||||
</view>
|
||||
<view class="appointment-info">
|
||||
<view class="appointment-time">
|
||||
<t-icon name="time" size="40rpx" />
|
||||
<text>{{item.date}} {{item.time}}</text>
|
||||
</view>
|
||||
<view class="appointment-price">¥{{item.service.price}}</view>
|
||||
</view>
|
||||
<view class="appointment-actions">
|
||||
<t-button size="small" variant="outline" bindtap="cancelAppointment" data-id="{{item.id}}">取消预约</t-button>
|
||||
<t-button size="small" bindtap="viewAppointmentDetail" data-id="{{item.id}}">查看详情</t-button>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 功能列表 -->
|
||||
<view class="section function-list">
|
||||
<view class="section-header">
|
||||
<text class="section-title">我的服务</text>
|
||||
</view>
|
||||
|
||||
<view class="function-grid">
|
||||
<view
|
||||
wx:for="{{functionList}}"
|
||||
wx:key="id"
|
||||
class="function-item"
|
||||
bindtap="goToFunction"
|
||||
data-url="{{item.url}}"
|
||||
>
|
||||
<t-icon name="{{item.icon}}" size="48rpx" color="#FF5F15" />
|
||||
<view class="function-name">{{item.name}}</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 服务列表 -->
|
||||
<view class="section service-list">
|
||||
<view class="section-header">
|
||||
<text class="section-title">服务与设置</text>
|
||||
</view>
|
||||
|
||||
<view class="service-items">
|
||||
<view
|
||||
wx:for="{{serviceList}}"
|
||||
wx:key="id"
|
||||
class="service-item"
|
||||
bindtap="goToFunction"
|
||||
data-url="{{item.url}}"
|
||||
data-type="{{item.type}}"
|
||||
>
|
||||
<t-icon name="{{item.icon}}" size="40rpx" color="#666" />
|
||||
<view class="service-name">{{item.name}}</view>
|
||||
<t-icon name="chevron-right" size="40rpx" color="#999" />
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</scroll-view>
|
||||
Reference in New Issue
Block a user