From 4416addc3154d32005db1105133821e7c553e8ba Mon Sep 17 00:00:00 2001 From: al Date: Wed, 24 Jul 2024 13:57:22 +0800 Subject: [PATCH] JSON.parse(currentBaseCode) --- app/bill/[type]/page.jsx | 2 +- app/pay/page.jsx | 2 +- app/vip/page.jsx | 2 +- app/zone/pay/[zid]/[product_id]/[moment_id]/page.jsx | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app/bill/[type]/page.jsx b/app/bill/[type]/page.jsx index 2d88c33..eb89278 100644 --- a/app/bill/[type]/page.jsx +++ b/app/bill/[type]/page.jsx @@ -15,7 +15,7 @@ export default function BillDetail({ params }) { let searchParamsObj=null; let currentBaseCode = searchParams.get("base") if(currentBaseCode){ - let currentBase = decodeURIComponent(currentBaseCode); + let currentBase = JSON.parse(currentBaseCode); searchParamsObj={...currentBase}; } return searchParamsObj || webviewBase; diff --git a/app/pay/page.jsx b/app/pay/page.jsx index 3101249..8fe2f16 100644 --- a/app/pay/page.jsx +++ b/app/pay/page.jsx @@ -48,7 +48,7 @@ export default function Pay() { let searchParamsObj=null; let currentBaseCode = searchParams.get("base") if(currentBaseCode){ - let currentBase = decodeURIComponent(currentBaseCode); + let currentBase = JSON.parse(currentBaseCode); searchParamsObj={...currentBase}; } return searchParamsObj || webviewBase; diff --git a/app/vip/page.jsx b/app/vip/page.jsx index 4da7c99..80be7e8 100644 --- a/app/vip/page.jsx +++ b/app/vip/page.jsx @@ -28,7 +28,7 @@ export default function Vip() { let searchParamsObj=null; let currentBaseCode = searchParams.get("base") if(currentBaseCode){ - let currentBase = decodeURIComponent(currentBaseCode); + let currentBase = JSON.parse(currentBaseCode); searchParamsObj={...currentBase}; } return searchParamsObj || webviewBase; diff --git a/app/zone/pay/[zid]/[product_id]/[moment_id]/page.jsx b/app/zone/pay/[zid]/[product_id]/[moment_id]/page.jsx index d91cb4f..f58cb30 100644 --- a/app/zone/pay/[zid]/[product_id]/[moment_id]/page.jsx +++ b/app/zone/pay/[zid]/[product_id]/[moment_id]/page.jsx @@ -20,7 +20,7 @@ export default function Pay({ params }) { let searchParamsObj=null; let currentBaseCode = searchParams.get("base") if(currentBaseCode){ - let currentBase = decodeURIComponent(currentBaseCode); + let currentBase = JSON.parse(currentBaseCode); searchParamsObj={...currentBase}; } return searchParamsObj || webviewBase;