From 28c247b39b0e031088532e7be36c28452413a73a Mon Sep 17 00:00:00 2001 From: mukund-egov Date: Thu, 12 Sep 2024 11:23:40 +0530 Subject: [PATCH 1/2] Redirected all citizen redundant pages to employee page --- .../web/micro-ui-internals/packages/modules/core/src/App.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/micro-ui/web/micro-ui-internals/packages/modules/core/src/App.js b/frontend/micro-ui/web/micro-ui-internals/packages/modules/core/src/App.js index 100884bb5..d83ffb90d 100644 --- a/frontend/micro-ui/web/micro-ui-internals/packages/modules/core/src/App.js +++ b/frontend/micro-ui/web/micro-ui-internals/packages/modules/core/src/App.js @@ -4,7 +4,7 @@ import CitizenApp from "./pages/citizen"; import EmployeeApp from "./pages/employee"; import CommonApp from "./pages/common"; -export const DigitApp = ({ stateCode, modules, appTenants, logoUrl, initData, defaultLanding = "citizen" }) => { +export const DigitApp = ({ stateCode, modules, appTenants, logoUrl, initData, defaultLanding = "employee" }) => { const history = useHistory(); const { pathname } = useLocation(); const innerWidth = window.innerWidth; @@ -71,7 +71,7 @@ export const DigitApp = ({ stateCode, modules, appTenants, logoUrl, initData, de - + From c4c86ff54efe03992032616524ecae6f65feb850 Mon Sep 17 00:00:00 2001 From: mukund-egov Date: Thu, 12 Sep 2024 12:34:51 +0530 Subject: [PATCH 2/2] Corrected the citizen/payment issue --- .../packages/modules/core/src/App.js | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/frontend/micro-ui/web/micro-ui-internals/packages/modules/core/src/App.js b/frontend/micro-ui/web/micro-ui-internals/packages/modules/core/src/App.js index d83ffb90d..a2fec0412 100644 --- a/frontend/micro-ui/web/micro-ui-internals/packages/modules/core/src/App.js +++ b/frontend/micro-ui/web/micro-ui-internals/packages/modules/core/src/App.js @@ -65,13 +65,22 @@ export const DigitApp = ({ stateCode, modules, appTenants, logoUrl, initData, de pathname, initData, }; + + // Do not redirect if it's a payment route under citizen + const shouldRedirectToEmployee = () => { + if (pathname.startsWith(`/${window?.contextPath}/citizen/payment`)) { + return false; + } + return true; + }; + return ( - + {shouldRedirectToEmployee() ? : }