Skip to content

Commit

Permalink
DEVPROD-4665 Disable performance plugin selection at repo level (#98)
Browse files Browse the repository at this point in the history
  • Loading branch information
khelif96 authored May 2, 2024
1 parent 3d3d4db commit 544b709
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ export const PluginsTab: React.FC<TabProps> = ({
const formSchema = useMemo(
() =>
getFormSchema(
projectType === ProjectType.Repo,
jiraEmail,
projectType === ProjectType.AttachedProject ? repoData : null,
),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ const requesters = [
];

export const getFormSchema = (
isRepo: boolean,
jiraEmail?: string,
repoData?: PluginsFormState,
): ReturnType<GetFormSchema> => ({
Expand Down Expand Up @@ -225,8 +226,8 @@ export const getFormSchema = (
"ui:ObjectFieldTemplate": CardFieldTemplate,
perfEnabled: {
"ui:widget": widgets.RadioBoxWidget,
"ui:description":
"Enable the performance plugin (this requires the project to have matching ID and identifier).",
"ui:disabled": isRepo,
"ui:description": `Enable the performance plugin (this requires the project to have matching ID and identifier). ${isRepo && "This setting is disabled at the repo level."}`,
},
},
buildBaronSettings: {
Expand Down

0 comments on commit 544b709

Please sign in to comment.