Skip to content

Commit

Permalink
feat: disableCreate of resourceQuotas on all namespaces overview
Browse files Browse the repository at this point in the history
  • Loading branch information
chriskari committed Sep 13, 2024
1 parent eb30dcc commit aa61305
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions src/resources/Namespaces/AllNamespacesDetails.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ export function AllNamespacesDetails() {
namespace: '-all-',
isCompact: true,
showTitle: true,
disableCreate: true,
};

const ResourceQuotasList = (
Expand Down
4 changes: 2 additions & 2 deletions src/resources/ResourceQuotas/ResourceQuotasList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ export function ResourceQuotasList(props: any) {
);
};

const createButton = (
const createButton = !props?.disableCreate ? (
<Button
key={`create-resource-quotas`}
data-testid={`create-resource-quotas`}
Expand All @@ -70,7 +70,7 @@ export function ResourceQuotasList(props: any) {
>
{t('components.resources-list.create')}
</Button>
);
) : null;

return (
<ResourcesList
Expand Down

0 comments on commit aa61305

Please sign in to comment.