There are several libraries which enable you to do fancy pagination of django queryset.
See this grid: https://djangopackages.org/grids/g/pagination/
I have not look at all libraries, but the one I saw needed a queryset as input.
I search a solution for the step before this:
How to get to the queryset?
I search a library which translates request.GET to a queryset filter.
Example: You want to show a search form for users (model User) with a generic interface.
AFAIK this could be solved without coding, just configuring should be enough.
http:///mydjangopage.example.com/query?username=foo&date_joined__gt=2017-01-01
The library should take request.GET and the django.contrib.auth.models.User model. The result should be a queryset. The nice double underscore feature for filter should be supported, too.
This queryset can be passed to one of above pagination libraries.
Of course authorization needs to handled somehow (but later)
License: Only open source software can be used here.
Please ask, if you don't understand the question.
I ask here, since no expert could help me here: https://softwarerecs.stackexchange.com/questions/42458/generic-search-for-any-django-model
Regards,
Thomas Güttler
-- See this grid: https://djangopackages.org/grids/g/pagination/
I have not look at all libraries, but the one I saw needed a queryset as input.
I search a solution for the step before this:
How to get to the queryset?
I search a library which translates request.GET to a queryset filter.
Example: You want to show a search form for users (model User) with a generic interface.
AFAIK this could be solved without coding, just configuring should be enough.
http:///mydjangopage.example.com/query?username=foo&date_joined__gt=2017-01-01
The library should take request.GET and the django.contrib.auth.models.User model. The result should be a queryset. The nice double underscore feature for filter should be supported, too.
This queryset can be passed to one of above pagination libraries.
Of course authorization needs to handled somehow (but later)
License: Only open source software can be used here.
Please ask, if you don't understand the question.
I ask here, since no expert could help me here: https://softwarerecs.stackexchange.com/questions/42458/generic-search-for-any-django-model
Regards,
Thomas Güttler
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/4d002075-cd92-4fa8-86db-4e52ab633729%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
No comments:
Post a Comment