statamic / ideas

💡Discussions on ideas and feature requests for Statamic
https://statamic.dev
31 stars 1 forks source link

GraphQL: add "site" argument to the entries query (in addition to singular entry) #1016

Closed fabiangigler closed 2 months ago

fabiangigler commented 1 year ago

The ability to filter the entry query by site handle in multisite / localized statamic sites was added 2 years ago in this PR by @jasonvarga, changing about 4 lines: https://github.com/statamic/cms/pull/4055/files

However the site argument is still missing for the entries query, see here: GraphiQL screenshot

While the same result can be achieved via the filter argument and adding the site to the allowed filter configuration, direct support as an argument as well as symmetry between the queries would be nice. From local testing the effort should not be much higher than in the PR above.

If you want me to open a PR, let me know.

jasonvarga commented 1 year ago

Happy to take a look at a PR. 👍