Wednesday, 11 September 2013

How to position inlines in Django Admin?

How to position inlines in Django Admin?

I have two tables related Quiz and Difficulty_level:
I have created inline in admin.py like this:
class DifficultyLevelInline(admin.TabularInline):
model = DifficultyLevel
and included in QuizAdmin
To arrange the list order, I would do:
list_display = ('name', 'description', 'publication_date', 'category',
'is_active', 'is_premium')
How can I add inlines in the list_display order. I want to display The
DifficultyLevelInline before category.

No comments:

Post a Comment