From 6c7bba2e05c011a3d640b6565a113204228e92e0 Mon Sep 17 00:00:00 2001 From: zhaojs <349234519@qq.com> Date: 星期六, 07 十月 2023 10:58:36 +0800 Subject: [PATCH] Merge tag '首页猜你喜欢修复' into develop --- public/html/mttran.html | 15 ++++++++++++--- 1 files changed, 12 insertions(+), 3 deletions(-) diff --git a/public/html/mttran.html b/public/html/mttran.html index 2a47a4f..dadc47a 100644 --- a/public/html/mttran.html +++ b/public/html/mttran.html @@ -31,9 +31,18 @@ methods:{ getEn:function() { - uni.getEnv(function(res){ - alert(JSON.stringify(res)); - }); + // uni.getEnv(function(res){ + // alert(JSON.stringify(res)); + // }); + const userAgent = navigator.userAgent.toLowerCase(); + const iswx = userAgent.match(/weixin/i); + if(iswx) + { + window.location.href="https://click.meituan.com/t?t=1&c=2&p=jqgHar5zidEL"; + } + else{ + window.location.href="imeituan://www.meituan.com/web?lch=cps:waimai:3:65c5f4b9271221c79eae104d969a48a3:94691jutuike123456:33:85459&url=https%3A%2F%2Fclick.meituan.com%2Ft%3Ft%3D1%26c%3D2%26p%3Dhl8Lar5zidEL"; + } } }, mounted:function() -- Gitblit v1.9.3