search.wxml 1.9 KB

1
  1. <view class="home"><view class="search-area" style="padding:20rpx 0;background-color:#f5f6fa;"><u-search vue-id="50cad900-1" placeholder="搜索设备" shape="square" clearabled="{{true}}" show-action="{{true}}" action-text="搜索" animation="{{true}}" search-icon-color="#000" color="#000" bgColor="#fff" height="40" placeholder-color="#5c5b5b" value="{{keyword}}" data-event-opts="{{[['^search',[['search',[1,'$0'],['keyword']]]],['^custom',[['search',[1,'$0'],['keyword']]]],['^input',[['__set_model',['','keyword','$event',[]]]]]]}}" bind:search="__e" bind:custom="__e" bind:input="__e" bind:__l="__l"></u-search></view><u-empty vue-id="50cad900-2" show="{{emptyShow}}" mode="search" icon="{{$root.m0}}" bind:__l="__l"></u-empty><view hidden="{{!(!emptyShow)}}" style="height:100%;"><u-list vue-id="50cad900-3" height="100%" data-event-opts="{{[['^scrolltolower',[['scrolltolower']]]]}}" bind:scrolltolower="__e" bind:__l="__l" vue-slots="{{['default']}}"><block wx:for="{{dataList}}" wx:for-item="item" wx:for-index="index" wx:key="index"><u-list-item vue-id="{{('50cad900-4-'+index)+','+('50cad900-3')}}" bind:__l="__l" vue-slots="{{['default']}}"><view data-event-opts="{{[['tap',[['toBorrow',['$0'],[[['dataList','',index,'barCode']]]]]]]}}" class="data-box" bindtap="__e"><view style="display:flex;justify-content:space-between;margin-bottom:10rpx;"><view class="data-header"><image style="width:40rpx;height:40rpx;margin-right:10rpx;" src="{{$root.m1}}" mode="aspectFit"></image><text>{{item.name}}</text></view><text style="{{'color:'+(''+(item.borrowStatus==='可借出'?'#19be6b':item.borrowStatus==='已借出'?'#fa3534':'#ff9900'))+';'}}">{{item.borrowStatus}}</text></view><view class="data-content"><text>{{"设备编码:"+item.number}}</text><view class="_br"></view><text>{{"设备条形码:"+item.barCode}}</text></view></view></u-list-item></block></u-list></view></view>