File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -252,15 +252,15 @@ Setup the Tabular Inlines to enable Buttons to be sorted in Django Admin
252
252
.. code :: python
253
253
254
254
from django.contrib import admin
255
- from adminsortable2.admin import SortableInlineAdminMixin
255
+ from adminsortable2.admin import SortableInlineAdminMixin, SortableAdminBase
256
256
from models import Panel
257
257
258
258
class ButtonTabularInline (SortableInlineAdminMixin , admin .TabularInline ):
259
259
# We don't use the Button model but rather the juction model specified on Panel.
260
260
model = Panel.buttons.through
261
261
262
262
@admin.register (Panel)
263
- class PanelAdmin (admin .ModelAdmin )
263
+ class PanelAdmin (SortableAdminBase , admin .ModelAdmin ):
264
264
inlines = (ButtonTabularInline,)
265
265
266
266
You can’t perform that action at this time.
0 commit comments