mirror of
https://github.com/jazzband/django-admin2.git
synced 2026-03-16 22:20:24 +00:00
Added search_fields to admin and admin2 class for the example project
This commit is contained in:
parent
2af4aed976
commit
858d39e5f4
2 changed files with 2 additions and 0 deletions
|
|
@ -9,6 +9,7 @@ class CommentInline(admin.TabularInline):
|
|||
|
||||
class PostAdmin(admin.ModelAdmin):
|
||||
inlines = [CommentInline, ]
|
||||
search_fields = ('title', 'body')
|
||||
|
||||
admin.site.register(Post, PostAdmin)
|
||||
admin.site.register(Comment)
|
||||
|
|
|
|||
|
|
@ -35,6 +35,7 @@ class CommentInline(djadmin2.Admin2Inline):
|
|||
|
||||
class PostAdmin(djadmin2.ModelAdmin2):
|
||||
inlines = [CommentInline]
|
||||
search_fields = ('title', 'body')
|
||||
|
||||
|
||||
class UserAdmin2(djadmin2.ModelAdmin2):
|
||||
|
|
|
|||
Loading…
Reference in a new issue