Thanks Alex that worked great.
Vitaly Babiy
On Fri, Nov 7, 2008 at 12:19 PM, Alex Koshelev <[EMAIL PROTECTED]> wrote:
> Try to connection handler without `sender` specified. And filter needed
> models inside it.
>
> def my_handler(sender, **kwargs):
> if not isinstance(sender, CustomModel):
Try to connection handler without `sender` specified. And filter needed
models inside it.
def my_handler(sender, **kwargs):
if not isinstance(sender, CustomModel):
return
signals.pre_save.connect(my_handler)
On Fri, Nov 7, 2008 at 20:03, Vitaly Babiy <[EMAIL PROTECTED]> wrote:
> if
if I define a model called CustomModel and I attach attach a pre_save signal
to it. Is there any way to have that signal be called any time model that
extends CustomModel is being saved has that method saved.
I know i could do this by overriding the save method on CustomeModel but I
was wondering
3 matches
Mail list logo