django-admin-rangefilter app, add the filter by a custom date range on the admin UI.
Project description
django-admin-rangefilter
django-admin-rangefilter app, add the filter by a custom date / datetime range on the admin UI.
Requirements
Python 2.7+ or Python 3.4+
Django 1.8+
Installation
Use your favorite Python package manager to install the app from PyPI, e.g.
Example:
pip install django-admin-rangefilter
Add rangefilter to INSTALLED_APPS:
Example:
INSTALLED_APPS = (
...
'rangefilter',
...
)
Example usage
In admin
from django.contrib import admin
from rangefilter.filter import DateRangeFilter, DateTimeRangeFilter
from .models import Post
@admin.register(Post)
class PostAdmin(admin.ModelAdmin):
list_filter = (
('created_at', DateRangeFilter), ('updated_at', DateTimeRangeFilter),
)
Support Content-Security-Policy
For Django 1.8+, if django-csp is installed, nonces will be added to style and script tags.
INSTALLED_APPS = (
...
'rangefilter',
'csp',
...
)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for django-admin-rangefilter-0.6.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0f08ef774cb7da1c0e5d748c81d4044dbd8240c114599ef94bb68b22ab98d7e9 |
|
MD5 | 606b1de1a04f6ebd07eb6f838d58efdb |
|
BLAKE2b-256 | 0c4f44f997884679ec21721bf2445b9d2a7be179e5ffb5358ddea1f6afdc47e3 |
Close
Hashes for django_admin_rangefilter-0.6.1-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e767bdf8f79480793b1d424e323ac810ca0e06cd5a63217fef8c6c0f04aa15b7 |
|
MD5 | 5c2121aedc7649f3c7d0555de300beab |
|
BLAKE2b-256 | 3d4e28dbf28aa6412bbf0e0af62e11f07c454c809a4f1163731dd2876cad5151 |