Commit 00e6d851 by Bach Dániel

dashboard: add groupprofile to admin

parent 3cf09597
...@@ -18,17 +18,24 @@ ...@@ -18,17 +18,24 @@
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
from django import contrib from django import contrib
from django.contrib.auth.admin import UserAdmin from django.contrib.auth.admin import UserAdmin, GroupAdmin
from django.contrib.auth.models import User from django.contrib.auth.models import User, Group
from dashboard.models import Profile from dashboard.models import Profile, GroupProfile
class ProfileInline(contrib.admin.TabularInline): class ProfileInline(contrib.admin.TabularInline):
model = Profile model = Profile
class GroupProfileInline(contrib.admin.TabularInline):
model = GroupProfile
UserAdmin.inlines = (ProfileInline, ) UserAdmin.inlines = (ProfileInline, )
GroupAdmin.inlines = (GroupProfileInline, ), UserAdmin), UserAdmin), GroupAdmin)
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 sign in to comment