1 {% extends 'base.html' %}
4 {% macro show_node(node, indent) %}
6 {% for i in range(indent) %} {% endfor %} +
7 {% if node.seen %}({% else %}{% endif %}<a href="todo?id={{node.item.id_}}">{{node.item.process.title.newest|e}}</a>{% if node.seen %}){% else %}{% endif %}
9 {% for i in range(indent) %} {% endfor %} +
10 {% if node.seen %}({% else %}{% endif %}<a href="condition?id={{node.item.id_}}">{{node.item.title.newest|e}}</a>{% if node.seen %}){% else %}{% endif %}
15 {% macro undone_with_children(node, indent) %}
16 {% if not node.hide %}
20 <input name="done" value="{{node.item.id_}}" type="checkbox" {% if node.seen or not node.item.is_doable %}disabled{% endif %} {% if node.item.is_done %} checked {% endif %} />
24 {{ show_node(node, indent) }}
28 {% for child in node.children %}
29 {{ undone_with_children(child, indent+1) }}
34 {% macro done_with_children(node, indent) %}
35 {% if not node.hide %}
38 {{ show_node(node, indent) }}
42 {% for child in node.children %}
43 {{ done_with_children(child, indent+1) }}
49 <h3>{{day.date}} / {{day.weekday}}</h3>
51 <a href="day?date={{day.prev_date}}">prev</a> | <a href="day?date={{day.next_date}}">next</a>
53 <form action="day?date={{day.date}}" method="POST">
54 comment: <input name="comment" value="{{day.comment|e}}" />
55 <input type="submit" value="OK" /><br />
56 add todo: <input name="new_todo" list="processes" autocomplete="off" />
57 <datalist id="processes">
58 {% for process in processes %}
59 <option value="{{process.id_}}">{{process.title.newest|e}}</option>
64 {% for node in condition_listings %}
65 <li>[{% if node.condition.is_active %}x{% else %} {% endif %}] <a href="condition?id={{node.condition.id_}}">{{node.condition.title.newest|e}}</a>
66 ({% for enabler in node.enablers %}
67 < {{enabler.process.title.newest|e}};
69 {% for disabler in node.disablers %}
70 ! {{disabler.process.title.newest|e}};
76 {% for node in todo_trees %}
77 {{ undone_with_children(node, indent=0) }}
82 {% for node in done_trees %}
83 {{ done_with_children(node, indent=0) }}