Commit 2af17265 authored by Ilya Simonov's avatar Ilya Simonov

fix create playlist

parent da5769a4
...@@ -41,7 +41,9 @@ class PlayListAdmin(admin.ModelAdmin): ...@@ -41,7 +41,9 @@ class PlayListAdmin(admin.ModelAdmin):
inlines = [TagInline] inlines = [TagInline]
def get_inlines(self, request, obj): def get_inlines(self, request, obj):
return self.inlines if obj.type == models.DYNAMIC else [] if obj and obj.type == models.DYNAMIC:
return [TagInline]
return []
class CategoryAdmin(admin.ModelAdmin): class CategoryAdmin(admin.ModelAdmin):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment