|
|
@ -22,11 +22,11 @@ |
|
|
|
|
|
|
|
|
|
|
|
<!-- #ifdef APP-PLUS --> |
|
|
|
<u-swiper class="swiper" :list="swiperList" previousMargin="48rpx" nextMargin="80rpx" circular |
|
|
|
<u-swiper class="swiper" :list="swiperList" @click="bannerClick" previousMargin="48rpx" nextMargin="80rpx" circular |
|
|
|
:autoplay="true" radius="32rpx" bgColor="rgba(0,0,0,0)" height="360rpx"> |
|
|
|
<!-- #endif --> |
|
|
|
<!-- #ifdef H5 --> |
|
|
|
<u-swiper class="swiper" :list="swiperList" previousMargin="48rpx" nextMargin="80rpx" circular |
|
|
|
<u-swiper class="swiper" :list="swiperList" @click="bannerClick" previousMargin="48rpx" nextMargin="80rpx" circular |
|
|
|
:autoplay="true" radius="32rpx" bgColor="rgba(0,0,0,0)" height="360rpx" style="margin-top: 145rpx;"> |
|
|
|
<!-- #endif --> |
|
|
|
</u-swiper> |
|
|
@ -150,6 +150,7 @@ |
|
|
|
swiperList: [ |
|
|
|
|
|
|
|
], |
|
|
|
bannerList:[], |
|
|
|
videoShow: false, |
|
|
|
videoUrl: '', |
|
|
|
videoList: [], |
|
|
@ -196,6 +197,16 @@ |
|
|
|
} |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
bannerClick(i){ |
|
|
|
// #ifdef APP-PLUS |
|
|
|
plus.runtime.openUrl(this.bannerList[i].adUrl) |
|
|
|
// #endif |
|
|
|
// #ifdef H5 |
|
|
|
var href = this.bannerList[i].adUrl |
|
|
|
window.open(href, '_blank'); |
|
|
|
// #endif |
|
|
|
|
|
|
|
}, |
|
|
|
// 获取用户余额信息 |
|
|
|
getUserInfoBalance() { |
|
|
|
api.userAccount().then(res => { |
|
|
@ -322,6 +333,7 @@ |
|
|
|
api.indexBanner({ |
|
|
|
'mark': 'APP_INDEX' |
|
|
|
}).then(res => { |
|
|
|
this.bannerList=res |
|
|
|
for (var i = 0; i < res.length; i++) { |
|
|
|
this.swiperList.push(this.baseURL + res[i].adImgPath) |
|
|
|
} |
|
|
|