tanghaolin
2022-07-27 fd4d1d9296ba620de15b47bd1d58383d46ecb626
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
<template name="wxSearch">
  <view class="wxSearch" bindtap="wxSearchTap" style="display:{{wxSearchData.view.isShow ? 'block':'none'}};height:{{wxSearchData.view.seachHeight}}px;top:{{wxSearchData.view.barHeight}}px;">
    <view class="wxSearchInner">
 
      <view class="wxSearchMindKey">
        <view class="wxSearchMindKeyList">
          <block wx:for="{{wxSearchData.mindKeys}}" wx:key="key">
            <view class="wxSearchMindKeyItem" bindtap="wxSearchKeyTap" data-key="{{item}}">{{item}}</view>
          </block>
        </view>
      </view>
 
      <view class="wxSearchKey" style="display:{{wxSearchData.view.isShowSearchKey ? 'block':'none'}}">
        <text class="wxSearchTitle" bindtap="asd">热门搜索</text>
        <view class="wxSearchKeyList">
          <block wx:for="{{wxSearchData.keys}}" wx:key="key">
            <view class="wxSearchKeyItem" bindtap="wxSearchKeyTap" data-key="{{item}}">{{item}}</view>
          </block>
        </view>
      </view>
      <view class="wxSearchHistory" style="display:{{wxSearchData.view.isShowSearchHistory ? 'block':'none'}}">
        <text class="wxSearchTitle">搜索历史</text>
        <view wx:if="{{wxSearchData.his[0]}}" class="wxSearchHistoryList">
          <block wx:for="{{wxSearchData.his}}" wx:key="key">
            <view class="wxSearchHistoryItem">
              <text class="wxSearchHistoryItemText" bindtap="wxSearchKeyTap" data-key="{{item}}">{{item}}</text>
              <text class="wxSearchHistoryItemDel" bindtap="wxSearchDeleteKey" data-key="{{item}}" data-key="{{item}}">删除</text>
            </view>
          </block>
          <view class="wxSearchDeleteAllBtn" bindtap="wxSearchDeleteAll">清除历史</view>
        </view>
        <view wx:else>
          <view class="wxSearchHistoryEmpty">搜索历史为空</view>
        </view>
      </view>
    </view>
  </view>
</template>