On 18 jan, 10:08, Mo Mughrabi <mo.mughr...@gmail.com> wrote:
> Hi,
>
> am having problem with django custom signals not being able to see signals
> across application. I made a simple call in my
>
> *core/signals.py*
>
>   *  from django.dispatch.dispatcher import Signal*
> *    # Signal-emitting code... emits whenever a file upload is received*
> *    # ----------------------------------------------------------------*
> *    *
> *    upload_recieved = Signal(providing_args=['data'])*

(snip)

> *in blog/admin.py*
>
> *    from libs.shared.core import signals*
(snip)
> *    *
> *    *
> *    class ArticleModelAdmin(admin.ModelAdmin):*
> *        def save_model(self, request, obj, form, change):*
> *            upload_recieved.send(sender=self, data='ddd')*

You want:
               signals.upload_recieved.send(sender=self, data='ddd')

(snip)
> *    *
>
> this is what I did, but am getting an error in the runtime unable to see
> upload_received function. any ideas?


http://docs.python.org/tutorial/modules.html


Also and while we're at it : avoid adding '*' around your code
snippets, it really doesn't help.
;)

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.

Reply via email to