Commit a8b82e47 authored by liwei's avatar liwei

对接了banner相关接口,后续要改

parent 4b897d7f
...@@ -14,8 +14,7 @@ ...@@ -14,8 +14,7 @@
<!-- 轮播图 后面放banner里的图--> <!-- 轮播图 后面放banner里的图-->
<view class="box"> <view class="box">
<view class="swiper"> <view class="swiper">
<ls-swiper :list="userData.imgList" imgKey="" :loop="true" :dots="true" :autoplay="true" <ls-swiper :list="bannerList" imgKey="" :loop="true" :dots="true" :autoplay="true" :height="200" />
:height="200" />
</view> </view>
</view> </view>
<!-- 公告--> <!-- 公告-->
...@@ -128,7 +127,6 @@ ...@@ -128,7 +127,6 @@
<image src="../../static/images/share.png" class="simg" mode="aspectFill"></image> <image src="../../static/images/share.png" class="simg" mode="aspectFill"></image>
{{userData.gender!='MALE'?'她':'他'}}推荐给好友 {{userData.gender!='MALE'?'她':'他'}}推荐给好友
</u-button> </u-button>
<!-- <view class="name">{{userData.gender!='MALE'?'她':'他'}}推荐给好友</view> -->
</view> </view>
<view class="fe"> <view class="fe">
<view class="" style="height: 40rpx;display: flex;align-items: center;margin-top: 26rpx;"> <view class="" style="height: 40rpx;display: flex;align-items: center;margin-top: 26rpx;">
...@@ -280,7 +278,8 @@ ...@@ -280,7 +278,8 @@
rows:this.queryParam.rows rows:this.queryParam.rows
} }
bannerList(query).then(res =>{ bannerList(query).then(res =>{
this.bannerList = res.data.rows //将res.data.rows集合里的bannerPicture取出来,放到集合中
this.bannerList = res.data.rows.map(item => item.bannerPicture)
}).catch(e => { }).catch(e => {
console.log(e) console.log(e)
}) })
......
...@@ -43,17 +43,20 @@ ...@@ -43,17 +43,20 @@
}; };
}, },
onShow() { onShow() {
if (uni.getStorageSync('itemobj')) {
uni.switchTab({ uni.switchTab({
url: '/pages/tab/index' url: '/pages/tab/index'
}); });
// this.falg = false // if (uni.getStorageSync('itemobj')) {
} else { // uni.switchTab({
console.log('[]'); // url: '/pages/tab/index'
setTimeout(() => { // });
this.falg = true; // // this.falg = false
}, 1000); // } else {
} // console.log('[]');
// setTimeout(() => {
// this.falg = true;
// }, 1000);
// }
}, },
components: { components: {
ELM ELM
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment