diff --git a/src/views/Activities/SpringFestival/index.vue b/src/views/Activities/SpringFestival/index.vue index 2b14f48..dd5c8b2 100644 --- a/src/views/Activities/SpringFestival/index.vue +++ b/src/views/Activities/SpringFestival/index.vue @@ -511,9 +511,81 @@ + > + + + + + + + + + + + + {{ showTarget(task) }} + + + + + + 100000 coins/Get + + + *1 + + + + + + + + {{ t('task_go') }} + + + + + {{ t('task_receive') }} + + + + + {{ t('task_received') }} + + + + { helpShow.value = false } +// 展示任务目标 +const showTarget = (task) => { + if (task.targetType == 'SEND_GIFT') { + if (task.taskCode == 'SPINS_SEND_GIFT') { + return 'Lucky and magical gifts win gold coins' + } + } else if (task.targetType == 'WIN_COINS') { + if (task.taskCode == 'SPINS_WIN_100000') { + return 'Win coins in the game' + } + } +} + // 跳转到充值页面 const gotoRecharge = () => { router.push('/recharge') @@ -846,6 +931,46 @@ const getMyLotteryTicketCount = async () => { } } +//获取任务列表 +const getTaskList = async () => { + // const resTaskList = await ActTaskList() + // if (resTaskList.status && resTaskList.body) { + // taskList.value = resTaskList.body + // } + taskList.value = [ + { + taskId: 1, + taskCode: 'SPINS_WIN_100000', + taskName: 'Win 100000 coins in the game', + taskType: 4, + taskDesc: '游戏内获得100000金币', + targetType: 'WIN_COINS', + targetValue: 100000, + targetUnit: 'COINS', + currentValue: 0, + progressRate: 0, + taskStatus: 0, + rewardType: 1, + rewardValue: 1, + }, + { + taskId: 2, + taskCode: 'SPINS_SEND_GIFT', + taskName: 'Lucky and magical gifts win 100000 gold coins', + taskType: 2, + taskDesc: '送出幸运礼物或魔法礼物赢取100000金币', + targetType: 'SEND_GIFT', + targetValue: 100000, + targetUnit: 'COINS', + currentValue: 0, + progressRate: 0, + taskStatus: 0, + rewardType: 1, + rewardValue: 1, + }, + ] +} + //获取用户信息 const getUserInfo = async () => { if (Object.keys(userInfo.value).length === 0) { @@ -1059,6 +1184,9 @@ const initData = async () => { await Promise.all([ getActivityDetail(), //获取奖池 getMyLotteryTicketCount(), //获取抽奖券 + + getTaskList(), //获取任务列表 + getUserInfo(), //获取用户信息 getDrawableAmount(), //获取可提现金额 initializePayee(), //获取收款人信息