Skip to content
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

[Feature Request] check() function support for to-many relations #1688

Open
jason-curtis opened this issue Sep 6, 2024 · 0 comments
Open

Comments

@jason-curtis
Copy link

As explained in this blog post, the check() function is a great way to simplify access rules with complex sets of models. However it is not implemented yet for to-many relations.

Describe the solution you'd like
Much like check(author) checks if the model referenced by the author field is accessible, check(children?) should check if any of the related children are accessible. Other Collection Predicate Expressions should work similarly.

Other syntax options are also discussed in the blog post and its comment thread: zenstackhq/zenstack-docs#360

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant