From 9167a05b1ba719434591660c76174e5c5baeeb09 Mon Sep 17 00:00:00 2001 From: hja <2684946387@qq.com> Date: Wed, 28 Jul 2021 17:51:57 +0800 Subject: [PATCH] =?UTF-8?q?=E9=80=9A=E7=94=A8=E4=B8=8B=E8=BD=BDExcel?= =?UTF-8?q?=EF=BC=8C=E5=8F=AA=E8=A6=81=E6=9F=A5=E8=AF=A2=E5=8F=82=E6=95=B0?= =?UTF-8?q?=E7=BB=99params=E5=B1=9E=E6=80=A7=E4=BC=A0=E4=BA=86=E5=8F=82?= =?UTF-8?q?=EF=BC=8C=E5=AF=BC=E5=87=BA=E5=B0=B1=E4=BC=9A=E6=8A=A5=E9=94=99?= =?UTF-8?q?=E3=80=82=20=E9=97=AE=E9=A2=98=E5=87=BA=E7=8E=B0=E5=9C=A8?= =?UTF-8?q?=E5=8F=82=E6=95=B0=E8=BD=AC=E6=8D=A2=E3=80=82ruoyi.js=E6=96=87?= =?UTF-8?q?=E4=BB=B6185=E8=A1=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ruoyi-ui/src/utils/ruoyi.js | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/ruoyi-ui/src/utils/ruoyi.js b/ruoyi-ui/src/utils/ruoyi.js index 9d5c3723..2b20df4b 100644 --- a/ruoyi-ui/src/utils/ruoyi.js +++ b/ruoyi-ui/src/utils/ruoyi.js @@ -183,6 +183,17 @@ export function tansParams(params) { Object.keys(params).forEach((key) => { if (!Object.is(params[key], undefined) && !Object.is(params[key], null) && !Object.is(JSON.stringify(params[key]), '{}')) { // result += encodeURIComponent(key) + '=' + encodeURIComponent(params[key]) + '&' + if(key != 'params'){ + result += encodeURIComponent(key) + '=' + encodeURIComponent(params[key]) + '&' + } + if(key === 'params'){ + let p = params[key]; + Object.keys(p).forEach((k) => { + if(!Object.is(p[k], undefined) && !Object.is(p[k], null)){ + result += encodeURIComponent(key) + encodeURIComponent('[') + encodeURIComponent(k) + encodeURIComponent(']') + '=' + encodeURIComponent(p[k]) + '&' + } + }) + } } }) return result