mirror of
https://github.com/ansible/awx.git
synced 2026-01-11 01:57:35 -03:30
Merge pull request #9588 from AlexSCorey/9456-9466-UserAndTeamsAccessAdd
Fixes a bug with ResourceAccess Add SUMMARY This addresses #9456 and #9466 The user can now properly add roles to a resource. ISSUE TYPE Bugfix Pull Request COMPONENT NAME UI ADDITIONAL INFORMATION Reviewed-by: Kersom <None> Reviewed-by: Jake McDermott <yo@jakemcdermott.me>
This commit is contained in:
commit
fa3e55be91
@ -54,8 +54,9 @@ function AddResourceRole({ onSave, onClose, roles, i18n, resource, onError }) {
|
||||
);
|
||||
|
||||
if (selectedIndex > -1) {
|
||||
selectedRoleRows.splice(selectedIndex, 1);
|
||||
setSelectedRoleRows(selectedRoleRows);
|
||||
setSelectedRoleRows(
|
||||
selectedRoleRows.filter((r, index) => index !== selectedIndex)
|
||||
);
|
||||
} else {
|
||||
setSelectedRoleRows([...selectedRoleRows, role]);
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user