Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

热门歌手 #65

Open
lanmch opened this issue Jun 19, 2023 · 4 comments
Open

热门歌手 #65

lanmch opened this issue Jun 19, 2023 · 4 comments

Comments

@lanmch
Copy link

lanmch commented Jun 19, 2023

热门歌手上周已经不支持 h5了,小程序也不支持(http 只有 header 不一样)
博主有没有考虑过 hack 一下 不支持 h5 购买的歌手返回的 code,强制展示进行抢票功能,我这边测试了下貌似可行,但是不太确定 http 接口是否仍然能够 create order 成功

就是这里的逻辑

// src/components/dm/Product.vue
// 修改前
else if(result.item.buyBtnStatus === "100") {
    // 不支持该渠道
    Message.error(joinMsg([result.item.buyBtnText, result.item.buyBtnTips]))
    return
} 
// 修改后
else if(result.item.buyBtnStatus === "100") {
    // 不支持该渠道
    Message.warning("不支持该渠道,即将开启强制抢票模式");
    countDownVal.value = Number(result.item.sellStartTime);
    if(countDownVal.value > Date.now()) {
        isPreSell.value = true
        isShowCountDown.value = true;
    } else {
        isPreSell.value = false
    }
} 
@lanmch
Copy link
Author

lanmch commented Jun 19, 2023

ps. 抢票可以设置下间隔,不然貌似很容易失败

@1679236695
Copy link

这个意思是虽然不支持h5,只是前端做了控制不让抢票,但是可以发请求用h5的接口去抢票?

@lanmch
Copy link
Author

lanmch commented Jun 20, 2023 via email

@shiyutim
Copy link
Owner

这属于掩耳盗铃吧,既然禁用了,接口都需要传入渠道的,这个渠道就是 h5,现在把h5禁了,那么接口肯定不会接收 h5渠道的了

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants