{% extends "base.html" %} {% macro ingredientpart(ing) -%} {% if recipe.price != None %}{{price(ing.price)}} {%endif%}{{ing.amount|amountprint}} {{ing["unit"].name}} {{ ing.name }} {{ing.note}} {%- endmacro %} {% macro ingredient(ing) -%} {{ingredientpart(ing)}} {% if ing.alternatives|length != 0 %} {% for alting in ing.alternatives %} or {{ingredientpart(alting)}} {% endfor %} {% endif %} {%- endmacro %} {% macro getrecipe(rec) -%} {% for subrecipe in rec.subrecipes %} {{getrecipe(subrecipe)}} {% endfor %}