diff --git a/changelog/unreleased/update-roles.md b/changelog/unreleased/update-roles.md new file mode 100644 index 00000000000..9fbba0aca50 --- /dev/null +++ b/changelog/unreleased/update-roles.md @@ -0,0 +1,5 @@ +Bugfix: Update the default admin role + +The admin role was missing two permissions. We added them to make the space admin role a subset of the admin role. This matches better with the default user expectations. + +https://github.com/owncloud/ocis/pull/6310 diff --git a/services/settings/pkg/store/defaults/defaults.go b/services/settings/pkg/store/defaults/defaults.go index 241bc8bd6e7..3e078f65d46 100644 --- a/services/settings/pkg/store/defaults/defaults.go +++ b/services/settings/pkg/store/defaults/defaults.go @@ -345,6 +345,36 @@ func generateBundleAdminRole() *settingsmsg.Bundle { }, }, }, + { + Id: ManageSpacePropertiesPermissionID, + Name: ManageSpacePropertiesPermissionName, + DisplayName: "Manage space properties", + Description: "This permission allows to manage space properties such as name and description.", + Resource: &settingsmsg.Resource{ + Type: settingsmsg.Resource_TYPE_SYSTEM, + }, + Value: &settingsmsg.Setting_PermissionValue{ + PermissionValue: &settingsmsg.Permission{ + Operation: settingsmsg.Permission_OPERATION_READWRITE, + Constraint: settingsmsg.Permission_CONSTRAINT_ALL, + }, + }, + }, + { + Id: SpaceAbilityPermissionID, + Name: SpaceAbilityPermissionName, + DisplayName: "Space ability", + Description: "This permission allows to enable and disable spaces.", + Resource: &settingsmsg.Resource{ + Type: settingsmsg.Resource_TYPE_SYSTEM, + }, + Value: &settingsmsg.Setting_PermissionValue{ + PermissionValue: &settingsmsg.Permission{ + Operation: settingsmsg.Permission_OPERATION_READWRITE, + Constraint: settingsmsg.Permission_CONSTRAINT_ALL, + }, + }, + }, }, } } diff --git a/tests/acceptance/expected-failures-localAPI-on-OCIS-storage.md b/tests/acceptance/expected-failures-localAPI-on-OCIS-storage.md index 793d3b1d596..3e4b34d7003 100644 --- a/tests/acceptance/expected-failures-localAPI-on-OCIS-storage.md +++ b/tests/acceptance/expected-failures-localAPI-on-OCIS-storage.md @@ -175,10 +175,6 @@ The expected failures in this file are from features in the owncloud/ocis repo. - [apiGraph/addUserToGroup.feature:370](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiGraph/addUserToGroup.feature#L370) - [apiGraph/addUserToGroup.feature:384](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiGraph/addUserToGroup.feature#L384) -#### [Admin user can't restore other user spaces](https://github.com/owncloud/ocis/issues/5872) - -- [apiSpaces/restoreSpaces.feature:93](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiSpaces/restoreSpaces.feature#L93) - ### [Adding the same user as multiple members in a single request results in listing the same user twice in the group](https://github.com/owncloud/ocis/issues/5855) - [apiGraph/addUserToGroup.feature:421](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiGraph/addUserToGroup.feature#L421)