2022-11-13 23:14:38 +00:00
|
|
|
<div class="field">
|
2022-11-18 00:43:00 +00:00
|
|
|
<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 }}
|
2022-11-18 02:21:00 +00:00
|
|
|
{% 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 %}
|
2022-11-18 00:43:00 +00:00
|
|
|
{{ field }}
|
|
|
|
</div>
|
2022-12-02 01:46:49 +00:00
|
|
|
{% if field.field.widget.input_type == "file" and field.value%}
|
2022-11-18 02:21:00 +00:00
|
|
|
<img class="preview" src="{{ field.value }}">
|
2022-11-13 23:14:38 +00:00
|
|
|
{% endif %}
|
|
|
|
</div>
|