On 9/19/07, Marty Alchin <[EMAIL PROTECTED]> wrote:
>
> I think I can make signals work well, if the signal provides a few
> arguments. I'm think that if it sent "sender" (the Relationship),
> "origin" and "related" (the two models), people should be able to
> register functions to do just about anything.

It sounds like you're talking about making the m2m table a 3 foreign
key affair (with the third foreign key referencing the intermediate
data) rather than just adding 2 foreign keys (from and to) to the
intermediate model. I'd be inclined to treat the 'Role' table as-is,
but the fact that it is referenced in a 'through' attribute means that
it gets 2 foreign keys automagically added. The approach you are
proposing will require a lot more table joins to get anything done,
and I'm not sure I see the benefit.

Also - I'm not sure I understand why you're getting so attached to
signals. Signals should only be required if there isn't a clear
connection between the stimulating action and the response. In the
case of m2m, when you add a relationship, you should have a handle to
the two models being related (and in the case of m2m intermediates,
the intermediate model) - there isn't anything ambiguous about the
target of the action. Why is a signal required?

Yours,
Russ Magee %-)

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To post to this group, send email to django-developers@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to