diff --git a/pages/task/index.vue b/pages/task/index.vue index 34db094..9fcc9f5 100644 --- a/pages/task/index.vue +++ b/pages/task/index.vue @@ -50,7 +50,8 @@ {{ item.type == 1 ? item.buttonTitle : item.number ? `${item.discNumber}/${item.number}` : ( item.discNumber <= 0 ? item.buttonTitle : `剩余${item.discNumber}次`) }} - {{ item.buttonUnderContent}} @@ -283,6 +284,7 @@ } } async function goNav(item, url) { + console.log(item, url, '调试111') // jumpType (integer, optional): 跳转类型 1 内部路径 2 外部路径 , // type (integer, optional): 任务类型 1 普通任务 2 打卡任务 9 其它 , if (url) { @@ -360,42 +362,38 @@ if (item.title && item.title.indexOf('每周打卡奖励') != -1) { buttonUrl = item.buttonUrl + '?source=2' - uni.navigateTo({ - url: buttonUrl - }) + } if (item.title && item.title.indexOf('每月打卡奖励1') != -1) { buttonUrl = item.buttonUrl + '?source=3' - - uni.navigateTo({ - url: buttonUrl - }) } if (item.title && item.title.indexOf('每月打卡奖励2') != -1) { - let res = await taskReceive({ - id: item.id - }) - if (res.code == 0) { - uni.showToast({ - title: res.id == 15 ? '签到成功' : '领取成功', - icon: 'none' - }) - setTimeout(() => { - getTaskdata() - getsignIn() - }, 1000) - } else { - uni.showToast({ - title: res.msg, - icon: 'none' - }) - } + // let res = await taskReceive({ + // id: item.id + // }) + // if (res.code == 0) { + // uni.showToast({ + // title: res.id == 15 ? '签到成功' : '领取成功', + // icon: 'none' + // }) + // setTimeout(() => { + // getTaskdata() + // getsignIn() + // }, 1000) + // } else { + // uni.showToast({ + // title: res.msg, + // icon: 'none' + // }) + // } - // buttonUrl = - // `${item.buttonUrl}?standard=${item.discNumber == null ? true : false}&taskId=${item.id}` + buttonUrl = + `${item.buttonUrl}?standard=${item.discNumber == null ? true : false}&taskId=${item.id}` } - + uni.navigateTo({ + url: buttonUrl + }) } else if (item.jumpType == 3) { uni.switchTab({