adjusted logic to cater for viewl all path and dnsapplications

This commit is contained in:
2026-03-11 10:40:48 +00:00
parent 9c483ec655
commit f947821afa
3 changed files with 210 additions and 300 deletions
+21 -2
View File
@@ -326,6 +326,27 @@ const CaseSummary = (props) => {
const buildSearchHref = (router, session) => {
const { va, adv, ads, key } = router.query;
console.log(router);
const isDnsRoute =
router.pathname === "/dns" ||
router.pathname.startsWith("/dns/") ||
router.pathname === "/myportal/dns" ||
router.pathname.startsWith("/myportal/dns/");
const base = session ? "/myportal" : "";
if (!va && !adv && !ads) {
return {
pathname: "/myportal"
};
}
if (isDnsRoute) {
return {
pathname: `${base}/dnsapplications`
};
}
if (va === "true") {
return {
@@ -334,8 +355,6 @@ const CaseSummary = (props) => {
};
}
const base = session ? "/myportal" : "";
if (adv === "true") {
return {
pathname: `${base}/advancedsearchresults`,