Hi everybody, 

I'm beginner in Django, and I have a "little" problem.

I would like to include a subtemplate in a for loop and passing some 
parameter.

like this:

          {% for tasklist in object_list %}
>           <li>
>                 <a href="{% url 'tasks-list'  tasklist.id %}">{{ 
> tasklist.title }}</a>
>                 {% block task_list %}
>         {% include "tasklist-one.html" with tasklist_id=tasklist.id %}
> {% endblock %}
>           </li>
>           {% endfor %}


But before including template ( tasklist-one.html ) I would like to call a 
function  which take the tasklist_id and look for the task which compose 
the tasklist.
How can I do this kind of things ? 

Thank you !

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to