WIP modal

This commit is contained in:
jenny-s51 2021-01-08 13:04:58 -05:00
parent 3562cf8d57
commit 162146c371
3 changed files with 23 additions and 2 deletions

View file

@ -87,4 +87,4 @@ export const RealmRoleForm = ({
</ActionGroup>
</FormAccess>
);
};
};

View file

@ -71,6 +71,26 @@ export const RealmRolesSection = () => {
},
});
// const [toggleAssociatedRoleDialog, associatedRolesList] = useConfirmDialog({
// titleKey: "roles:associatedRolesModalTitle",
// messageKey: t("roles:roleDeleteConfirmDialog", {
// selectedRoleName: selectedRole ? selectedRole!.name : "",
// }),
// continueButtonLabel: t("Add"),
// continueButtonVariant: ButtonVariant.danger,
// onConfirm: async () => {
// try {
// await adminClient.roles.delById({
// id: selectedRole!.id!,
// });
// setSelectedRole(undefined);
// addAlert(t("roleDeletedSuccess"), AlertVariant.success);
// } catch (error) {
// addAlert(`${t("roleDeleteError")} ${error}`, AlertVariant.danger);
// }
// },
// });
const goToCreate = () => history.push(`${url}/add-role`);
return (
<>
@ -95,7 +115,7 @@ export const RealmRolesSection = () => {
setSelectedRole(role);
toggleDeleteDialog();
},
},
}
]}
columns={[
{

View file

@ -1,6 +1,7 @@
{
"roles": {
"attributes": "Attributes",
"add": "Add",
"addAttributeText": "Add an attribute",
"deleteAttributeText": "Delete an attribute",
"addAssociatedRolesText": "Add associated roles",