go-appointment.wxml 3.1 KB
<!--pages/index/go-appointment/go-appointment.wxml-->
<view class="content">
    <view class="city_box">
        <picker bindchange="bindPickerChange" value="{{index}}" range="{{array}}">
            <view class="select">
                <view class="picker" wx:if="{{is_change}}">
                    {{array[index]}}
                </view>
                <view wx:else>北京市</view>
                <view class="iconfont icon-daosanjiao"></view>
            </view>
        </picker>
    </view>

    <view class="section">
        <scroll-view class="area_box"  scroll-y>
            <block wx:for="{{areaTest}}" wx:key="index">
                <view class="area-test">
                    <view class="area">{{item.area}}</view>
                    <view class="test-list">
                        <view class="list-item-box">
                            <block wx:for="{{item.list}}" wx:key="index">
                                <view class="list-item" bindtap="chooseTest" data-index="{{index}}"
                                      data-id="{{item.id}}">
                                    <image src="../../../images/blue_line.png" wx:if="{{currentId === item.id}}"
                                           class="blue-line"></image>
                                    <view class="test {{currentId === item.id?'change-color':''}}">{{item.name}}</view>
                                </view>
                            </block>
                        </view>
                    </view>
                </view>
            </block>
        </scroll-view>

        <view class="test_box">
            <scroll-view scroll-y class="test_describe">
                {{test.title}}
            </scroll-view>
            <scroll-view class="time-list-box" scroll-y>
                <view wx:for="{{test.list}}" wx:key="index" class="time-list" bindtap="chooseTime" data-index="{{index}}">
                    <image src="../../../images/blue_line.png" wx:if="{{currentTime === index && item.rest !== 0}}"
                           class="blue-line"></image>
                    <view class="right-content {{item.rest === 0? 'change-gray':''}}">
                        <view class="{{currentTime === index && item.rest !== 0? 'change-color':''}}">{{item.week}}  {{item.date}}</view>
                        <view class="bottom-time-box">
                            <text class="time {{currentTime === index && item.rest !== 0? 'change-color':''}}">{{item.time}}</text>
                            <text class="rest {{item.rest === 0? 'change-gray':''}}">剩余: {{item.rest}}</text>
                        </view>
                    </view>
                </view>
            </scroll-view>
        </view>
    </view>

    <view class="footer">
        <view class="confirm_btn" bindtap="submit" wx:if="{{show_submit_btn}}">
            <text>提 交</text>
        </view>
        <view class="appointment-box" wx:else>
            <text class="single" bindtap="singleAppointment">单人预约</text>
            <text class="double" bindtap="doubleAppointment">双人预约</text>
        </view>
        <!--<view>提 交</view>-->
    </view>
</view>