Remove unwanted workflow fetch on right drawer open (#13122)

There was a mistake in the ActionConfig load, we were trying to fetch a
workflow with the opened recordId (which is not always a workflow)
This commit is contained in:
Charles Bochet
2025-07-09 13:12:46 +02:00
committed by GitHub
parent 44b9990ba7
commit 0316c857d8

View File

@ -9,7 +9,6 @@ import { useShouldActionBeRegisteredParams } from '@/action-menu/hooks/useShould
import { contextStoreTargetedRecordsRuleComponentState } from '@/context-store/states/contextStoreTargetedRecordsRuleComponentState'; import { contextStoreTargetedRecordsRuleComponentState } from '@/context-store/states/contextStoreTargetedRecordsRuleComponentState';
import { ObjectMetadataItem } from '@/object-metadata/types/ObjectMetadataItem'; import { ObjectMetadataItem } from '@/object-metadata/types/ObjectMetadataItem';
import { useRecoilComponentValueV2 } from '@/ui/utilities/state/component-state/hooks/useRecoilComponentValueV2'; import { useRecoilComponentValueV2 } from '@/ui/utilities/state/component-state/hooks/useRecoilComponentValueV2';
import { useWorkflowWithCurrentVersion } from '@/workflow/hooks/useWorkflowWithCurrentVersion';
export const ActionMenuContextProviderWorkflowsEnabled = ({ export const ActionMenuContextProviderWorkflowsEnabled = ({
objectMetadataItem, objectMetadataItem,
@ -28,13 +27,8 @@ export const ActionMenuContextProviderWorkflowsEnabled = ({
objectMetadataItem, objectMetadataItem,
}); });
const workflowWithCurrentVersion = useWorkflowWithCurrentVersion(
params.selectedRecord?.id,
);
const shouldBeRegisteredParams = { const shouldBeRegisteredParams = {
...params, ...params,
workflowWithCurrentVersion,
}; };
const actions = useRegisteredActions(shouldBeRegisteredParams); const actions = useRegisteredActions(shouldBeRegisteredParams);