django-jazzmin
django-jazzmin copied to clipboard
Support for django-admin-numeric-filter (feature)
Django-admin-numeric-filter (https://github.com/lukasvinclav/django-admin-numeric-filter) adds support for adding range filters on your lists with some nice sliders.
However when using this with django-jazzmin you are greeted with:
....azzmin/templatetags/jazzmin.py", line 234, in jazzmin_list_filter
query_string = choice["query_string"][1:]
KeyError: 'query_string'
This works without problems in the default admin.
I think jazzmin makes assumptions about how filters work which is broken by django-admin-numeric-filter.
Would be nice if the page does not break and maybe the range slider box needs some jazz.
When i look into the search and filter fields implementation, i feel like it needs reshuiffling, i think its drifted away from djangos implementation too much, to fix this issue, i think we would rework the search_form.html include in change_list.html, and if possible, do away with the jazzmin_list_filter
The fastest way for us to provide a fix in for this, is to do the following:
- Fork the project and make a new branch
- Integrate this 3rd party app into our embedded demo app (https://github.com/farridav/django-jazzmin/tree/master/tests/test_app)
- push it up and send us a link to the branch
This way we will be able to reproduce the issue quickly, and fix it, without needing to delve into how to integrate/setup the 3rd party app :)
Thanks for reporting, we hope to provide compatibility with all other packages, especially if they are widely used
I created a branch where I integrated the 3rd party app. See PR.
Good news: It just works now, but only needs some styling.
Bump as django-admin-numeric-filter is still missing styling.
I'm afraid I'm finding it very difficult to put time in to this at the moment, so anybody that wants to add to the PR, and get it code complete, please do.
I hope to have more time in a month or so, but until then, I'll need contributors