<!--pages/me/index.wxml-->
<view class='v-page'>
  <!-- 头部   -->
  <view class='head-map'>
    <image src='/images/personal_center/info_background.png'></image>
    <view class='avatar_box'>
      <image src='{{user.avatar}}' bindtap="toUrl" data-url='/pages/me/profile/index'></image>
    </view>
    <view class='user-info-box'>
      <image wx-if="{{user.is_vip==1}}" src='/images/personal_center/vip.png'></image>
      <text>{{user.nickname}}</text>
    </view>
  </view>

  <!-- 我的订单 -->
  <i-cell-group>
    <i-cell title="我的订单" is-link url="/pages/me/order/index">
      <text slot="footer" class='text-gray' url='/pages/order/index'>全部</text>
    </i-cell>
    <i-row i-class="order-status-box">
      <i-col span="8" i-class="col-class">
        <view class='order-item' catchtap='handleOrderClick' data-status='1'>
          <image src='/images/personal_center/icon_be_in_progress.png'></image>
          <text>进行中</text>
        </view>
      </i-col>
      <i-col span="8" i-class="col-class">
        <view class='order-item' catchtap='handleOrderClick' data-status='2'>
          <image src='/images/personal_center/icon_to_be_evaluated.png'></image>
          <text>待评价</text>
        </view>
      </i-col>
      <i-col span="8" i-class="col-class">
        <view class='order-item' catchtap='handleOrderClick' data-status='3'>
          <image src='/images/personal_center/icon_completed.png'></image>
          <text>已完成</text>
        </view>
      </i-col>
    </i-row>
  </i-cell-group>

  <i-cell-group i-class='vip'>
    <i-cell title="VIP会员" is-link url="/pages/me/vip/index?is_vip={{user.is_vip}}&vip_endtime={{user.vip_endtime}}">
      <text slot="footer" class='text-gray'>{{user.vip_endtime==null?'':user.vip_endtime_str}}</text>
    </i-cell>
    <i-cell title="我的收藏" is-link url="/pages/me/collection/index"></i-cell>
  </i-cell-group>

  <i-cell-group>
    <i-cell title="商家合作" is-link catchtap="gotoShopJoin"></i-cell>
    <i-cell is-link>
      <button open-type='contact' class='my-btn-contact'>官方客服</button>
    </i-cell>
  </i-cell-group>
</view>