I'm not sure to understand the actual purpose of using a create_object()
method in a custom manager, rather than directly in the model, when I need to override the default Class.objects.create()
method.
The only difference I see is how I would call it:
Class.create_object()
if thecreate_object()
method is in the modelClass.objects.create_object()
if thecreate_object
is a custom manager method.
However, I suppose the latter is the right thing to do, based on examples I can see from Django (with create_user
for example). I just would like to understand why.
Thanks!