Wiadomość napisana w dniu 2009-01-14, o godz. 18:42, przez Tim:

> I am using the messages framework to notify users when another user
> has commented on their profile or on an item they've posted. I was
> pretty excited to see that such an infrastructure was included with
> the authentication system out of the box. However, I was disappointed
> to see that the only way to retrieve messages was via a get _and_
> delete operation, so each get (or reference to "messages" in a
> template) emptied the queue.


Messages are normal model instances, you are not limited to  
get_and_delete_messages(), user.message_set.all() is normal queryset  
so you can retrieve objects without deleting them.

-- 
We read Knuth so you don't have to. - Tim Peters

Jarek Zgoda, R&D, Redefine
jarek.zg...@redefine.pl


--~--~---------~--~----~------------~-------~--~----~
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