Django-grappelli inside use inline seems a bit of a problem, change a skin:
Django-suit is the second admin skin recommended by 2scoops.
Supports:django 1.4-1.7. Python:2.6-3.
The environment for this article is Django 1.7.1
Django-suit official website
Installation Guide Links
Set up Raiders
Translation is handled as follows:
Installation
Copy the Code code as follows:
Pip Install Django-suit
# settings.py
From django.conf.global_settings import template_context_processors as TCP
Template_context_processors = TCP + (
' Django.core.context_processors.request ',
)
Terminal
Copy the Code code as follows:
Python manage.py makemigrations
Python manage.py Migrate
Python manage.py collectstatic
Congratulations! The basic installation is complete!
Official raiders also have a lot of detailed settings, I found that this plugin is not just for the back-end service, but also with a lot of form widgets, at the front desk can also be good use:
Examples are as follows:
DateTime widget
Copy the Code code as follows:
Suitdatewidget, Suittimewidget and Suitsplitdatetimewidget extends original admin widgets by adding some additional output Styling only. Widgets still uses same original JavaScript for calendar and time. You can see example in Demo app:user changeform:
From django.forms import Modelform
From suit.widgets import Suitdatewidget, Suittimewidget, Suitsplitdatetimewidget
Class Userchangeform (Userchangeform):
Class Meta:
Model = User
Widgets = {
' Last_login ': Suitsplitdatetimewidget,
' date_joined ': Suitsplitdatetimewidget,
}
Most of the above content is reduced to the official guide, to the needs of the small partners to refer to it