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

Content ordering should be separated based on API it is served from #10354

Closed
1 of 3 tasks
naz opened this issue Jan 9, 2019 · 4 comments
Closed
1 of 3 tasks

Content ordering should be separated based on API it is served from #10354

naz opened this issue Jan 9, 2019 · 4 comments
Labels
affects:api Affects the Ghost API later [triage] Things we intend to work but are not immediate priority server / core Issues relating to the server or core of Ghost

Comments

@naz
Copy link
Contributor

naz commented Jan 9, 2019

Problem

At the moment we are applying the same ordering rules for both Admin and Content API's which is not ideal. For example, we end up ordering page served from Content API using orderDefaultRaw , this instead could be just ordered by title. For this reason, ordering of content served from Content and Admin APIs should be separated.

Specification

The default order for resources returned from Content API should be:

  • Post: “published_at desc”
  • Page: “title asc”
  • Tag: “name asc”
  • Author: “name asc”

The order of resources served in Admin API should stay as is.

Ideally this would be put on the controller level once controller separation is finished.

TODO

  • Implement default ordering
  • Fix Alphabetical ordering bug
  • achieve consistent ordering independent of DB engine,
@naz naz added server / core Issues relating to the server or core of Ghost affects:api Affects the Ghost API refactoring/cleanup labels Jan 9, 2019
@ErisDS ErisDS added the cleanup label Jan 11, 2019
@kirrg001 kirrg001 added the help wanted [triage] Ideal issues for contributors to help with label Jan 11, 2019
@ErisDS
Copy link
Member

ErisDS commented Jan 14, 2019

The refactoring work in this issue is low priority but getting the ordering correct needs to be fixed ASAP

@naz naz self-assigned this Jan 14, 2019
naz added a commit to naz/Ghost that referenced this issue Jan 14, 2019
refs TryGhost#10354

- Adds ordering on input serialization layer for posts, pages, tags, and authors
naz added a commit that referenced this issue Jan 15, 2019
refs #10354

- Added ordering on input serialization layer for posts, pages, tags, and authors
- At the moment ordering is dependent on DB engine which will be resolved with #6104
@naz naz removed their assignment Jan 21, 2019
@ErisDS ErisDS added content-api and removed help wanted [triage] Ideal issues for contributors to help with labels Jan 23, 2019
@stale
Copy link

stale bot commented May 15, 2019

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale [triage] Issues that were closed to to lack of traction label May 15, 2019
@naz
Copy link
Contributor Author

naz commented May 15, 2019

Not stale

@stale stale bot removed the stale [triage] Issues that were closed to to lack of traction label May 15, 2019
@stale
Copy link

stale bot commented Aug 13, 2019

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale [triage] Issues that were closed to to lack of traction label Aug 13, 2019
@naz naz removed the stale [triage] Issues that were closed to to lack of traction label Aug 13, 2019
@ErisDS ErisDS added the later [triage] Things we intend to work but are not immediate priority label Aug 21, 2019
@ErisDS ErisDS closed this as completed Aug 21, 2019
naz added a commit that referenced this issue Nov 22, 2020
refs #10354

- The serializer wasn't hooked up properly during the implementation (1a4497f). It is not possible to hook it back in now as that would introduce breaking change to now stable v2 API.
- v3 (canary) has is properly hooked in, so there should not be a problem going forward
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 later [triage] Things we intend to work but are not immediate priority server / core Issues relating to the server or core of Ghost
Projects
None yet
Development

No branches or pull requests

3 participants