Commit d8b73198 authored by ziyu's avatar ziyu

improvement: 优化

parent 09f1c7a7
...@@ -52,9 +52,8 @@ ...@@ -52,9 +52,8 @@
showLoading:false, showLoading:false,
isListDone:false, isListDone:false,
}, },
created() { attached() {
this.getList(); this.getList();
// goodsIds = this.list.map(item => item.sourceId);
}, },
methods: { methods: {
moveSwiper(e) { moveSwiper(e) {
......
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
<van-loading type="spinner" size="40" v-if="videoLoading" custom-class="video-loading"/> <van-loading type="spinner" size="40" v-if="videoLoading" custom-class="video-loading"/>
<!--<video-loading v-if="videoLoading" :snapshot="item.videoSnapUrl"/>--> <!--<video-loading v-if="videoLoading" :snapshot="item.videoSnapUrl"/>-->
</video> </video>
<van-image wx:if="{{item.showType && item.showType.value ==1}}" use-loading-slot src="{{item.photoUrl}}" class="images" radius="10rpx" fit="contain" width="100%" height="100%"> <van-image wx:if="{{item.showType && item.showType.value ==1}}" use-loading-slot src="{{item.photoUrl || item.videoSnapUrl}}" class="images" radius="10rpx" fit="contain" width="100%" height="100%">
<van-loading slot="loading" type="spinner" size="20" vertical/> <van-loading slot="loading" type="spinner" size="20" vertical/>
</van-image> </van-image>
<view class="rightcont" v-show="item.id > 0"> <view class="rightcont" v-show="item.id > 0">
......
...@@ -413,15 +413,18 @@ ...@@ -413,15 +413,18 @@
} else { } else {
wx.setStorageSync('innerActivity', ''); wx.setStorageSync('innerActivity', '');
} }
// 弹窗有多个,展示顺序 1、活动弹窗 2、邀请好友 3、购买获得克币 4、开奖宝箱 // 弹窗有多个,展示顺序 活动弹窗->邀请好友->购买获得克币->开奖宝箱
if(this.mainInfo.activity && this.mainInfo.activity.id && this.mainInfo.activity.id !== +activityId) { if(this.mainInfo.activity && this.mainInfo.activity.id && this.mainInfo.activity.id !== +activityId) {
//活动弹窗
this.avtivityModal = true; this.avtivityModal = true;
} else if (this.mainInfo.inviteRecord && this.mainInfo.inviteRecord.length) { } else if (this.mainInfo.inviteRecord && this.mainInfo.inviteRecord.length) {
//邀请好友
this.showModal = 1; this.showModal = 1;
} else if (this.mainInfo.buyRecord && this.mainInfo.buyRecord.length) { } else if (this.mainInfo.buyRecord && this.mainInfo.buyRecord.length) {
//购买获得金币 //购买获得金币
this.showModal = 4; this.showModal = 4;
} else if (this.mainInfo.joinRecord && this.mainInfo.joinRecord.id) { } else if (this.mainInfo.joinRecord && this.mainInfo.joinRecord.id) {
//开奖宝箱
this.showModal = 2; this.showModal = 2;
} }
}, },
...@@ -460,7 +463,6 @@ ...@@ -460,7 +463,6 @@
if (this.mainInfo.inviteRecord && this.mainInfo.inviteRecord.length) { if (this.mainInfo.inviteRecord && this.mainInfo.inviteRecord.length) {
this.showModal = 1; this.showModal = 1;
} else if (this.mainInfo.buyRecord && this.mainInfo.buyRecord.length) { } else if (this.mainInfo.buyRecord && this.mainInfo.buyRecord.length) {
//购买获得金币
this.showModal = 4; this.showModal = 4;
} else if (this.mainInfo.joinRecord && this.mainInfo.joinRecord.id) { } else if (this.mainInfo.joinRecord && this.mainInfo.joinRecord.id) {
this.showModal = 2; this.showModal = 2;
...@@ -510,6 +512,7 @@ ...@@ -510,6 +512,7 @@
// 获取奖品列表 // 获取奖品列表
this.videoList = await getPrizeList(options.prizeId); this.videoList = await getPrizeList(options.prizeId);
this.getMainInfo(); this.getMainInfo();
flag = true; flag = true;
......
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