if a have a query like
following = Relations.objects.filter(initiated_by = request.user)
in which i'm having all the users followed by the currently logged in user, and i want to display those user's blog posts. Using a query like:
blog = New.objects.filter(created_by = following)
it only shows me the blog posts of the user with the id = 1 (though the currently logged in user doesn't actually follow him) in template i have :
{% for object in blog %}
<a href='/accounts/profile_view/{{object.created_by}}/'> {{object.created_by}}</a> <br />
{{object.post}}<br />
{% endfor %}
Where am i wrong?