擅长:python、mysql、java
<p>通常django模板将用django视图中呈现的数据作为字典填充,这些数据可以在使用django模板标记“{tag\u name}}”的模板中调用</p>
<p>在这里,您将把所有表单呈现为字典中的一个列表,这样就可以通过循环显示每个表单。你知道吗</p>
<pre><code>{% for form in forms %}
{{form.description}}
{% endfor %}
</code></pre>
<p>这样,就可以显示每个窗体的数据。如果只想显示特定窗体的数据,则正确的方法是使用特定窗体的数据呈现视图,并使用template标记在template中显示数据{{表格.说明}}你知道吗</p>
<p>查看django文档:<a href="https://docs.djangoproject.com/en/2.1/topics/templates/" rel="nofollow noreferrer">https://docs.djangoproject.com/en/2.1/topics/templates/</a></p>