From af8b5b562eebf1ecb3e6732dc733cceedf682bf4 Mon Sep 17 00:00:00 2001 From: kylin L <452061493@qq.com> Date: Mon, 6 May 2024 16:10:39 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8A=A0=E5=85=A5=E8=B7=AF=E7=94=B1=E6=8B=A6?= =?UTF-8?q?=E6=88=AA=E5=99=A8=E5=B9=B6=E5=88=A4=E6=96=AD=E6=89=80=E6=9C=89?= =?UTF-8?q?=E5=8F=82=E6=95=B0=E5=80=BC=E7=9A=84=E9=95=BF=E5=BA=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/common/globalRouter.js | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/common/globalRouter.js b/src/common/globalRouter.js index df4220f..2eb98a1 100644 --- a/src/common/globalRouter.js +++ b/src/common/globalRouter.js @@ -30,7 +30,10 @@ $globalRouter.beforeEach((to, from, next) => { if (typeof to.query[key] === 'number' && !Number.isNaN(to.query[key])) { if (to.query[key].toString().length > 9) { to.query[key] = 0; - console.log(to.query[key]); + } + } else { + if (to.query[key].toString().length > 33) { + to.query[key] = 0; } } } @@ -41,7 +44,10 @@ $globalRouter.beforeEach((to, from, next) => { if (typeof to.params[key] === 'number' && !Number.isNaN(to.params[key])) { if (to.params[key].toString().length > 9) { to.params[key] = 0; - console.log(to.params[key]); + } + } else { + if (to.params[key].toString().length > 33) { + to.params[key] = 0; } } }