-
-
Notifications
You must be signed in to change notification settings - Fork 179
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
Allow nested relationship pagination #1035
Labels
enhancement
New feature or request
Comments
This would be a welcome feature. I attempted to add this a long time ago, but the codebase wasn't in a good place for that. In its current state, I think it is much more doable. There may be some finicky bits since what must currently be a list could now be a page, but we can work those things out without too much hassle I think. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Is your feature request related to a problem? Please describe.
This is a presequisite for ash-project/ash_graphql#131, opening it here to focus the discussion on the core part
Describe the solution you'd like
It should be possible to paginate a relationship by passing an appropriate
Query
. This would allow to have pagination for nested relationships for extensions that support this (like, potentially, AshGraphql).Express the feature either with a change to resource syntax, or with a change to the resource interface
Right now the only place where pagination can be configured is in action options, i.e. passing
page: [offset: 3, limit: 10]
toAsh.read
or similar functions. To be able to setup pagination in nested loads, we will probably have to add some function and/or option onQuery
(andChangeset
, since those have loads too). This should be similar to what is already done with, e.g.,tenant
, which can be set both on theQuery
and as an action option.Potential syntax:
The text was updated successfully, but these errors were encountered: