From ad4c400bc1dc8005d581290bcc91201734e825ed Mon Sep 17 00:00:00 2001 From: Sanj Date: Sun, 6 Mar 2011 18:19:58 +0530 Subject: [PATCH] forgot to add admin.py to tree --- itf/app/admin.py | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 itf/app/admin.py diff --git a/itf/app/admin.py b/itf/app/admin.py new file mode 100644 index 0000000..847b57d --- /dev/null +++ b/itf/app/admin.py @@ -0,0 +1,15 @@ +from django.contrib import admin +from models import ModelsModel, ModelSort, ModelExtraButton + +class ButtonsInline(admin.StackedInline): + model = ModelExtraButton + extra = 2 + + +class ModelsModelAdmin(admin.ModelAdmin): + inlines = [ButtonsInline] + + +admin.site.register(ModelsModel, ModelsModelAdmin) +admin.site.register(ModelSort) +admin.site.register(ModelExtraButton)