GrafeasGroup / blossom

The website. The app. The everything.
6 stars 3 forks source link

Add query parameter to order API results explicitly #173

Closed TimJentzsch closed 3 years ago

TimJentzsch commented 3 years ago

Relevant issue: Closes #172

Description:

This uses the OrderingFilter general filter back-end to provide an ordering query parameter. This can be used to explicitly control the ordering of the API results.

For example, /api/submission/?ordering=complete_time and api/submission/?ordering=-complete_time will return the submissions filtered by the time they were completed at, ascending and descending respectively.

I added orderings to the submission, transcription and volunteer endpoints.

Checklist: