diff --git a/health/micro-ui/web/micro-ui-internals/packages/modules/campaign-manager/src/components/CampaignCard.js b/health/micro-ui/web/micro-ui-internals/packages/modules/campaign-manager/src/components/CampaignCard.js index 8b28d4eb125..1a662a87e2c 100644 --- a/health/micro-ui/web/micro-ui-internals/packages/modules/campaign-manager/src/components/CampaignCard.js +++ b/health/micro-ui/web/micro-ui-internals/packages/modules/campaign-manager/src/components/CampaignCard.js @@ -40,7 +40,7 @@ const CampaignCard = () => { }, { label: t("ACTION_TEST_SETUP_CAMPAIGN_FROM_MICROPLAN"), - link: `/${window?.contextPath}/employee/campaign/setup-microplan&userId=${userId}&status=${microplanStatus}`, + link: `/${window?.contextPath}/employee/campaign/setup-from-microplan&userId=${userId}&status=${microplanStatus}`, roles: ROLES.CAMPAIGN_MANAGER }, { diff --git a/health/micro-ui/web/micro-ui-internals/packages/modules/campaign-manager/src/components/CampaignType.js b/health/micro-ui/web/micro-ui-internals/packages/modules/campaign-manager/src/components/CampaignType.js index 2bc5e33d3e9..ca8c7bf4184 100644 --- a/health/micro-ui/web/micro-ui-internals/packages/modules/campaign-manager/src/components/CampaignType.js +++ b/health/micro-ui/web/micro-ui-internals/packages/modules/campaign-manager/src/components/CampaignType.js @@ -119,7 +119,7 @@ const CampaignSelection = ({ onSelect, formData, formState, ...props }) => {
{ - if (props?.props?.sessionData?.HCM_CAMPAIGN_TYPE?.projectType && !canUpdate && productType!=="microplan") { + if (props?.props?.sessionData?.HCM_CAMPAIGN_TYPE?.projectType && !canUpdate && source!=="microplan") { setShowPopUp(true); return; } diff --git a/health/micro-ui/web/micro-ui-internals/packages/modules/campaign-manager/src/pages/employee/MyMicroplans.js b/health/micro-ui/web/micro-ui-internals/packages/modules/campaign-manager/src/pages/employee/MyMicroplans.js index 89208ca7e09..40740c1d2ce 100644 --- a/health/micro-ui/web/micro-ui-internals/packages/modules/campaign-manager/src/pages/employee/MyMicroplans.js +++ b/health/micro-ui/web/micro-ui-internals/packages/modules/campaign-manager/src/pages/employee/MyMicroplans.js @@ -4,11 +4,24 @@ import { useTranslation } from "react-i18next"; import { useHistory } from "react-router-dom"; import { MicroplanCampaignSearchConfig } from "../../configs/myMicroplanConfig"; +// export const updateUrlParams=(params) =>{ +// const url = new URL(window.location.href); +// Object.entries(params).forEach(([key, value]) => { +// url.searchParams.set(key, value); +// }); +// window.history.replaceState({}, "", url); +// } + const MyMicroplans = () => { const { t } = useTranslation(); const history = useHistory(); + // const userId = Digit.UserService.getUser().info.uuid; + // const microplanStatus = "RESOURCE_ESTIMATIONS_APPROVED" + + // useEffect(() =>{ + // updateUrlParams({ userId: userId, status: microplanStatus }); + // },[]) const onClickRow = ({ original: row }) => { - console.log("row" , row); const updatedName = row.name.replace(/&/g, "and"); history.push(`/${window.contextPath}/employee/campaign/setup-campaign?id=${row.campaignId}&draft=true&fetchBoundary=true&draftBoundary=true&source=microplanµName=${updatedName}`); }; diff --git a/health/micro-ui/web/micro-ui-internals/packages/modules/campaign-manager/src/pages/employee/index.js b/health/micro-ui/web/micro-ui-internals/packages/modules/campaign-manager/src/pages/employee/index.js index 4a175150cb5..a3051b82ed0 100644 --- a/health/micro-ui/web/micro-ui-internals/packages/modules/campaign-manager/src/pages/employee/index.js +++ b/health/micro-ui/web/micro-ui-internals/packages/modules/campaign-manager/src/pages/employee/index.js @@ -151,7 +151,7 @@ const App = ({ path, BOUNDARY_HIERARCHY_TYPE, hierarchyData }) => { } /> } /> } /> - } /> + } />