OK.

One work around could be to fire the signal manually just after you
set/delete the value? I have not checked it yet :P

Do one thing, implement pre_delete and post_delete signals and check the
values of  instance, sender and using. It might give you more information
about what is happening.


Regards,
Chetan Ganji
+91-900-483-4183
ganji.che...@gmail.com
http://ryucoder.in


<https://www.avast.com/en-in/recommend?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail&utm_term=default3&tag=7ce9710f-d0c2-48a2-a0ba-76107578348e>
I’m
protected online with Avast Free Antivirus. Get it here — it’s free forever.
<https://www.avast.com/en-in/recommend?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail&utm_term=default3&tag=7ce9710f-d0c2-48a2-a0ba-76107578348e>
<#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>

On Thu, Mar 14, 2019 at 9:15 PM mccc <mcicc...@gmail.com> wrote:

>
>
> On Thursday, March 14, 2019 at 4:22:15 PM UTC+1, Chetan Ganji wrote:
>>
>> Why do you need to do any calculations in the model code?
>>
>> I would do any calculations in the views and store them using models.
>> That will remove the getters and setters from model.
>> Everything should work fine then.
>>
>> Hope it helps.
>>
>
> No, nothing would work fine: in that case I would need to remember
> constantly to either copy the code to handle the behaviour or make a call
> to *a view* each time and in any place that handles those fields.
> Plus the tests would need to check over and over for the same behaviour
> every time the field was involved.
>
> I'm sorry, but it really doesn't help.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/ed1853bb-402a-4688-9061-63054c44ce63%40googlegroups.com
> <https://groups.google.com/d/msgid/django-users/ed1853bb-402a-4688-9061-63054c44ce63%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAMKMUjuXZaAQXtM0ac%3DX7icsk76-eTcWnKSCgYp9iR_crQP%3D6A%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to