[EMAIL PROTECTED] wrote:
How could I combine this into one view (i.e. recent_photos)?
Hi Oliver, Since you're talking about two separate models, two queries (the way you are doing it at the moment) makes perfect sense. In a view, combine them in a list, sort it, then pass that to your template. Something like: recent_photos = [p.date_taken, p for p in recent_ownphotos] + [p.date_taken, p for p in recent_faves] recent_photos.sort() recent_photos.reverse() recent_photos = [p for date, p in recent_photos] --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---

