Skip to content

Commit

Permalink
Merge pull request #13 from kunalgrover05/patch-1
Browse files Browse the repository at this point in the history
Add documentation for using in custom filters
  • Loading branch information
mrts authored Oct 21, 2018
2 parents 9a9bb97 + 3ec26fd commit 4142afd
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,19 @@ class EntityAdmin(admin.ModelAdmin):
)
```

Example of a custom filter that uses the provided template:

```py
class CustomFilter(SimpleListFilter):
template = 'django_admin_listfilter_dropdown/dropdown_filter.html'

def lookups(self, request, model_admin):
...

def queryset(self, request, queryset):
...
```

# Example

Here's what it looks like:
Expand Down

0 comments on commit 4142afd

Please sign in to comment.