Not sure it'll help but I've always used the 'sender' kwarg (I've used
it a total of once to be fair):
for example:
m2m_changed.connect(update_answer_set_num_answers,
sender=AnswerSet.answers.through)
On Sep 14, 11:43 am, allyb wrote:
> hi,
>
> yes, it is called in models.py, and no, it's not i
hi,
yes, it is called in models.py, and no, it's not indented and neither
is the handler function.
On Sep 14, 4:28 pm, Jason wrote:
> Is the m2m_changed() call in the models.py?
>
> Also, it looks indented - if it is, it shouldn't be - in other words -
> it doesn't belong to the model.
>
> On Se
hi,
yes, it is called in models.py, and no, it's not indented and neither
is the handler function.
On Sep 14, 4:28 pm, Jason wrote:
> Is the m2m_changed() call in the models.py?
>
> Also, it looks indented - if it is, it shouldn't be - in other words -
> it doesn't belong to the model.
>
> On Se
Is the m2m_changed() call in the models.py?
Also, it looks indented - if it is, it shouldn't be - in other words -
it doesn't belong to the model.
On Sep 13, 1:27 pm, allyb wrote:
> I'm finding it difficult to denormalise a field in a django model. I
> have:
>
> class AnswerSet(models.Model)
I'm finding it difficult to denormalise a field in a django model. I
have:
class AnswerSet(models.Model):
title = models.CharField(max_length=255)
num_answers = models.PositiveIntegerField(editable=False,
default=0)
answers = models.ManyToManyField(Answer,
through='Answ
5 matches
Mail list logo