Skip to content

Commit

Permalink
EES-5568 Adding modal for admins deleting users (#5342)
Browse files Browse the repository at this point in the history
* EES-5568 Adding modal for admins deleting users

* EES-5568 Removing the custom `DeleteUserModal.tsx` component, and using the `ModalConfirm.tsx` component directly inside the `BauUsersPage`

* EES-5568 Updating comment
  • Loading branch information
jack-hive authored Oct 23, 2024
1 parent dca9ec2 commit cf62a0d
Showing 1 changed file with 19 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@ import styles from './BauUsersPage.module.scss';
const BauUsersPage = () => {
const { value, isLoading } = useAsyncRetry(() => userService.getUsers());

// const handleDeleteUser = async (userEmail: string) => { // EES-5573
// EES-5573
// const handleDeleteUser = async (userEmail: string) => {
// await userService
// .deleteUser(userEmail)
// .then(() => {
Expand Down Expand Up @@ -56,12 +57,23 @@ const BauUsersPage = () => {
Manage
</Link>
{/* EES-5573 */}
{/* <ButtonText */}
{/* onClick={() => handleDeleteUser(user.email)} */}
{/* className={styles.deleteUserButton} */}
{/* > */}
{/* Delete */}
{/* </ButtonText> */}
{/* <ModalConfirm
title="Confirm you want to delete this user"
triggerButton={
<ButtonText className={styles.deleteUserButton}>
Delete
</ButtonText>
}
onConfirm={async () => await handleDeleteUser(user.email)}
>
<p>
By deleting this User you will remove all access and
permissions they have on the service. This change cannot
be reversed. Users who are removed and then need access
at a later point will need to be re-invited to the
service as a new user.
</p>
</ModalConfirm> */}
</td>
</tr>
))}
Expand Down

0 comments on commit cf62a0d

Please sign in to comment.