Commit 0ae24270 authored by 郝聪敏's avatar 郝聪敏

Merge branch 'feature/animation' into 'master'

修改分享图片为空bug;修改视频规则bug

See merge request !45
parents 80899fc1 f1cf839c
......@@ -97,7 +97,7 @@
<video-pause :pause="pause"></video-pause>
</video>
<image v-if="item.showType && item.showType.value === 1" class="images" :src="item.photoUrl" mode="widthFix"></image>
<view class="rightcont">
<view class="rightcont" v-show="item.id > 0">
<view class="info">奖品库存: {{item.stock}}/{{item.totalStock}}</view>
<view class="info">中奖概率: {{item.probability}}</view>
<view class="progress">
......
......@@ -41,7 +41,7 @@
<view class="help-cont">
<view class="help-title">如何获得克币?</view>
<view class="help-info">
<view>1.打卡:每次可获得50克币,每天仅限打卡一次;</view>
<view>1.打卡:每次可获得1克币,每天仅限打卡一次;</view>
<view>2.分享:通过分享每次邀请1名新的好友参加,即可获得10克币;</view>
<view>3.购买:通过在Luckii购买产品即可获得克币,克币数量根据购买产品价格而定。</view>
</view>
......
......@@ -158,7 +158,7 @@
<template>
<view class="video-wrapper">
<view class="prize">
<prize-list :videoList="videoList" :userAccount="mainInfo && mainInfo.account && mainInfo.account.quantity || 0" :total="total" bindchange="changeVideo" @getAwardsInfo="getAwardsInfo">
<prize-list :videoList="videoList" :userAccount="mainInfo && mainInfo.account && mainInfo.account.quantity || 0" bindchange="changeVideo" @getAwardsInfo="getAwardsInfo">
</prize-list>
</view>
<view class="userInfo" style="{{safeAreaStyle}}">
......@@ -202,7 +202,7 @@
mainInfo: null,
showModal: 0, // 1: 展示领取金币弹窗 2: 展示抽奖弹窗 3: 头像菜单弹窗
awardsInfo: {},
isReceive: false
isReceive: false // 是否显示领取克币动画
},
computed: {
......@@ -294,7 +294,7 @@
return {
title: `${(this.$wepy.userInfo && this.$wepy.userInfo.nickName) || '您的好朋友'}邀请您来抽奖啦~`,
path: `/pages/index?openid=${openid}`,
imageUrl: this.$wepy.awardsInfo.photoUrl,
imageUrl: decodeURIComponent(this.$wepy.awardsInfo.photoUrl),
success: function(res) {
let shareId = res.shareTickets[0];
console.log('shareId', shareId);
......@@ -306,7 +306,7 @@
},
getAwards: function() {
const { id, photoUrl, name, chance } = this.awardsInfo;
if (!id || !this.mainInfo || !this.mainInfo.account) {
if ((!id && id !== 0) || !this.mainInfo || !this.mainInfo.account) {
Notify({ message: '服务器异常,请稍后重试', safeAreaInsetTop: true });
return;
}
......@@ -314,6 +314,10 @@
Notify({ message: '您的克币数为0, 无法参与抽奖', safeAreaInsetTop: true });
return;
}
if (id <= 0) {
Notify({ message: '当前视频为规则说明, 无法参与抽奖', safeAreaInsetTop: true });
return;
}
wx.navigateTo({
url: `/pages/raffle?prizeId=${id}&chance=${chance}&photoUrl=${photoUrl}&quantity=${this.mainInfo.account.quantity}&name=${name}`
......
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