search.wxml 2.9 KB

1
  1. <view class="content"><view class="vheight"></view><view class="input-box flex"><view class=" input-content flex"><view class="iconfont iconsearch"></view><view class="input"><input type="text" placeholder="请输入搜索内容" data-event-opts="{{[['input',[['__set_model',['','keyword','$event',[]]]]]]}}" value="{{keyword}}" bindinput="__e"/></view></view><view data-event-opts="{{[['tap',[['navTo',['$event']]]]]}}" class="input-button flex" bindtap="__e"><text>搜索</text></view></view><swiper class="swiper-box " current="{{tabCurrentIndex}}" duration="300"><swiper-item class="search-hot"><view class="title"><text>热门搜索</text></view><view class="hot-list"><block wx:for="{{list}}" wx:for-item="ls" wx:for-index="ind" wx:key="ind"><view data-event-opts="{{[['tap',[['clickHotText',['$0'],[[['list','',ind]]]]]]]}}" class="list-item" bindtap="__e"><text>{{ls}}</text></view></block></view></swiper-item><swiper-item class="search-hot position-relative"><view class="navbar"><view data-event-opts="{{[['tap',[['defaultSearch']]]]}}" class="nav-item" bindtap="__e">默认</view><view data-event-opts="{{[['tap',[['sortTab',[1]]]]]}}" class="{{['nav-item',(searchType===1)?'current':'']}}" bindtap="__e"><text>销量优先</text><view class="p-box"><text class="{{['iconfont','iconfold',(searchType===1&&numberOrder===1)?'active':'']}}"></text><text class="{{['iconfont','iconfold','xia',(searchType===1&&numberOrder===2)?'active':'']}}"></text></view></view><view data-event-opts="{{[['tap',[['sortTab',[2]]]]]}}" class="{{['nav-item',(searchType===2)?'current':'']}}" bindtap="__e"><text>价格</text><view class="p-box"><text class="{{['iconfont','iconfold',(searchType===2&&priceOrder===1)?'active':'']}}"></text><text class="{{['iconfont','iconfold','xia',(searchType===2&&priceOrder===2)?'active':'']}}"></text></view></view><view data-event-opts="{{[['tap',[['newGoodsTab']]]]}}" class="{{['nav-item',(newOrder==1)?'current':'']}}" bindtap="__e">新品</view></view><scroll-view class="cate-list" scroll-y="{{true}}" data-event-opts="{{[['scrolltolower',[['getProducts',['$event']]]]]}}" bindscrolltolower="__e"><view class="guess-section"><block wx:for="{{goodsList}}" wx:for-item="item" wx:for-index="index" wx:key="index"><view data-event-opts="{{[['tap',[['navToDetailPage',['$0'],[[['goodsList','',index]]]]]]]}}" class="guess-item" bindtap="__e"><view class="image-wrapper"><image src="{{item.image}}" mode="aspectFill"></image></view><text class="title clamp margin-c-20">{{item.store_name}}</text><view class="cmy-hr"></view><view class="price margin-c-20 flex"><view><text class="font-size-sm ">¥</text>{{''+item.price+''}}</view><view class="font-size-sm"><text class="font-color-gray">{{item.sales+"人购买"}}</text></view></view></view></block></view><uni-load-more vue-id="1e45b5a5-1" status="{{loadingType}}" bind:__l="__l"></uni-load-more></scroll-view></swiper-item></swiper></view>