Changeset e9ba764


Ignore:
Timestamp:
Mar 22, 2012 12:46:12 AM (2 years ago)
Author:
yomguy <yomguy@…>
Branches:
master, crem, crem2, dev, dev2, diadems, dj1.6, feature/breadcrumbs, feature/ts-0.5, feature/ts-0.5.4, feature/writecache, forma, generic, instru_search, lam, lam2, mapsv3, merge, nlivemulti, production, release/1.4.4, sabiod, security, server, social, storage, telecaster, test
Children:
bfa68c2
Parents:
2359393
git-author:
yomguy <yomguy@…> (22/03/2012 00:46:12)
git-committer:
yomguy <yomguy@…> (22/03/2012 00:46:12)
Message:

add user profile to admin

File:
1 edited

Legend:

Unmodified
Added
Removed
  • telemeta/admin.py

    rfabced9 re9ba764  
    66from telemeta.models.system import * 
    77from django.contrib import admin 
     8from django.forms import CheckboxSelectMultiple 
     9from django.contrib.auth.models import User 
     10from django.contrib.auth.admin import UserAdmin 
     11 
     12admin.site.unregister(User) 
    813 
    914class MediaFondsAdmin(admin.ModelAdmin): 
     
    7580    search_fields = ['code', 'vendor'] 
    7681 
     82class UserProfileInline(admin.StackedInline): 
     83        model = UserProfile 
     84 
     85class UserProfileAdmin(UserAdmin): 
     86        inlines = [UserProfileInline] 
     87 
    7788admin.site.register(MediaFonds, MediaFondsAdmin) 
    7889admin.site.register(MediaCorpus, MediaCorpusAdmin) 
     
    99110 
    100111admin.site.register(Format, FormatAdmin) 
     112 
     113admin.site.register(User, UserProfileAdmin) 
Note: See TracChangeset for help on using the changeset viewer.