all-appointment.wxml 2.3 KB
<!--pages/my/all-appointment/all-appointment.wxml-->
<view class="content">
  <!--tab-->
  <view class="tab-box">
    <view wx:for="{{tab}}" wx:key="index" bindtap="changeTab" data-index="{{index}}" class="{{currentTab == index?'change-color':''}}">{{item}}</view>
  </view>

  <!--预约列表-->
  <view class="list-box">
    <view class="order-box" bindtap="goDetail" wx:for="{{orderList}}" wx:key="index">

      <view class="head">
        <text class="number">预约单号:{{item.reservation_sn}}</text>
        <text class="appointment-state" wx:if="{{currentTab === 1}}" style="color: #FC5B63;">待确认</text>
        <text class="appointment-state" wx:if="{{currentTab === 2}}">已预约</text>
        <text class="appointment-state" wx:if="{{currentTab === 3}}" style="color: #464646;">已取消</text>
        <text class="appointment-state" wx:if="{{currentTab === 4}}" style="color: #C3C3C3;">已结束</text>
      </view>

      <view class="section">
        <image src="../../../images/red_line.png" wx:if="{{currentTab === 1}}" class="blue-line"></image>
        <image src="../../../images/blue_line.png" wx:if="{{currentTab === 2}}" class="blue-line"></image>
        <image src="../../../images/deep_grey_line.png" wx:if="{{currentTab === 3}}" class="blue-line"></image>
        <image src="../../../images/grey_line.png" wx:if="{{currentTab === 4}}" class="blue-line"></image>

        <view class="right-box">
          <view class="right-top-box">
            <view class="iconfont icon-dingwei"></view>
            <view class="address">{{item.address}}</view>
          </view>

          <view class="right-bottom-box">
            <view class="iconfont icon-shangwutubiao"></view>
            <view class="date-box">
              <view class="date">预约日期:{{item.time}}</view>

              <view class="not_confirm" wx:if="{{currentTab === 1}}">
                <view class="go-cancel">取消</view>
                <view class="go-confirm">去确认</view>
              </view>
              <view class="cancel" wx:if="{{currentTab === 2}}">取消</view>
              <view class="iconfont icon-quxiao" wx:if="{{currentTab === 3}}"></view>
              <view class="iconfont icon-jieshu" wx:if="{{currentTab === 4}}"></view>
            </view>
          </view>
        </view>
      </view>


    </view>
  </view>
</view>