1. index.xml 代码
1 <!--index.wxml-->
2 <swiper indicator-dots="{{indicatorDots}}" indicator-dots="true"
3 autoplay="{{autoplay}}" autoplay="true" interval="{{interval}}" duration="{{duration}}">
4 <block wx:for="{{imgUrls}}" wx:key="">
5
<swiper-item>
6
<image src="{{item}}" class="slide-image"/>
7
</swiper-item>
8 </block>
9 </swiper>
10 <view class=\'pro-list\'>
11 <view class=\'pro-item\' wx:for="{{ proList}}" wx:key="" bindtap=\'toDetail\' data-index="{{index}}">
12
<image class=\'pro-logo\' src="{{item.img}}"></image>
13
<view class=\'pro-body\'>
14
<view class=\'pro-title\'>{{item.title}}</view>
15
<text class=\'pro-desc\'>{{item.desc}}</text>
16
<view class=\'pro-footer\'>
17
<image class="btn-detial" src="/images/btn_detail.png"></image>
18
<button class="btn-ask" open-type="contact">
<image class=\'btn-img\' src="/images/btn_ask.png"/>
</button>
20
</view>
21
</view>
22 </view>
23 </view>