PageRenderTime 10ms CodeModel.GetById 1ms app.highlight 3ms RepoModel.GetById 1ms app.codeStats 1ms

/django/contrib/admin/templates/admin/includes/fieldset.html

https://code.google.com/p/mango-py/
HTML | 29 lines | 29 code | 0 blank | 0 comment | 0 complexity | f29facf02bbbe66a5beecb382f192ae3 MD5 | raw file
 1<fieldset class="module aligned {{ fieldset.classes }}">
 2    {% if fieldset.name %}<h2>{{ fieldset.name }}</h2>{% endif %}
 3    {% if fieldset.description %}
 4        <div class="description">{{ fieldset.description|safe }}</div>
 5    {% endif %}
 6    {% for line in fieldset %}
 7        <div class="form-row{% if line.fields|length_is:'1' and line.errors %} errors{% endif %}{% for field in line %} {{ field.field.name }}{% endfor %}">
 8            {% if line.fields|length_is:'1' %}{{ line.errors }}{% endif %}
 9            {% for field in line %}
10                <div{% if not line.fields|length_is:'1' %} class="field-box{% if not field.is_readonly and field.errors %} errors{% endif %}"{% endif %}>
11                    {% if not line.fields|length_is:'1' and not field.is_readonly %}{{ field.errors }}{% endif %}
12                    {% if field.is_checkbox %}
13                        {{ field.field }}{{ field.label_tag }}
14                    {% else %}
15                        {{ field.label_tag }}
16                        {% if field.is_readonly %}
17                            <p>{{ field.contents }}</p>
18                        {% else %}
19                            {{ field.field }}
20                        {% endif %}
21                    {% endif %}
22                    {% if field.field.help_text %}
23                        <p class="help">{{ field.field.help_text|safe }}</p>
24                    {% endif %}
25                </div>
26            {% endfor %}
27        </div>
28    {% endfor %}
29</fieldset>