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

Fetching posts should allow for sorting #78

Closed
RiccardoM opened this issue Jan 14, 2020 · 0 comments · Fixed by #83
Closed

Fetching posts should allow for sorting #78

RiccardoM opened this issue Jan 14, 2020 · 0 comments · Fixed by #83
Assignees
Labels
kind/enhancement Enhance an already existing feature; no "New feature" to add x/posts Post module
Projects
Milestone

Comments

@RiccardoM
Copy link
Contributor

Is your feature request related to a problem? Please describe.
Currently when fetching posts using the REST API there is no way to sort the posts before the pagination. This results into the impossibility of fetching (e.g.) the latest posts sorted by descending creation date.

This is particularly useful when developing applications that needs to show the posts in a timeline.

Describe the solution you'd like
Improve the /posts REST API endpoint to accept a sorting parameter and a sorting order parameter. One example could be

/posts?sort=created&sort_order=descending

Describe alternatives you've considered

Additional context

@RiccardoM RiccardoM added kind/enhancement Enhance an already existing feature; no "New feature" to add x/posts Post module labels Jan 14, 2020
@RiccardoM RiccardoM added this to the v0.3.0 milestone Jan 14, 2020
@RiccardoM RiccardoM added this to To do in Desmos via automation Jan 14, 2020
@RiccardoM RiccardoM self-assigned this Jan 21, 2020
Desmos automation moved this from To do to Done Jan 22, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/enhancement Enhance an already existing feature; no "New feature" to add x/posts Post module
Projects
No open projects
Desmos
  
Done
Development

Successfully merging a pull request may close this issue.

1 participant