blob: 99db8190a496755615235ba931232a092f41929f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
<div class="field">
<div class="label-input">
<label for="{{ field.id_for_label }}">
{{ field.label }}
{% if field.field.required %}<small>(Required)</small>{% endif %}
</label>
{% if field.help_text %}
<p class="help">
{{ field.help_text|linebreaksbr }}
</p>
{% endif %}
{{ field.errors }}
{% if field.field.widget.input_type == "file" and field.value %}
<div class="clear">
<input type="checkbox" class="clear" name="{{ field.name }}__clear"> Clear current value</input>
</div>
{% endif %}
{{ field }}
</div>
{% if field.field.widget.input_type == "file" %}
<img class="preview" src="{{ field.value }}">
{% endif %}
</div>
|