* Update API Keys UI to adjust based on users permissions
Since API Keys support now RBAC we need to ensure that UI
is adjusted based on the user permissions.
* Applying PR suggestions
(cherry picked from commit cbd2d09d70)
Co-authored-by: Vardan Torosyan <vardants@gmail.com>
This commit is contained in:
co-authored by
Vardan Torosyan
parent
8888dac836
commit
5de766a202
@@ -174,19 +174,15 @@ func (hs *HTTPServer) declareFixedRoles() error {
|
||||
DisplayName: "APIKeys writer",
|
||||
Description: "Gives access to add and delete api keys.",
|
||||
Group: "API Keys",
|
||||
Permissions: []ac.Permission{
|
||||
Permissions: ac.ConcatPermissions(apikeyReaderRole.Role.Permissions, []ac.Permission{
|
||||
{
|
||||
Action: ac.ActionAPIKeyCreate,
|
||||
},
|
||||
{
|
||||
Action: ac.ActionAPIKeyRead,
|
||||
Scope: ac.ScopeAPIKeysAll,
|
||||
},
|
||||
{
|
||||
Action: ac.ActionAPIKeyDelete,
|
||||
Scope: ac.ScopeAPIKeysAll,
|
||||
},
|
||||
},
|
||||
}),
|
||||
},
|
||||
Grants: []string{string(models.ROLE_ADMIN)},
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user