From 218a32a49fb758853a687f4a756a99ae4b8f83eb Mon Sep 17 00:00:00 2001 From: testa113 Date: Thu, 14 Dec 2023 16:52:00 +1300 Subject: [PATCH] po feedback --- .../components/form-components/FormSection/FormSection.tsx | 4 ++-- .../components/RedeployGitAppForm/RedeployGitAppForm.tsx | 5 +++++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/app/react/components/form-components/FormSection/FormSection.tsx b/app/react/components/form-components/FormSection/FormSection.tsx index ec09cdcea..2aeecd287 100644 --- a/app/react/components/form-components/FormSection/FormSection.tsx +++ b/app/react/components/form-components/FormSection/FormSection.tsx @@ -1,5 +1,5 @@ import { PropsWithChildren, ReactNode, useState } from 'react'; -import { ChevronUp, ChevronRight } from 'lucide-react'; +import { ChevronUp, ChevronDown } from 'lucide-react'; import { Icon } from '@@/Icon'; @@ -42,7 +42,7 @@ export function FormSection({ className="mx-2 !ml-0 inline-flex w-2 items-center justify-center border-0 bg-transparent" > diff --git a/app/react/kubernetes/applications/components/RedeployGitAppForm/RedeployGitAppForm.tsx b/app/react/kubernetes/applications/components/RedeployGitAppForm/RedeployGitAppForm.tsx index b33796fcd..ab9552025 100644 --- a/app/react/kubernetes/applications/components/RedeployGitAppForm/RedeployGitAppForm.tsx +++ b/app/react/kubernetes/applications/components/RedeployGitAppForm/RedeployGitAppForm.tsx @@ -1,6 +1,7 @@ import { Form, Formik, FormikHelpers, useFormikContext } from 'formik'; import { useRef, useState } from 'react'; import { RefreshCw } from 'lucide-react'; +import { useRouter } from '@uirouter/react'; import { Stack, StackId } from '@/react/common/stacks/types'; import { @@ -192,6 +193,7 @@ function RedeployGitAppInnerForm({ namespaceName: string; webhookId: string; }) { + const router = useRouter(); const environmentId = useEnvironmentId(); const redeployKubeGitStackMutation = useRedeployKubeGitStackMutation( stack.Id, @@ -323,6 +325,9 @@ function RedeployGitAppInnerForm({ await redeployKubeGitStackMutation.mutateAsync(redeployPayload, { onSuccess: () => { notifySuccess('Success', 'Application redeployed successfully.'); + router.stateService.go('kubernetes.applications.application', { + id: stack.Id, + }); }, });