Commit 072d05c7 authored by xd's avatar xd

Merge branch 'master' of http://114.67.93.201/xulili/ybf

parents e967ff4e 927961a3
......@@ -3,7 +3,9 @@
<img class="bg" src="../../../public/img/activeDetail_bg.jpg" alt="bg" />
<template v-if="active_type === 'coupon'">
<div class="coupon">
<div class="user-icon">用户头像</div>
<div class="user-icon">
<img :src="userIcon" alt="icon">
</div>
<p class="slogan">送你限量优惠券,手慢无~</p>
<div class="coupon-content">
<img src="../../../public/img/coupon.png" alt="coupon_bg" />
......@@ -117,6 +119,7 @@ export default {
components: { wxAuth },
data() {
return {
userIcon: '/img/photo.png',
couponDetail: {},
game_end: false,
res_error: false,
......@@ -185,11 +188,13 @@ export default {
this.currentUrl = location.href;
this.active_id = this.$route.query.id;
this.active_type = this.$route.query.active_type;
this.userIcon = this.$route.query.headurl ? decodeURIComponent(this.$route.query.headurl) : '';
// 验证用户是否登录
if (!sessionStorage.getItem("userId")) {
// 1.获取code
if (this.$route.query.unionid === undefined) {
// this.getUnionid();
console.log('query', this.$route.query);
this.getUnionid();
} else {
this.userBaseInfo.unionid = JSON.stringify(this.$route.query.unionid);
this.userBaseInfo.openid = JSON.stringify(this.$route.query.openid);
......@@ -273,8 +278,6 @@ export default {
if (this.active_type === "wheel") {
let cur_date = new Date();
let end_time = new Date(this.timeLine);
console.log(cur_date);
console.log(end_time);
if (end_time - cur_date > 0) {
this.timer = setInterval(() => {
CoutDown(this.timeLine);
......@@ -288,7 +291,6 @@ export default {
},
handleCheckAuth() {
this.showAuthDialog = false;
// this.getUnionid();
},
getUnionid() {
let redirect_uri = encodeURIComponent(
......@@ -297,7 +299,8 @@ export default {
window.location.href = `http://wxsyls.oysd.cn/getwxuserinfo.aspx?jump=${redirect_uri}`;
},
Start_Game() {
if (this.$route.query.iswxClient === "false") {
// 在微信端打开 会有身份验证 路径中会带上 unionid
if (this.$route.query.unionid === undefined) {
this.$toast("企业微信端不能参与抽奖活动");
return;
}
......@@ -410,6 +413,11 @@ export default {
border-radius: 50%;
background: #fff;
// filter: blur(2px);
img {
width: 100%;
height: 100%;
border-radius: 50%;
}
}
.slogan {
......@@ -440,6 +448,7 @@ export default {
justify-content: space-around;
align-items: center;
.money {
text-align: center;
font-size: 32px;
font-weight: bold;
}
......@@ -447,6 +456,7 @@ export default {
height: 70px;
}
.other {
padding-left: 15px;
font-size: 14px;
font-weight: 400;
p {
......
......@@ -64,7 +64,7 @@ import * as API_Active from "@/api/active";
export default {
data() {
return {
flag: 1,
flag: 2,
wheelActive_limit: 3,
wheelList_finished: false,
couponActive_limit: 3,
......@@ -149,8 +149,7 @@ export default {
path: "/activeDetail",
query: {
id: active_id,
active_type: type,
iswxClient: "false"
active_type: type
}
});
}
......
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