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

Model modifier for root query and -to-many relations only #24

Open
IlyaSemenov opened this issue Jul 12, 2023 · 0 comments
Open

Model modifier for root query and -to-many relations only #24

IlyaSemenov opened this issue Jul 12, 2023 · 0 comments
Labels
enhancement New feature or request

Comments

@IlyaSemenov
Copy link
Owner

Currently, a model/table modifier runs for all queries against that model:

  • root query
  • -to-many relations
  • -to-one relations

In many cases, such as when using the modifier for sorting or limiting data access, running it for -to-one relations is useless.

I propose to add new r.model({ manyModifier }) (not sure about the naming) that will only run for root query and -to-many relations.

@IlyaSemenov IlyaSemenov added the enhancement New feature or request label Jul 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant