Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
La Quadrature du Net
piphone
campaign
Commits
1babafbd
Commit
1babafbd
authored
Jan 14, 2015
by
Mindiell
Browse files
Contact admin page modified to show more columns and add a search field
parent
be3a8ca6
Changes
1
Hide whitespace changes
Inline
Side-by-side
picampaign/contact/admin.py
View file @
1babafbd
from
django.contrib
import
admin
from
picampaign.contact.models
import
Contact
admin
.
site
.
register
(
Contact
)
class
ContactAdmin
(
admin
.
ModelAdmin
):
list_display
=
[
'full_name'
,
'mail'
,
'phone'
,
'twitter'
]
search_fields
=
(
'first_name'
,
'last_name'
)
admin
.
site
.
register
(
Contact
,
ContactAdmin
)
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment