List Info

Thread: edit_inline on the other end of the OneToOneField




edit_inline on the other end of the OneToOneField
user name
2006-03-30 22:59:36
Hello,

I used edit_inline with a OneToOneField and it worked.
I am trying to extend the user model, but with multiple
OneToOneField
models. For example, I might have an Employee model that has
a
OneToOneField to User, and a Customer model with a
OneToOneField  to
User.
Now, if I add 'edit_inline' to those OneToOneFields, it
adds the
ability to edit Employee and Customer from the User page. I
want to do
the opposite, whenever I am editing an Employee, I want to
have the
ability to edit the associated User. Of course I would like
to do this
wihtout editing the User model itself.

Am I approaching this the correct way? or do I have to think
about it
differently?

-- 
Thanks!
Medhat Assaad


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the
Google Groups "Django users" group.
To post to this group, send email to django-usersgooglegroups.com
To unsubscribe from this group, send email to
django-users-unsubscribegooglegroups.com
For more options, visit this group at http://gr
oups.google.com/group/django-users
-~----------~----~----~----~------~----~------~--~---

edit_inline on the other end of the OneToOneField
user name
2006-03-31 08:02:18
medhat schrieb:
> Am I approaching this the correct way? or do I have to
think about it
> differently?

I experienced the same problem during "playing
around" with an idea, so 
I think you really hit a limitation. In the magic-removal
branch, there 
will be subclassing a model class this way (search for
"model 
inheritance"), which should, some day , solve
this.

Any great idea to solve this with the current django this is
very 
welcome by me, too 

Michael

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the
Google Groups "Django users" group.
To post to this group, send email to django-usersgooglegroups.com
To unsubscribe from this group, send email to
django-users-unsubscribegooglegroups.com
For more options, visit this group at http://gr
oups.google.com/group/django-users
-~----------~----~----~----~------~----~------~--~---

[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )