Skip to main content
django-better-filter-widget
===========================

A better filter widget for foreign key relationships that also works on mobile devices. This was initially developed as a drop-in replacement for admin forms. It will work in a normal form but you'll have to include some css/js dependencies. I'll write about how to do that soon.

<img src="http://i.imgur.com/jzKen5h.gif" width="542"/>

# About
Django's [horizontal and vertical filter widget](http://i.imgur.com/RBgrm.png) is ugly, confusing to new users and completely broken on mobile devices. **django-better-filter-widget** is not magic and does not do real-time lookups like **django-selectable**. It's simply a nicer UI for filtering a list of things that, most importantly, actual works on mobile devices.


# Installation

Note: This project is brand spanking new and is still being tested. It was developed using django 1.6. It was tested in modern desktop and mobile browsers.

**Install with pip**

`pip install django-better-filter-widget`

**settings.py**

Add 'better_filter_widget' to INSTALLED_APPS in your settings.py

**admin.py**

Specify BetterFilterWidget as the widget for your field:

from django import forms
from django.contrib import admin
from better_filter_widget import BetterFilterWidget

class MyModelForm(forms.ModelForm):

class Meta(object):
model = MyModel
widgets = {
'my_field': BetterFilterWidget(),
}


class MyModelAdmin(admin.ModelAdmin):

form = MyModelForm

admin.site.register(MyModel, MyModelAdmin)


# License

The MIT License (MIT)

Copyright (c) 2014 Exotic Objects

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

Metadata

Release files for django-better-filter-widget 0.4.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for django-better-filter-widget 0.4.2
File Size Uploaded
django-better-filter-widget-0.4.2.tar.gz 5.3 kB Details

Release files / django-better-filter-widget-0.4.2.tar.gz

Download URL django-better-filter-widget-0.4.2.tar.gz
Size 5.3 kB
Tags Source
SHA-256 checksum
How to use checksums
21cfa80b1590d008ee72c94ea07227e4fecd51a2540f27931bd0e2c07fc9730e
BLAKE2b-256 checksum
How to use checksums
04234d7994523d7facf250434e463d6d909d3997a3047267cb11d624810696a8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

This release

0.4.2 This release

1 release file

0.4.1

1 release file

0.4

1 release file

0.3

1 release file

0.2

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page