1 {% extends '_base.html' %}
2 {% import '_macros.html' as macros %}
8 border: 1px solid black;
10 td.cond_line_0, td.cond_line_1, td.cond_line_2 {
12 border-top: 1px solid white;
15 background-color: #bfbfbf;
18 background-color: #dfdfdf;
21 background-color: #fffff;
30 border-bottom: 1px solid #bfbfbf;
33 tr.inactive > td.todo_line {
34 background-color: #bfbfbf;
35 border-bottom: 1px solid white;
37 tr.hidden_undone > td, tr.hidden_undone a {
41 border-left: 1px solid black;
44 border-right: 1px solid black;
53 {% macro show_node_undone(node, indent) %}
54 {% if not node.todo.is_done %}
55 <tr {% if node.seen or not node.todo.is_doable %}class="inactive"{% endif %}>
56 {% if not node.seen %}
57 <input type="hidden" name="todo_id" value="{{node.todo.id_}}" />
60 {% for condition in conditions_present %}
61 <td class="cond_line_{{loop.index0 % 3}}">
62 {% if condition in node.todo.conditions and not condition.is_active %}
64 {% elif condition in node.todo.blockers and condition.is_active %}
71 <td class="todo_line left_border"></td>
72 <td class="todo_line">{% if node.todo.effort %}{{ node.todo.effort }}{% endif %}</td>
74 <td class="todo_line left_border"><input name="done" type="checkbox" value="{{node.todo.id_}}" {% if not node.todo.is_doable %}disabled{% endif %}/></td>
75 <td class="todo_line"><input name="effort" type="number" step=0.1 placeholder={{node.todo.effort_then}} value={{node.todo.effort}} /></td>
77 <td class="todo_line right_border">
78 {% for i in range(indent) %} {% endfor %} +
79 {% if node.seen %}({% endif %}<a href="todo?id={{node.todo.id_}}">{{node.todo.title_then|e}}</a>{% if node.seen %}){% endif %}
82 {% for condition in conditions_present|reverse %}
83 <td class="cond_line_{{(conditions_present|length - loop.index) % 3}}">{% if condition in node.todo.enables %} +{% elif condition in node.todo.disables %} !{% endif %}</td>
88 {{node.todo.comment|e}}
90 <input name="comment" type="text" value="{{node.todo.comment|e}}" />
97 {% if not node.seen %}
98 {% for child in node.children %}
99 {{ show_node_undone(child, indent+1) }}
107 {% macro show_node_done(node, indent, path) %}
108 {% if node.todo.has_doneness_in_path %}
109 <tr{% if not node.todo.is_done %} class="hidden_undone"{% endif %}>
110 <td class="number">{{ '{:4.1f}'.format(node.todo.performed_effort) }}</td>
111 <td class="number">{{ '{:4.1f}'.format(node.todo.tree_effort) }}</td>
113 {% for i in range(indent) %} {% endfor %} +
114 {% if not node.todo.is_done %}({% endif %}{% if node.seen %}[{% endif %}<a href="todo?id={{node.todo.id_}}">{{node.todo.title_then|e}}</a>{% if node.seen %}]{% endif %}{% if not node.todo.is_done %}){% endif %}{% if node.todo.comment %} · {{node.todo.comment|e}}{% endif %}</td>
116 {% if not node.seen %}
117 {% for child in node.children %}
118 {{ show_node_done(child, indent+1) }}
127 <h3>{{day.date}} / {{day.weekday}} ({{day.total_effort|round(1)}})</h3>
129 <a href="day?date={{day.prev_date}}">prev</a> | <a href="day?date={{day.next_date}}">next</a>
131 <form action="day?date={{day.date}}" method="POST">
135 <input name="day_comment" type="text" value="{{day.comment|e}}" />
136 <input type="submit" value="OK" /></td>
142 add: <input type="text" name="new_todo" list="processes">
146 <select name="make_type">
147 <option value="full">with</option>
148 <option value="empty"{% if make_type == "empty" %}selected {% endif %}>without</option>
150 descendants (i.e. adopt where possible, otherwise create anew)
156 <th colspan={{ conditions_present|length + 3 + conditions_present|length }}>conditions</th>
158 <th>add disabler</th>
161 {% for condition in conditions_present %}
162 {% set outer_loop = loop %}
165 {% for _ in conditions_present %}
166 {% if outer_loop.index > loop.index %}
167 <td class="cond_line_{{loop.index0 % 3}}">
168 {% elif outer_loop.index < loop.index %}
169 <td class="cond_line_{{outer_loop.index0 % 3}}">
171 <td class="cond_line_{{outer_loop.index0 % 3}} cond_line_corner">×
176 <td class="cond_line_{{loop.index0 % 3}}"><input type="checkbox" disabled{% if condition.is_active %} checked{% endif %}></td>
177 <td colspan=2 class="cond_line_{{loop.index0 % 3}}"><a href="condition?id={{condition.id_}}">{{condition.title.at(day.date)|e}}</a></td>
179 {% for _ in conditions_present %}
180 {% if outer_loop.index0 + loop.index < conditions_present|length %}
181 <td class="cond_line_{{outer_loop.index0 % 3}}">
182 {% elif outer_loop.index0 + loop.index > conditions_present|length %}
183 <td class="cond_line_{{(conditions_present|length - loop.index) % 3}}">
185 <td class="cond_line_{{outer_loop.index0 % 3}} cond_line_corner"> ×
189 {% set list_name = "todos_for_%s"|format(condition.id_) %}
190 <td><input class="ablers" type="text" name="new_todo" list="{{list_name}}" autocomplete="off" /></td>
191 {{ macros.datalist_of_titles(list_name, enablers_for[condition.id_]) }}
193 {% set list_name = "todos_against_%s"|format(condition.id_) %}
194 <td><input class="ablers" type="text" name="new_todo" list="{{list_name}}" autocomplete="off" /></td>
195 {{ macros.datalist_of_titles(list_name, disablers_for[condition.id_]) }}
201 {% for condition in conditions_present %}
202 <td class="cond_line_{{loop.index0 % 3}}"></td>
204 <th colspan=3>doables</th>
205 {% for condition in conditions_present %}
206 <td class="cond_line_{{(conditions_present|length - loop.index) % 3}}"></td>
208 <th colspan=2>comments</th>
210 {% for node in top_nodes %}
211 {{ show_node_undone(node, 0) }}
218 <table class="alternating">
220 <th colspan=2>effort</th><th rowspan=2>action · comment</th>
223 <th>self</th><th>tree</th>
225 {% for node in top_nodes %}
226 {{ show_node_done(node, 0, []) }}
232 {{ macros.datalist_of_titles("processes", processes) }}