haldis/app/templates/utils.html
Feliciaan De Palmenaer 7032f2ad77 `The Final Countdown
2015-03-30 23:02:05 +02:00

22 lines
No EOL
745 B
HTML

{% macro render_order(order) -%}
<div class="row darker">
<div class="col-md-9">
<h5>{{ order.location.name }}</h5>
<p><b>Status:</b> <span class="time">{{ order.stoptime|countdown }}</span><br/>
<b>Orders:</b> {{ order.items.count() }}</p>
</div>
<div class="col-md-3">
<a class="btn btn-primary align-bottom full-width" href="{{ url_for('order_bp.order', id=order.id) }}">Expand</a>
</div>
</div>
{%- endmacro %}
{% macro render_form_field_errors(field) %}
{%- if field.errors %}
{%- for error in field.errors %}
<p class="help-block">{{error}}</p>
{%- endfor %}
{%- elif field.description -%}
<p class="help-block">{{field.description|safe}}</p>
{%- endif %}
{% endmacro %}