| 123456789101112131415161718192021222324252627282930313233343536373839404142 | <!--pages/add-inner-device/index.wxml--><view class="sg-container">  <view class="sg-search-box sg-fix-top">    <van-dropdown-menu>      <van-dropdown-item value="{{ type }}" options="{{ device_types }}" bind:change="onChange" bind:change="onChange"        data-name="type" />      <van-dropdown-item value="{{ name }}" options="{{ names }}" bind:change="onChange" bind:change="onChange"        data-name="name" />      <van-dropdown-item value="{{ spec }}" options="{{ specs }}" bind:change="onChange" bind:change="onChange"        data-name="spec" />    </van-dropdown-menu>    <van-search value="{{ number }}" placeholder="请输入固定资产编号模糊查询" bind:change="onChange" data-name="number"      left-icon="false" bind:search="search" use-right-icon-slot>      <van-icon name="search" bind:tap="search" slot="right-icon"></van-icon>    </van-search>  </view>  <view class="sg-list sg-pad">    <inner-device-card wx:for="{{list}}" wx:key="index" index="{{index}}" item="{{item}}" showChecked="{{true}}" bind:checked="switchSelect"></inner-device-card>  </view>  <van-dialog show="{{ showAdded }}" use-slot title="已添加设备" show-cancel-button bind:confirm="switchShowAdded"    z-index="200" data-show="{{false}}">    <view class="sg-added-list">      <view class="sg-item sg-pad sg-bottom-border sg-flex sg-align-center sg-space-between" wx:for="{{add_devices}}"        wx:key="index">        <view class="sg-left">          <view class="sg-name sg-font-small">{{item.device ? item.device.name + ' - ' : ''}}{{item.name}}</view>          <view class="sg-dates sg-font-xs sg-gray-color">            {{item.start_date ? item.start_date + '至' + item.end_date : ''}}</view>        </view>        <view class="sg-right sg-red-bg sg-white sg-pad-sm" bindtap="deleteDevice" data-index="{{index}}">删除</view>      </view>    </view>  </van-dialog>  <van-calendar show="{{ showDate }}" bind:close="switchShowDate" bind:confirm="confirmDate" data-show="{{false}}"    type="range" class="sg-calendar" default-date="{{default_dates}}" />  <view class="sg-submit-box sg-fix-bottom sg-flex sg-align-center sg-center">    <!-- <view class="sg-action sg-pad sg-white-bg" bindtap="switchShowAdded" data-show="{{true}}">已添加({{add_devices.length}})</view> -->    <!-- <view class="sg-action sg-draft sg-pad sg-border-right sg-green-bg sg-white" bindtap="complete">完成</view> -->    <view class="sg-action sg-draft sg-pad sg-border-right sg-index-bg sg-white" style="width:100%"      bindtap="switchShowDate" data-show="{{true}}" data-type='draft'>立即添加</view>  </view></view>
 |