-
Notifications
You must be signed in to change notification settings - Fork 113
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The libregraph public link type representation added to the PROPFIND response #4722
base: edge
Are you sure you want to change the base?
Conversation
// EDIT SharingLinkType = "edit" | ||
// CREATE_ONLY SharingLinkType = "createOnly" | ||
func (r *Role) OCSPermissionsToPublicLinkType(rt provider.ResourceType) string { | ||
p := r.OCSPermissions() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hm, I don't think we should converting this based on the OCS permissions here. OCS is going to go a away at some point (and r.OCSPermissions()
will hopefully go with it. IMO we should do the conversion based on the CS3ResourcePermissions.
In ocis (https://github.com/owncloud/ocis/blob/fc2318a5ef419c559a46fad41fbc22f6211f50ec/services/graph/pkg/linktype/linktype.go#L33) we already have function for converting ResourcePermissions to libregraph link types. Maybe we should move that into reva to make it reusable in graph and reva?
BTW, libregraph also defines a blocksDownload
type. Do need that here as well?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems like an obvious solution but it will lead to coping more code. Since LinkType is similar to UnifiedRoleDefinition and UnifiedRoleDefinition was moved from reva to graph, it seems to me there is no point in bringing back LinkType to reva. https://github.com/cs3org/reva/pull/4268/files
The blocksDownload
is not used.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@rhafer We could try to move the Link permission sets to the reva/pkg/convertions
and keep the LinkType
in a graph. Then we can use those sets for the permission conversations.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@micbar Could we separate the LinkType
and move the permission sets provider.ResourcePermissions
from the graph to the reva/pkg/conversions that allows converting based on the OCS permissions?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In would suggest the opposite. Move the ocdav service to ocis.
The libregraph public link type representation added to the PROPFIND response
Related issue #8740