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

Post-filter parameter cleanup & changes #5943

Closed
10 of 12 tasks
ErisDS opened this issue Oct 13, 2015 · 0 comments
Closed
10 of 12 tasks

Post-filter parameter cleanup & changes #5943

ErisDS opened this issue Oct 13, 2015 · 0 comments
Labels
affects:api Affects the Ghost API

Comments

@ErisDS
Copy link
Member

ErisDS commented Oct 13, 2015

Issue #5463 describes the current state of the API (pre-filter parameter) and how this will be much improved with the addition of the filter parameter.

Once the filter parameter (#5604) itself has been merged, we will need to refactor all the parts of Ghost which depend on the old style API, such as the frontend controller and the admin UI model layer, so that they use the new filter parameter rather than the oldschool tags or author parameters.

Careful consideration will be needed for some of the boolean parameters, for which we need to make sure we can support true, false and unset / all - for example with page and featured.

We'll also need to remove the old style parameters from the API, update the tests, and ensure that we still support he same behaviours as we did previously.

More details including a task list will be added to this issue when we're ready to start working on it.

* Not sure if we're ready to do this...

@ErisDS ErisDS added the affects:api Affects the Ghost API label Oct 13, 2015
@ErisDS ErisDS added this to the Public API v1 milestone Oct 13, 2015
ErisDS added a commit to ErisDS/Ghost that referenced this issue Oct 26, 2015
refs TryGhost#5943, TryGhost#5091

- updated fetch-data to handle multiple api queries
- using named keys for queries so that the names of items in the result are correct (tag instead of tags etc)
- updated channel configs in frontend controller
- removed old filter code from frontend controller
- added test coverage for fetch-data and format-response
- fixes / removes tests which are broken by the refactor
ErisDS added a commit to ErisDS/Ghost that referenced this issue Oct 27, 2015
refs TryGhost#5943, TryGhost#5091

- split out channel config
- use config.theme instead of api calls to grab title & desc
- wrap rss call in a function which sets channel config for RSS feeds
- change rss `getData` function to use the new multiple-query-handling fetchData functionality
- make sure channelConfig is set in all tests
ErisDS added a commit to ErisDS/Ghost that referenced this issue Oct 27, 2015
refs TryGhost#5943

- removed featured, tag and author parameters from posts API
   - featured was only used in tests
- removed role filter from users API
   - role was only used in tests
- fixed up the tests, skipping those that don't quite work yet
ErisDS added a commit to ErisDS/Ghost that referenced this issue Nov 9, 2015
ref TryGhost#5943

- found some more code that can be removed
ErisDS added a commit to ErisDS/Ghost that referenced this issue Nov 12, 2015
refs TryGhost#5943

- no longer assume the options in processOptions are set
- set where to a new GQL JSON-like statement object
- rather than setting options, add statements which can be understood by knexify
- pass the statements through knexify to build the query
@ErisDS ErisDS mentioned this issue Nov 16, 2015
ErisDS added a commit to ErisDS/Ghost that referenced this issue Nov 17, 2015
refs TryGhost#5614, TryGhost#5943

- adds a new 'filter' bookshelf plugin which extends the model
- the filter plugin provides handling for merging/combining various filters (enforced, defaults and custom/user-provided)
- the filter plugin also handles the calls to gql
- post processing is also moved to the plugin, to be further refactored/removed in future
- adds tests showing how filter could be abused prior to this commit
ErisDS added a commit to ErisDS/Ghost that referenced this issue Nov 19, 2015
ErisDS added a commit to ErisDS/Ghost that referenced this issue Nov 20, 2015
@ErisDS ErisDS modified the milestone: Public API v1 Dec 3, 2015
@ErisDS ErisDS added the later [triage] Things we intend to work but are not immediate priority label Sep 20, 2016
@ErisDS
Copy link
Member Author

ErisDS commented Sep 20, 2016

I'm closing most API issues temporarily with the later label.

JSON API Overhaul & OAuth access are currently scheduled next on the roadmap

@ErisDS ErisDS closed this as completed Sep 20, 2016
@ErisDS ErisDS removed later [triage] Things we intend to work but are not immediate priority labels Jan 23, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
affects:api Affects the Ghost API
Projects
None yet
Development

No branches or pull requests

1 participant