Hi Kristofer,
I usualy put methods like this one into Model, although Manager is also
possible. Definitely not View or sth else.
Why I like Model more than Manager is this difference (suppose your
method is called make_payment):
Account.make_payment # via Model
Account.objects.make_payment # via Manager
and because this method is "creating" object instead of "retrieving"
objects, it seems to me more apropriate. I know, there are methods like
create or get_or_create in Manager, so propably someone would have a
better arguments on this. Or maybe it's just matter of taste. In fact,
in one application of mine I have method Node.create which do some
fancy stuff (creating other related objects, consistency checks, etc.)
and then call Node.objects.create.
Cheers,
Tom
Dne Sat, 10 Nov 2012 01:23:44 -0600 (CST)
Kristofer <
kris...@cybernetik.net> napsal(a):