<view class="page">
|
<t-loading
|
wx:if="{{pageLoading}}"
|
theme="circular"
|
size="40rpx"
|
text="加载中..."
|
loading
|
t-class="fy-loading"
|
t-class-indicator="fy-loading-indicator"
|
t-class-text="fy-loading-text"
|
>
|
</t-loading>
|
<view class="page-header">
|
<filter
|
scene="{{searchOptions.sceneType}}"
|
time="{{searchOptions.period}}"
|
bind:scenePickerChange="handleSceneChange"
|
bind:timePickerChange="handleTimeChange"
|
bind:showFilterPopup="showFilterPopup"
|
>
|
<filter-popup-2
|
slot="filterPopup"
|
show="{{show}}"
|
bind:showFilterPopupClose="showFilterPopupClose"
|
bind:reset="reset"
|
bind:confirm="confirm"
|
>
|
</filter-popup-2>
|
</filter>
|
<view class="patrol-flex">
|
<text>总计: {{unfinishedList.length + finishedList.length}}</text>
|
<text>未完成: {{unfinishedList.length}}</text>
|
<text>完成: {{finishedList.length}}</text>
|
</view>
|
</view>
|
<t-tabs defaultValue="{{0}}" sticky>
|
<t-tab-panel
|
label="待完成"
|
value="0"
|
badge-props="{{ { count: unfinishedList.length, offset: ['-16rpx', '8rpx'] } }}"
|
>
|
<view slot="panel" class="panel-wrap">
|
<block wx:if="{{unfinishedList.length > 0}}">
|
<patrol-task
|
wx:for="{{unfinishedList}}"
|
wx:key="index"
|
item="{{item}}"
|
></patrol-task>
|
<view class="page-footer"></view>
|
</block>
|
<t-empty-page wx:else description="无相关记录" />
|
<load-more
|
list-is-empty="{{!unfinishedList.length}}"
|
status="{{loadStatus}}"
|
bind:retry="_startLoad"
|
/>
|
</view>
|
</t-tab-panel>
|
<t-tab-panel label="已完成" value="1">
|
<view slot="panel" class="panel-wrap">
|
<block wx:if="{{finishedList.length > 0}}">
|
<patrol-task
|
wx:for="{{finishedList}}"
|
wx:key="index"
|
item="{{item}}"
|
></patrol-task>
|
<view class="page-footer"></view>
|
</block>
|
<t-empty-page wx:else description="无相关记录" />
|
<load-more
|
list-is-empty="{{!finished.length}}"
|
status="{{loadStatus}}"
|
bind:retry="_startLoad"
|
/>
|
</view>
|
</t-tab-panel>
|
</t-tabs>
|
<t-fab
|
icon="add"
|
style="right: 16px; bottom: 128px"
|
bind:click="navToPublishTask"
|
aria-label="发布任务"
|
text=""
|
></t-fab>
|
</view>
|