mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-07 19:28:09 +00:00
rename org admin console subject name
This commit is contained in:
@@ -27,7 +27,7 @@ export enum OrgPermissionSubjects {
|
|||||||
SecretScanning = "secret-scanning",
|
SecretScanning = "secret-scanning",
|
||||||
Identity = "identity",
|
Identity = "identity",
|
||||||
Kms = "kms",
|
Kms = "kms",
|
||||||
AdminConsole = "admin-console"
|
AdminConsole = "organization-admin-console"
|
||||||
}
|
}
|
||||||
|
|
||||||
export type OrgPermissionSet =
|
export type OrgPermissionSet =
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ export enum OrgPermissionSubjects {
|
|||||||
SecretScanning = "secret-scanning",
|
SecretScanning = "secret-scanning",
|
||||||
Identity = "identity",
|
Identity = "identity",
|
||||||
Kms = "kms",
|
Kms = "kms",
|
||||||
AdminConsole = "admin-console"
|
AdminConsole = "organization-admin-console"
|
||||||
}
|
}
|
||||||
|
|
||||||
export enum OrgPermissionAdminConsoleAction {
|
export enum OrgPermissionAdminConsoleAction {
|
||||||
|
|||||||
@@ -44,7 +44,7 @@ export const formSchema = z.object({
|
|||||||
ldap: generalPermissionSchema,
|
ldap: generalPermissionSchema,
|
||||||
billing: generalPermissionSchema,
|
billing: generalPermissionSchema,
|
||||||
identity: generalPermissionSchema,
|
identity: generalPermissionSchema,
|
||||||
"admin-console": adminConsolePermissionSchmea
|
"organization-admin-console": adminConsolePermissionSchmea
|
||||||
})
|
})
|
||||||
.optional()
|
.optional()
|
||||||
});
|
});
|
||||||
|
|||||||
+5
-5
@@ -29,7 +29,7 @@ export const OrgPermissionAdminConsoleRow = ({ isEditable, control, setValue }:
|
|||||||
|
|
||||||
const rule = useWatch({
|
const rule = useWatch({
|
||||||
control,
|
control,
|
||||||
name: "permissions.admin-console"
|
name: "permissions.organization-admin-console"
|
||||||
});
|
});
|
||||||
|
|
||||||
const selectedPermissionCategory = useMemo(() => {
|
const selectedPermissionCategory = useMemo(() => {
|
||||||
@@ -62,7 +62,7 @@ export const OrgPermissionAdminConsoleRow = ({ isEditable, control, setValue }:
|
|||||||
|
|
||||||
if (val === Permission.NoAccess) {
|
if (val === Permission.NoAccess) {
|
||||||
setValue(
|
setValue(
|
||||||
"permissions.admin-console",
|
"permissions.organization-admin-console",
|
||||||
{ "access-all-projects": false },
|
{ "access-all-projects": false },
|
||||||
{ shouldDirty: true }
|
{ shouldDirty: true }
|
||||||
);
|
);
|
||||||
@@ -102,8 +102,8 @@ export const OrgPermissionAdminConsoleRow = ({ isEditable, control, setValue }:
|
|||||||
{PERMISSION_ACTIONS.map(({ action, label }) => {
|
{PERMISSION_ACTIONS.map(({ action, label }) => {
|
||||||
return (
|
return (
|
||||||
<Controller
|
<Controller
|
||||||
name={`permissions.admin-console.${action}`}
|
name={`permissions.organization-admin-console.${action}`}
|
||||||
key={`permissions.admin-console.${action}`}
|
key={`permissions.organization-admin-console.${action}`}
|
||||||
control={control}
|
control={control}
|
||||||
render={({ field }) => (
|
render={({ field }) => (
|
||||||
<Checkbox
|
<Checkbox
|
||||||
@@ -118,7 +118,7 @@ export const OrgPermissionAdminConsoleRow = ({ isEditable, control, setValue }:
|
|||||||
}
|
}
|
||||||
field.onChange(e);
|
field.onChange(e);
|
||||||
}}
|
}}
|
||||||
id={`permissions.admin-console.${action}`}
|
id={`permissions.organization-admin-console.${action}`}
|
||||||
>
|
>
|
||||||
{label}
|
{label}
|
||||||
</Checkbox>
|
</Checkbox>
|
||||||
|
|||||||
+1
-1
@@ -112,7 +112,7 @@ export const OrgRoleWorkspaceRow = ({ isEditable, control, setValue }: Props) =>
|
|||||||
}
|
}
|
||||||
field.onChange(e);
|
field.onChange(e);
|
||||||
}}
|
}}
|
||||||
id={`permissions.admin-console.${action}`}
|
id={`permissions.organization-admin-console.${action}`}
|
||||||
>
|
>
|
||||||
{label}
|
{label}
|
||||||
</Checkbox>
|
</Checkbox>
|
||||||
|
|||||||
+1
-1
@@ -63,7 +63,7 @@ type Props = {
|
|||||||
title: string;
|
title: string;
|
||||||
formName: keyof Omit<
|
formName: keyof Omit<
|
||||||
Exclude<TFormSchema["permissions"], undefined>,
|
Exclude<TFormSchema["permissions"], undefined>,
|
||||||
"workspace" | "admin-console"
|
"workspace" | "organization-admin-console"
|
||||||
>;
|
>;
|
||||||
setValue: UseFormSetValue<TFormSchema>;
|
setValue: UseFormSetValue<TFormSchema>;
|
||||||
control: Control<TFormSchema>;
|
control: Control<TFormSchema>;
|
||||||
|
|||||||
Reference in New Issue
Block a user