{% extends "layout.html" -%}
{% set active_page = "home" -%}
{% import "utils.html" as util -%}
{% block container %}
Hi, I'm Haldis
What would you like to eat, sir?
{% if orders|count > 0 -%}
Open orders:
{% for order in orders %}
{{ util.render_order(order) }}
{% endfor %}
{% else %}
No orders available.
{% if not current_user.is_anonymous() %}
To create an order, fill in the form on the right.
{% else %}
Login to create an order, or ask someone else.
{% endif %}
{%- endif %}
{% if orders|count > 0 -%}
Recently closed orders:
{% for order in recently_closed %}
{{ util.render_order(order) }}
{% endfor %}
{%- endif %}