|
@@ -1,16 +1,16 @@
|
|
|
<template>
|
|
|
<view class="lottery_new">
|
|
|
- <view class="welcome" v-if="pageIndex == 0">
|
|
|
+ <view class="welcome" :style="pageIndex == 1 ? 'height:auto' : ''">
|
|
|
<!-- logo与跑马灯 -->
|
|
|
<view class="header">
|
|
|
<img :src="lotteryInfo.logo" class="logo" mode="widthFix" />
|
|
|
<view class="barrage-box">
|
|
|
- <view class="text">{{ recordList.length == 0 ? '还没有人中奖,快来参与吧!' : '' }}</view>
|
|
|
+ <view class="text">{{ lottery_list.length == 0 ? '还没有人中奖,快来参与吧!' : lottery_list }}</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
|
|
|
<!-- 立即参与页面 -->
|
|
|
- <view class="page-1" style="padding: 0 16rpx">
|
|
|
+ <view class="page-1" style="padding: 0 16rpx" v-if="pageIndex == 0">
|
|
|
<view class="activity-info">
|
|
|
<!-- <text class="title">{{ acticve_detail?.name }}</text> -->
|
|
|
<view class="active-rule">
|
|
@@ -29,10 +29,9 @@
|
|
|
dial-style="color: rgba(60,48,158,0.7); padding: 32rpx;background-image: url(https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/lottery/lottery_bg.png)"
|
|
|
:prizeList="prizeList"
|
|
|
:turns="5"
|
|
|
- :duration="5"
|
|
|
+ :duration="3"
|
|
|
@done="onDone"
|
|
|
ref="dialer"
|
|
|
- pointerStyle="display: none"
|
|
|
/>
|
|
|
<view class="lottery_bottom">
|
|
|
<view class="lottery_btn" @click="onClick"></view>
|
|
@@ -80,6 +79,7 @@
|
|
|
export default {
|
|
|
data() {
|
|
|
return {
|
|
|
+ lottery_list: '',
|
|
|
pageIndex: 0,
|
|
|
height: '',
|
|
|
// 奖项列表,
|
|
@@ -127,6 +127,7 @@ export default {
|
|
|
|
|
|
this.requestParam.id = param.id;
|
|
|
this.requestParam.activity_id = param.activity_id;
|
|
|
+ this.pageIndex = param.pageIndex || 0;
|
|
|
// 如果有scene参数的话,获取其中的ID
|
|
|
if (param.scene) {
|
|
|
// 转键值对参数
|
|
@@ -210,6 +211,18 @@ export default {
|
|
|
if (re.code == 'success') {
|
|
|
this.lotteryInfo = re.data;
|
|
|
this.prizeList = re.data.reward_list;
|
|
|
+ this.$http.request('api/lottery_recruitment_record/get_list_all', { lottery_id: this.requestParam.id }).then((res) => {
|
|
|
+ if (res.code == 'success') {
|
|
|
+ if (res.data?.length > 0) {
|
|
|
+ let str = '';
|
|
|
+
|
|
|
+ res.data.forEach((item) => {
|
|
|
+ str += `用户${item.username}已获得${item.reward_name};`;
|
|
|
+ });
|
|
|
+ this.lottery_list = str;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ });
|
|
|
} else {
|
|
|
if (re.code != 'no_login') {
|
|
|
uni.showModal({
|
|
@@ -269,10 +282,10 @@ export default {
|
|
|
});
|
|
|
return;
|
|
|
}
|
|
|
- if (!this.$checkAccess.getHasFollow()) {
|
|
|
- this.$refs.addFollow.open('center');
|
|
|
- return;
|
|
|
- }
|
|
|
+ // if (!this.$checkAccess.getHasFollow()) {
|
|
|
+ // this.$refs.addFollow.open('center');
|
|
|
+ // return;
|
|
|
+ // }
|
|
|
// 次数操作
|
|
|
this.lotteryInfo.number = this.lotteryInfo.number - 1;
|
|
|
// 请求列表
|
|
@@ -473,7 +486,7 @@ export default {
|
|
|
background-repeat: no-repeat;
|
|
|
width: 100vw;
|
|
|
min-height: 100vh;
|
|
|
- padding-top: 405rpx;
|
|
|
+ padding-top: 150rpx;
|
|
|
.lottery_box {
|
|
|
display: block;
|
|
|
width: 750rpx;
|
|
@@ -502,6 +515,19 @@ export default {
|
|
|
background-image: url('https://kailin-mp.oss-cn-shenzhen.aliyuncs.com/static/lottery/lottery_btn.png');
|
|
|
background-repeat: no-repeat;
|
|
|
background-size: 100% 100%;
|
|
|
+ animation: pulse 1.5s infinite; /* 添加动画 */
|
|
|
+ }
|
|
|
+ /* 定义动画 */
|
|
|
+ @keyframes pulse {
|
|
|
+ 0% {
|
|
|
+ transform: scale(1); /* 初始大小 */
|
|
|
+ }
|
|
|
+ 50% {
|
|
|
+ transform: scale(1.2); /* 变大 */
|
|
|
+ }
|
|
|
+ 100% {
|
|
|
+ transform: scale(1); /* 恢复原始大小 */
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
.lottery_rule_btn {
|