{% extends "base.html" %} {% block title %} {{ item.name }} {% endblock %} {% block content %}
{% include "includes/flash.html" %}

Edit '{{ item.name }}'

{{ form.hidden_tag() }} {% for field in form %} {% if field.name != "csrf_token" %} {% for error in field.errors %}

{{ error }}

{% endfor %} {% if field.name == 'value' %}
{{ form.value.label(class="input-group-text w-80") }} {{ form.comparison.label(class="input-group-text w-40") }}
{{ form.value2.label(class="input-group-text w-100") }}
{{ form.value(class="form-control w-50", value=form.value.data) }}
{{ form.comparison(class="form-control", value=form.comparison.data) }}
{{ form.value2(class="form-control", value=form.value2.data) }}
{% elif field.name != 'comparison' and field.name != 'value2' %}
{{ field.label(class="input-group-text fixed-label") }}
{% if field.data is iterable and field.data is not string %} {% if field.name == 'datafiles' %}
{% endif %} {% for option in field.choices %} {% endfor %} {% else %} {{ field(class="form-control", value=field.data) }} {% endif %}
{% if field.data is iterable and field.data is not string %}
{% for option in field.choices if option.0 in field.data %}
{{ option.1 }} ×
{% endfor %}
{% endif %} {% endif %} {% endif %} {% endfor %}

{% endblock %}