Skip to content

Search: refactor API to not emulate a Django queryset #7114

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

Merged
merged 4 commits into from
May 28, 2020

Conversation

stsewd
Copy link
Member

@stsewd stsewd commented May 21, 2020

The recommended way of using pagination over
a custom object is to manage the class ourselves.
I tried to rely on most of the defaults of the DRF's pagination class.

The API response is the same as before, we can extend it to return information about facets later.
Some method were moved around, but the logic is the same.

Closes #5235

stsewd added 2 commits May 21, 2020 15:48
The recommended way of using pagination over
a custom object is to manage the class ourselves.
I tried rely on most of the defaults of the DRF's pagination class.

Closes #5235
@stsewd stsewd requested a review from ericholscher May 21, 2020 21:15
Copy link
Member

@ericholscher ericholscher left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks like a solid refactor 👍

@stsewd stsewd merged commit e4973ea into master May 28, 2020
@stsewd stsewd deleted the refactor-search-apiview branch May 28, 2020 00:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Refactor docsearch to use facets and not emulate a queryset
2 participants