index.wxml
2.23 KB
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
<view class="page">
<view class="app__bgc bgc"></view>
<view class="app__bg bg"></view>
<view class="app__content main">
<!-- Title及搜索框 -->
<view class="top">
<image class="top-bg" mode="widthFix" src="../../image/index/index-c1.png" />
<view class="space1"></view>
<view class="search">
<view class="search-ipt-wrap">
<input value="{{code}}" bindinput="bindCodeInput" class="ipt" placeholder="请输入串码" />
</view>
<view bindtap="onSearchHandler" class="search-scan">
<image class="icon" mode="aspectFit" src="../../image/icon/icon-search.png" />
</view>
<!-- 隐藏扫描二维码 -->
<view class="search-line"></view>
<view bindtap="onScanHandler" class="search-scan">
<image class="icon" mode="aspectFit" src="../../image/icon/icon-scan.png" />
</view>
</view>
</view>
<view class="top-space"></view>
<view class="content">
<!-- 轮播 banner -->
<view class="banner">
<swiper class="swiper" indicator-color="rgba(0,0,0,.3)" indicator-active-color="rgba(255,255,255,1)" indicator-dots="{{true}}" autoplay="{{true}}" interval="{{5000}}" duration="{{500}}">
<block wx:for="{{bannerList}}" wx:key="{{index}}">
<swiper-item>
<image class="swiper-image" src="{{item}}" mode="aspectFill" />
</swiper-item>
</block>
</swiper>
</view>
<view class="product">
<view class="product-title">产品推荐{{codeStr}}</view>
<view class="product-list">
<!-- for循环 -->
<view bindtap="onProductItemHandler" data-data="{{item}}" wx:for="{{productList}}" wx:key="{{index}}" class="item">
<image class="image" mode="aspectFill" src="{{item.productImages[0]}}" />
<view class="desc">{{item.productInfo}}</view>
</view>
</view>
</view>
</view>
</view>
</view>
<van-popup show="{{ productDetailVisible }}" position="bottom">
<product-detail-comp product-info="{{curProductDetail}}" bind:evtcomp="evtcomp"></product-detail-comp>
</van-popup>
<van-popup show="{{ authorizeVisible }}">
<authorize-comp bind:evtcomp="evtcomp"></authorize-comp>
</van-popup>