Browse Source

首页轮播从第五个开始播放

master
chenkainan 1 year ago
parent
commit
6789c4052f
  1. 2
      app.js
  2. 2
      pages/index/index.js
  3. 2
      pages/index/index.wxml

2
app.js

@ -21,7 +21,7 @@ App({
unique_key: "wechatxcx" unique_key: "wechatxcx"
}).then(res => { }).then(res => {
let data = JSON.parse(res.data); let data = JSON.parse(res.data);
data.isTest = data.isTest157? true : false; data.isTest = data.isTest158? true : false;
this.globalData.configJson = data this.globalData.configJson = data
}).then(() => { }).then(() => {
// 获取ui配置文件 // 获取ui配置文件

2
pages/index/index.js

@ -33,7 +33,7 @@ Page({
videoPrize: false, videoPrize: false,
prizeInfo: null, prizeInfo: null,
otherPlat: null, otherPlat: null,
activeBannerIndex: 0, activeBannerIndex: 5,
smBannerIndex: 0, smBannerIndex: 0,
indexSeason: {}, indexSeason: {},
// startList: [], // 启动页广告 // startList: [], // 启动页广告

2
pages/index/index.wxml

@ -19,7 +19,7 @@
</navigator> </navigator>
</view> </view>
<view style="position:relative;z-index: 1;" > <view style="position:relative;z-index: 1;" >
<swiper class="swiper" autoplay="{{true}}" interval="{{3000}}" duration="{{300}}" bindchange="changeBannerIndex" circular> <swiper class="swiper" autoplay="{{true}}" interval="{{3000}}" duration="{{300}}" bindchange="changeBannerIndex" current="5" circular>
<block wx:for="{{banner}}" wx:key="index"> <block wx:for="{{banner}}" wx:key="index">
<swiper-item bindtap="bannerClick" data-item="{{item}}"> <swiper-item bindtap="bannerClick" data-item="{{item}}">
<image src="{{item.head_img}}" mode="scaleToFill"></image> <image src="{{item.head_img}}" mode="scaleToFill"></image>

Loading…
Cancel
Save