<import src="index.skeleton.wxml" />
<template is="skeleton" wx:if="{{loading}}" />
<Yl_nav search list='{{navList}}' sort='{{content.sort}}' bind:onClick='navClick' bindonSearch="onSearch" />
<!-- 显示类型 -->
<van-action-sheet show="{{ classShow }}" actions="{{ classActions }}" cancel-text="{{language['取消']||'取消'}}" bind:cancel="classClose" bind:click-overlay='classClose' bind:select="classSelect" />
<view class="global-total">
    <text wx:if="{{language['总共']}}">{{language['总共']}}：{{content.total}}</text>
    <text wx:else>总共{{content.total}}个</text>
</view>
<Yl_ListBox id='ListBox' bind:getlist='getList'>
    <List list='{{list}}' />
</Yl_ListBox>
<!-- 筛选条件 -->
<Yl_filtrate show="{{filter.show}}" bind:handle="handleFilter">
    <view class="groud">
        <view class="label">
            {{language['报价单类型']||'报价单类型'}}
        </view>
        <view class="content">
            <van-button custom-class='but {{filter.typeActive==item?"active":""}}' wx:for="{{filter.type}}" wx:key="item" bindtap="typeStatus" data-item="{{item}}">{{language[item]||item}}</van-button>
        </view>
    </view>
    <view class="groud">
        <view class="label">
            {{language['报价单状态']||'报价单状态'}}
        </view>
        <view class="content">
            <van-button custom-class='but {{filter.statusActive==item?"active":""}}' wx:for="{{filter.status}}" wx:key="item" bindtap="selectStatus" data-item="{{item}}">{{language[item]||item}}</van-button>
        </view>
    </view>
    <view class="groud">
        <view class="label">
            {{language['时间范围']||'时间范围'}}
        </view>
        <view class="content time">
            <picker mode="date" bindchange='changeDate' data-name="startdate">
                <view class="tbox">{{filter.startdate||language['开始时间']||'开始时间'}}</view>
            </picker>
            <view class="partition">-</view>
            <picker mode="date" bindchange='changeDate' data-name="enddate">
                <view class="tbox">{{filter.enddate||language['结束时间']||'结束时间'}}</view>
            </picker>
        </view>
    </view>
</Yl_filtrate>

<!-- 浮动按钮 -->
<Yl_FloatingButton wx:if="{{insert}}" bindtap="openType" />

<van-action-sheet show="{{ typeShow }}" actions="{{ typeList }}" cancel-text="{{language['取消']||'取消'}}" bind:cancel='typeCancel' bind:click-overlay='typeCancel' bind:select='typeSelect' />