forked from appsmithorg/appsmith
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'appsmithorg:release' into release
- Loading branch information
Showing
150 changed files
with
1,477 additions
and
605 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
import { ActionParentEntityType } from "ee/entities/Engine/actionHelpers"; | ||
import type { IDEType } from "ee/entities/IDE/constants"; | ||
import { useSelector } from "react-redux"; | ||
import { | ||
getCurrentApplicationId, | ||
getCurrentBasePageId, | ||
} from "selectors/editorSelectors"; | ||
|
||
// eslint-disable-next-line @typescript-eslint/no-unused-vars | ||
export const useParentEntityInfo = (ideType: IDEType) => { | ||
const appId = useSelector(getCurrentApplicationId); | ||
const basePageId = useSelector(getCurrentBasePageId); | ||
|
||
return { | ||
editorId: appId || "", | ||
parentEntityId: basePageId || "", | ||
parentEntityType: ActionParentEntityType.PAGE, | ||
}; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
app/client/src/ce/entities/IDE/hooks/useCreateActionsPermissions.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import { useFeatureFlag } from "utils/hooks/useFeatureFlag"; | ||
import { IDE_TYPE, type IDEType } from "ee/entities/IDE/constants"; | ||
import { FEATURE_FLAG } from "ee/entities/FeatureFlag"; | ||
import { useSelector } from "react-redux"; | ||
import { getPagePermissions } from "selectors/editorSelectors"; | ||
import { getHasCreateActionPermission } from "ee/utils/BusinessFeatures/permissionPageHelpers"; | ||
|
||
export const useCreateActionsPermissions = (ideType: IDEType) => { | ||
const isFeatureEnabled = useFeatureFlag(FEATURE_FLAG.license_gac_enabled); | ||
const pagePermissions = useSelector(getPagePermissions); | ||
|
||
switch (ideType) { | ||
case IDE_TYPE.App: { | ||
return getHasCreateActionPermission(isFeatureEnabled, pagePermissions); | ||
} | ||
default: { | ||
return true; | ||
} | ||
} | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.