From fe560abb4eadf6fca541dcf915562402940beb38 Mon Sep 17 00:00:00 2001 From: NagendraOpsmx Date: Mon, 4 Mar 2024 15:38:46 +0530 Subject: [PATCH] encoded event listner msg earlier removed --- .../application-create-panel/application-create-panel.tsx | 2 +- .../components/applications-list/applications-list.tsx | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ui/src/app/applications/components/application-create-panel/application-create-panel.tsx b/ui/src/app/applications/components/application-create-panel/application-create-panel.tsx index acf804853a1b5..104d600594c06 100644 --- a/ui/src/app/applications/components/application-create-panel/application-create-panel.tsx +++ b/ui/src/app/applications/components/application-create-panel/application-create-panel.tsx @@ -131,7 +131,7 @@ export const ApplicationCreatePanel = (props: { }> {({projects, clusters, reposInfo}) => { if (pathHasOpsmx) { - window.parent.postMessage(window.btoa(JSON.stringify({msg:'loadEvent'})),'*') + window.parent.postMessage({msg:'loadEvent'},'*') } const repos = reposInfo.map(info => info.repo).sort(); const app = deepMerge(DEFAULT_APP, props.app || {}); diff --git a/ui/src/app/applications/components/applications-list/applications-list.tsx b/ui/src/app/applications/components/applications-list/applications-list.tsx index 9780c5d2d4bd5..7d2b4e27c1207 100644 --- a/ui/src/app/applications/components/applications-list/applications-list.tsx +++ b/ui/src/app/applications/components/applications-list/applications-list.tsx @@ -586,7 +586,7 @@ export const ApplicationsList = (props: RouteComponentProps<{}>) => { isShown={!!appInput} onClose={() => { if(pathHasOpsmx){ - window.parent.postMessage(window.btoa(JSON.stringify({msg:'closeEvent'})),'*') + window.parent.postMessage({msg:'closeEvent'},'*') } ctx.navigation.goto('.', {new: null}, {replace: true})}} header={ @@ -603,7 +603,7 @@ export const ApplicationsList = (props: RouteComponentProps<{}>) => { qe-id='applications-list-button-cancel' onClick={() => { if(pathHasOpsmx){ - window.parent.postMessage(window.btoa(JSON.stringify({msg:'closeEvent'})),'*') + window.parent.postMessage({msg:'closeEvent'},'*') } ctx.navigation.goto('.', {new: null}, {replace: true})}} className='argo-button argo-button--base-o'> @@ -622,7 +622,7 @@ export const ApplicationsList = (props: RouteComponentProps<{}>) => { await services.applications.create(app); //iframe msg alert needed if(pathHasOpsmx){ - window.parent.postMessage(window.btoa(JSON.stringify({msg:'saveEvent',appName:app['metadata']['name']})),'*') + window.parent.postMessage({msg:'saveEvent',appName:app['metadata']['name']},'*') } ctx.navigation.goto('.', {new: null}, {replace: true}); } catch (e) {