Re: Extending User Model with obligatory fields

2008-09-07 Thread [EMAIL PROTECTED]
Step 1: Write something like this in the appropriate app's models.py class CustomUser(User): client=models.ForeignKey('Client') Step 2: Either create your own ModelAdmin that extends django.contrib.auth.admin.UserAdmin or just use UserAdmin outright. Step 3: Create a middleware that runs a

Extending User Model with obligatory fields

2008-09-05 Thread David
Hi, I have a clients table, and I need each user to belong to a client. So in fact what I need is to extend the user model with one additional obligatory field. I have already seen the UserProfile approach, but that is not obligatory, meaning I can create a user without the profile, because the