Thursday, October 30, 2014

Get form from modelformset by the model associated in template

Hi all,
I think it is a simple question but I don't know how I can get the specific form associated to a model from a modelformset inside a template.
In other words I am extending a ListView and I pass a modelformset through the context.
So in the template:
{% for object in object_list %}
    {{ object.field }}
    {{ which form of modelformset????? }}
{% endfor %}

Thank you,
Luigi

--
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 django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/8c6a7fc4-420c-4ebc-ad74-ea16ddcea058%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment