-
Notifications
You must be signed in to change notification settings - Fork 18
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
Add config to lock video ACLs to their series #1305
Conversation
This comment has been minimized.
This comment has been minimized.
This comment was marked as resolved.
This comment was marked as resolved.
3d53a9f
to
119ad94
Compare
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.
I tested it and it works very well, no problems found there!
I found a few minor code things, but unfortunately also a bigger one (due to a n+1 query problem). That will require a bit of frontend change as well, but shouldn't be too terrible.
119ad94
to
b0490c8
Compare
const data = await fetchQuery<UploadSeriesAclQuery>( | ||
environment, | ||
SeriesAclQuery, | ||
{ seriesId } | ||
).toPromise(); |
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.
I think useQueryLoader
is more idiomatic here? :/ But mhhh not sure if it's worth it changing that. It would also change the UX a bit: the ACL UI would be completely hidden while loading instead of showing the old value. Not sure if thats better or worse. So yeah no hard opinion, we can probably just keep it...
This pull request has conflicts ☹ |
With this enabled, event ACLs can't be edited and will generally be determined by their series.
b0490c8
to
34f9159
Compare
And then also disable ACL editing and attachment. In a previous iteration, this was using a suboptimal approach where each series returned by the API would send an additional query to get the series ACL. Now this only sends a single additional query whenever a series is actually selected. While this requires more code, a good amount of it is just state management and error handling/reporting. The rest is related to the data fetching.
34f9159
to
b3a10b3
Compare
This will disable ACL editing for the uploader and the ACL UI when the video is part of a series.
Uploaded videos will then adopt the ACL of that series.
This needs to be configured with
lock_acl_to_series
, the default for this isfalse
.Closes #1006