Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,10 @@ import { filterEntityGroupsBySearchTerm } from "IDE/utils";
import { useLocation } from "react-router";
import { getIDETypeByUrl } from "ee/entities/IDE/utils";
import { useParentEntityInfo } from "ee/IDE/hooks/useParentEntityInfo";
import { useCreateActionsPermissions } from "ee/entities/IDE/hooks/useCreateActionsPermissions";
import { JSEntity } from "ee/pages/AppIDE/components/JSListItem/ListItem";
import type { EntityItem } from "ee/IDE/Interfaces/EntityItem";
import { getPagePermissions } from "selectors/editorSelectors";
import { getHasCreateActionPermission } from "ee/utils/BusinessFeatures/permissionPageHelpers";

const JSContainer = styled(Flex)`
& .t--entity-item {
Expand All @@ -42,7 +43,12 @@ export const ListJSObjects = () => {
const location = useLocation();
const ideType = getIDETypeByUrl(location.pathname);
const { editorId, parentEntityId } = useParentEntityInfo(ideType);
const canCreateActions = useCreateActionsPermissions(ideType);
const isFeatureEnabled = useFeatureFlag(FEATURE_FLAG.license_gac_enabled);
const pagePermissions = useSelector(getPagePermissions);
const canCreateActions = getHasCreateActionPermission(
isFeatureEnabled,
pagePermissions,
);

const isNewADSTemplatesEnabled = useFeatureFlag(
FEATURE_FLAG.release_ads_entity_item_enabled,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,10 @@ import { ActionEntityItem } from "ee/pages/AppIDE/components/QueryEntityItem/Lis
import { useLocation } from "react-router";
import { getIDETypeByUrl } from "ee/entities/IDE/utils";
import { useParentEntityInfo } from "ee/IDE/hooks/useParentEntityInfo";
import { useCreateActionsPermissions } from "ee/entities/IDE/hooks/useCreateActionsPermissions";
import { objectKeys } from "@appsmith/utils";
import type { EntityItem } from "ee/IDE/Interfaces/EntityItem";
import { getPagePermissions } from "selectors/editorSelectors";
import { getHasCreateActionPermission } from "ee/utils/BusinessFeatures/permissionPageHelpers";

export const ListQuery = () => {
const [searchTerm, setSearchTerm] = useState("");
Expand All @@ -36,7 +37,12 @@ export const ListQuery = () => {
const location = useLocation();
const ideType = getIDETypeByUrl(location.pathname);
const { editorId, parentEntityId } = useParentEntityInfo(ideType);
const canCreateActions = useCreateActionsPermissions(ideType);
const isFeatureEnabled = useFeatureFlag(FEATURE_FLAG.license_gac_enabled);
const pagePermissions = useSelector(getPagePermissions);
const canCreateActions = getHasCreateActionPermission(
isFeatureEnabled,
pagePermissions,
);

const showWorkflows = useSelector(getShowWorkflowFeature);

Expand Down
Loading