-
Story
-
Resolution: Unresolved
-
Major
-
None
-
None
-
5
-
False
-
True
-
XCMSTRAT-1005 - M2: htpasswd expanded UI
Description
An admin user that has the feature gate will be able to delete multiple users from an existing htpasswrd IDP with a single action (vs deleting each individually). There is a checkbox next to each user. Once at least one item is checked, a "Delete" button will be available. If no items are checked then the Delete button will not be visible. In addition, there will be a checkbox in the table header. When the checkbox is checked, all items on the current page will be checked. If this header checkbox is unchecked, then all checked checkboxes will be unchecked.
Note that if a user checks a user and then navigates to another pagination page, this checked user will be ignored.
When a user clicks on the "Delete" button, a modal is open. This modal will list up to the first 5 checked users on the current pagination page. If more than 5 users are checked, then at the bottom of the first five then the text "( X more )" will be shown where X is the number beyond the 5 shown that will be deleted.
When the user clicks on the "Delete users" button an API call will be made for each user to be deleted.. While the API calls are pending, a loading spinner is shown in the modal. During this pending time, the modal cannot be closed and the "Delete users" button will be disabled. If the API call returns all successes, the modal window is closed and the user table is refreshed. If any API call returns an error, the returned error(s) are shown in the modal. If any API call is successful, then the user table is updated when the modal closes (either automatically when all API calls are success or manually after the user has a chance to view the error).
Screenshots
h2. Technical notes
Since there isn't a bulk delete endpoint. An API call need to be made to
DELETE /api/clusters_mgmt/v1/clusters/{cluster_id}/identity_providers/{identity_provider_id}/htpasswd_users/{htpasswd_user_id
for each user.
The PatternFly patterns state that an inline confirmation alert is shown (see https://v5-archive.patternfly.org/patterns/actions#deletion ). The problem with this is that it will cause the other items on the page to "jump" when the alert disappears. Following other like actions (for example deleting a machine pool) no additional notification will be given to the user that the update was successful (beyond the closing of the modal).
- depends on
-
OCMUI-2966 View htpasswrd users on a htpassword details page
- In Progress
-
OCMUI-2970 Create feature gate to hide editing htpasswrd users
- Code Review