home
·
contact
·
privacy
projects
/
plomtask
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
214aeb0
)
Improve multiple template layouts and refactor CSS.
author
Christian Heller
<c.heller@plomlompom.de>
Sat, 8 Jun 2024 19:04:07 +0000
(21:04 +0200)
committer
Christian Heller
<c.heller@plomlompom.de>
Sat, 8 Jun 2024 19:04:07 +0000
(21:04 +0200)
templates/_base.html
patch
|
blob
|
history
templates/condition.html
patch
|
blob
|
history
templates/day.html
patch
|
blob
|
history
templates/process.html
patch
|
blob
|
history
templates/todo.html
patch
|
blob
|
history
diff --git
a/templates/_base.html
b/templates/_base.html
index 0d2debe981a931eece26a1a8a60b2b74eb15a857..0b441719c32916e2bf0d408fdf967319b98f7a7d 100644
(file)
--- a/
templates/_base.html
+++ b/
templates/_base.html
@@
-7,6
+7,9
@@
body {
text-align: left;
padding: 0;
}
text-align: left;
padding: 0;
}
+input[type="text"] {
+ width: 100em;
+}
input.btn-harmless {
color: green;
}
input.btn-harmless {
color: green;
}
@@
-29,6
+32,11
@@
th, td {
a {
color: black;
}
a {
color: black;
}
+table.edit_table > tbody > tr > td, table.main > tbody > tr > th {
+ border-bottom: 0.1em solid #bbbbbb;
+ padding-top: 0.5em;
+ padding-bottom: 0.5em;
+}
{% block css %}
{% endblock %}
</style>
{% block css %}
{% endblock %}
</style>
diff --git
a/templates/condition.html
b/templates/condition.html
index 8deb71cbf4dac93d837fb3cd51c8fd3b6b4cce6d..7142363b3f2e24b45ed2d250d2e4144bf8406ef0 100644
(file)
--- a/
templates/condition.html
+++ b/
templates/condition.html
@@
-3,34
+3,29
@@
-{% block css %}
-input[name="title"] {
- width: 100em;
-}
-{% endblock %}
-
-
-
{% block content %}
{% block content %}
-<h3>{% if is_new %}NEW {% endif %}condition</h3>
+<h3>
+{% if is_new %}
+add NEW condition
+{% else %}
+edit condition of ID {{condition.id_}}
+{% endif %}
+</h3>
<form action="condition?id={{condition.id_ or ''}}" method="POST">
<form action="condition?id={{condition.id_ or ''}}" method="POST">
-<table>
+<table class="edit_table">
<tr>
<th>title</th>
<tr>
<th>title</th>
-<td><input name="title" value="{{condition.title.newest|e}}" />{% if condition.id_ %} [<a href="condition_titles?id={{condition.id_}}">history</a>]{% endif %}</td>
+<td><input name="title"
type="text"
value="{{condition.title.newest|e}}" />{% if condition.id_ %} [<a href="condition_titles?id={{condition.id_}}">history</a>]{% endif %}</td>
<tr/>
<tr/>
-
<tr>
<th>is active</th>
<td><input name="is_active" type="checkbox" {% if condition.is_active %}checked{% endif %} /></td>
<tr/>
<tr>
<th>is active</th>
<td><input name="is_active" type="checkbox" {% if condition.is_active %}checked{% endif %} /></td>
<tr/>
-
<tr>
<th>description</th>
<td><textarea name="description">{{condition.description.newest|e}}</textarea>{% if condition.id_ %} [<a href="condition_descriptions?id={{condition.id_}}">history</a>]{% endif %}</td>
<tr/>
<tr>
<th>description</th>
<td><textarea name="description">{{condition.description.newest|e}}</textarea>{% if condition.id_ %} [<a href="condition_descriptions?id={{condition.id_}}">history</a>]{% endif %}</td>
<tr/>
-
<tr>
<th>enables</th>
<td>
<tr>
<th>enables</th>
<td>
@@
-39,7
+34,6
@@
input[name="title"] {
{% endfor %}
</td>
</tr>
{% endfor %}
</td>
</tr>
-
<tr>
<th>disables</th>
<td>
<tr>
<th>disables</th>
<td>
@@
-48,7
+42,6
@@
input[name="title"] {
{% endfor %}
</td>
</tr>
{% endfor %}
</td>
</tr>
-
<tr>
<th>enabled by</th>
<td>
<tr>
<th>enabled by</th>
<td>
@@
-57,7
+50,6
@@
input[name="title"] {
{% endfor %}
</td>
</tr>
{% endfor %}
</td>
</tr>
-
<tr>
<th>disabled by</th>
<td>
<tr>
<th>disabled by</th>
<td>
@@
-66,8
+58,8
@@
input[name="title"] {
{% endfor %}
</td>
</tr>
{% endfor %}
</td>
</tr>
-
</table>
</table>
+
{{ macros.edit_buttons() }}
{% endblock %}
{{ macros.edit_buttons() }}
{% endblock %}
diff --git
a/templates/day.html
b/templates/day.html
index 3b2e96a9114fb819a03b9e79d05489b4ad08cc91..c3a20aaf89fde7706ab8439e4f2877a994a58ed8 100644
(file)
--- a/
templates/day.html
+++ b/
templates/day.html
@@
-4,26
+4,23
@@
{% block css %}
{% block css %}
-td, th, tr, table {
- padding: 0;
- margin: 0;
-}
table {
border-collapse: collapse;
}
th {
border: 1px solid black;
}
table {
border-collapse: collapse;
}
th {
border: 1px solid black;
}
-td.cond_line_0 {
+td.cond_line_0, td.cond_line_1, td.cond_line_2 {
+ padding: 0;
border-top: 1px solid white;
border-top: 1px solid white;
+}
+td.cond_line_0 {
background-color: #bfbfbf;
}
td.cond_line_1 {
background-color: #bfbfbf;
}
td.cond_line_1 {
- border-top: 1px solid white;
background-color: #dfdfdf;
}
td.cond_line_2 {
background-color: #dfdfdf;
}
td.cond_line_2 {
- border-top: 1px solid white;
background-color: #fffff;
}
td.cond_line_corner {
background-color: #fffff;
}
td.cond_line_corner {
@@
-36,10
+33,10
@@
td.todo_line {
border-bottom: 1px solid #bfbfbf;
height: 1.7em;
}
border-bottom: 1px solid #bfbfbf;
height: 1.7em;
}
-tr.inactive td.todo_line {
+tr.inactive
>
td.todo_line {
background-color: #bfbfbf;
}
background-color: #bfbfbf;
}
-tr.hidden_undone td, tr.hidden_undone a {
+tr.hidden_undone
>
td, tr.hidden_undone a {
color: #9f9f9f;
}
td.left_border {
color: #9f9f9f;
}
td.left_border {
diff --git
a/templates/process.html
b/templates/process.html
index 064e83da1dae009da6c1c396a978d114d59b2a65..4027f502cbc19e46afe42c400e0c9eb3e8a36a81 100644
(file)
--- a/
templates/process.html
+++ b/
templates/process.html
@@
-4,9
+4,6
@@
{% block css %}
{% block css %}
-input[type="text"] {
- width: 100em;
-}
details > summary::after {
content: '[+]';
}
details > summary::after {
content: '[+]';
}
@@
-16,11
+13,6
@@
details summary {
details[open] > summary::after {
content: '[-]';
}
details[open] > summary::after {
content: '[-]';
}
-table.main > tbody > tr > td, table.main > tbody > tr > th {
- border-bottom: 0.1em solid #bbbbbb;
- padding-top: 0.5em;
- padding-bottom: 0.5em;
-}
{% endblock %}
{% endblock %}
@@
-61,11
+53,11
@@
table.main > tbody > tr > td, table.main > tbody > tr > th {
{% endif %}
</td>
{% endif %}
</td>
-<td>
{% if (not step_node.is_explicit) and (not step_node.seen) %}
{% if (not step_node.is_explicit) and (not step_node.seen) %}
+<td>
<input type="checkbox" name="suppresses" value="{{step_id}}" {% if step_node.is_suppressed %}checked{% endif %}> suppress
<input type="checkbox" name="suppresses" value="{{step_id}}" {% if step_node.is_suppressed %}checked{% endif %}> suppress
-{% endif %}
</td>
</td>
+{% endif %}
</tr>
{% if step_node.is_explicit or not step_node.seen %}
{% for substep_id, substep in step_node.steps.items() %}
</tr>
{% if step_node.is_explicit or not step_node.seen %}
{% for substep_id, substep in step_node.steps.items() %}
@@
-85,48
+77,40
@@
edit process of ID {{process.id_}}
{% endif %}
</h3>
<form action="process?id={{process.id_ or ''}}" method="POST">
{% endif %}
</h3>
<form action="process?id={{process.id_ or ''}}" method="POST">
-<table class="main">
+<table class="edit_table">
<tr>
<th>title</th>
<tr>
<th>title</th>
-<td><input name="title" value="{{process.title.newest|e}}" />{% if process.id_ %} [<a href="process_titles?id={{process.id_}}">history</a>]{% endif %}</td>
+<td><input name="title"
type="text"
value="{{process.title.newest|e}}" />{% if process.id_ %} [<a href="process_titles?id={{process.id_}}">history</a>]{% endif %}</td>
</tr>
</tr>
-
<tr>
<th>default effort</th>
<td><input name="effort" type="number" step=0.1 value={{process.effort.newest}} />{% if process.id_ %} [<a href="process_efforts?id={{process.id_}}">history</a>]{% endif %}</td>
</tr>
<tr>
<th>default effort</th>
<td><input name="effort" type="number" step=0.1 value={{process.effort.newest}} />{% if process.id_ %} [<a href="process_efforts?id={{process.id_}}">history</a>]{% endif %}</td>
</tr>
-
<tr>
<th>description</th>
<td><textarea name="description">{{process.description.newest|e}}</textarea><br />{% if process.id_ %} [<a href="process_descriptions?id={{process.id_}}">history</a>]{% endif %}</td>
</tr>
<tr>
<th>description</th>
<td><textarea name="description">{{process.description.newest|e}}</textarea><br />{% if process.id_ %} [<a href="process_descriptions?id={{process.id_}}">history</a>]{% endif %}</td>
</tr>
-
<tr>
<th>calendarize</th>
<td><input type="checkbox" name="calendarize" {% if process.calendarize %}checked {% endif %}</td>
</tr>
<tr>
<th>calendarize</th>
<td><input type="checkbox" name="calendarize" {% if process.calendarize %}checked {% endif %}</td>
</tr>
-
<tr>
<th>conditions</th>
<td>{{ macros.simple_checkbox_table("condition", process.conditions, "condition", "condition_candidates") }}</td>
</tr>
<tr>
<th>conditions</th>
<td>{{ macros.simple_checkbox_table("condition", process.conditions, "condition", "condition_candidates") }}</td>
</tr>
-
<tr>
<th>blockers</th>
<td>{{ macros.simple_checkbox_table("blocker", process.blockers, "condition", "condition_candidates") }}</td>
</tr>
<tr>
<th>blockers</th>
<td>{{ macros.simple_checkbox_table("blocker", process.blockers, "condition", "condition_candidates") }}</td>
</tr>
-
<tr>
<th>enables</th>
<td>{{ macros.simple_checkbox_table("enables", process.enables, "condition", "condition_candidates") }}</td>
</tr>
<tr>
<th>enables</th>
<td>{{ macros.simple_checkbox_table("enables", process.enables, "condition", "condition_candidates") }}</td>
</tr>
-
<tr>
<th>disables</th>
<td>{{ macros.simple_checkbox_table("disables", process.disables, "condition", "condition_candidates") }}</td>
</tr>
<tr>
<th>disables</th>
<td>{{ macros.simple_checkbox_table("disables", process.disables, "condition", "condition_candidates") }}</td>
</tr>
-
<tr>
<th>steps</th>
<td>
<tr>
<th>steps</th>
<td>
@@
-138,23
+122,20
@@
edit process of ID {{process.id_}}
add: <input name="new_top_step" list="process_candidates" autocomplete="off" value="{{preset_top_step or ''}}" />
</td>
</tr>
add: <input name="new_top_step" list="process_candidates" autocomplete="off" value="{{preset_top_step or ''}}" />
</td>
</tr>
-
<tr>
<th>step of</th>
<td>{{ macros.simple_checkbox_table("step_of", owners, "process", "process_candidates") }}</td>
</tr>
<tr>
<th>step of</th>
<td>{{ macros.simple_checkbox_table("step_of", owners, "process", "process_candidates") }}</td>
</tr>
-
<tr>
<th>todos</th>
<td>
<a href="todos?process_id={{process.id_}}">{{n_todos}}</a><br />
</td>
</tr>
<tr>
<th>todos</th>
<td>
<a href="todos?process_id={{process.id_}}">{{n_todos}}</a><br />
</td>
</tr>
-
</table>
</table>
+
{{ macros.edit_buttons() }}
</form>
{{ macros.edit_buttons() }}
</form>
-
{{ macros.datalist_of_titles("condition_candidates", condition_candidates) }}
{{ macros.datalist_of_titles("process_candidates", process_candidates) }}
{% endblock %}
{{ macros.datalist_of_titles("condition_candidates", condition_candidates) }}
{{ macros.datalist_of_titles("process_candidates", process_candidates) }}
{% endblock %}
diff --git
a/templates/todo.html
b/templates/todo.html
index 870eab35dd91449e367d15f4ca3c4bc1d95ae806..05e5b62c8aebfd0224ca3655b40e5dae906e3984 100644
(file)
--- a/
templates/todo.html
+++ b/
templates/todo.html
@@
-6,58
+6,48
@@
{% block content %}
<h3>Todo: {{todo.title_then|e}}</h3>
<form action="todo?id={{todo.id_}}" method="POST">
{% block content %}
<h3>Todo: {{todo.title_then|e}}</h3>
<form action="todo?id={{todo.id_}}" method="POST">
-<table>
+<table class="edit_table">
<tr>
<th>day</th>
<td><a href="day?date={{todo.date}}">{{todo.date}}</a></td>
</tr>
<tr>
<th>day</th>
<td><a href="day?date={{todo.date}}">{{todo.date}}</a></td>
</tr>
-
<tr>
<th>process</th>
<td><a href="process?id={{todo.process.id_}}">{{todo.process.title.newest|e}}</a></td>
</tr>
<tr>
<th>process</th>
<td><a href="process?id={{todo.process.id_}}">{{todo.process.title.newest|e}}</a></td>
</tr>
-
<tr>
<th>done</th>
<td><input type="checkbox" name="done" {% if todo.is_done %}checked {% endif %} {% if not todo.is_doable %}disabled {% endif %}/><br /></td>
</tr>
<tr>
<th>done</th>
<td><input type="checkbox" name="done" {% if todo.is_done %}checked {% endif %} {% if not todo.is_doable %}disabled {% endif %}/><br /></td>
</tr>
-
<tr>
<th>effort</th>
<td><input type="number" name="effort" step=0.1 size=5 placeholder={{todo.effort_then}} value={{todo.effort}} /><br /></td>
</tr>
<tr>
<th>effort</th>
<td><input type="number" name="effort" step=0.1 size=5 placeholder={{todo.effort_then}} value={{todo.effort}} /><br /></td>
</tr>
-
<tr>
<th>comment</th>
<tr>
<th>comment</th>
-<td><input name="comment" value="{{todo.comment|e}}"/></td>
+<td><input name="comment"
type="text"
value="{{todo.comment|e}}"/></td>
</tr>
</tr>
-
<tr>
<th>calendarize</th>
<td><input type="checkbox" name="calendarize" {% if todo.calendarize %}checked {% endif %}</td>
</tr>
<tr>
<th>calendarize</th>
<td><input type="checkbox" name="calendarize" {% if todo.calendarize %}checked {% endif %}</td>
</tr>
-
<tr>
<th>conditions</th>
<td>{{ macros.simple_checkbox_table("condition", todo.conditions, "condition", "condition_candidates") }}</td>
</tr>
<tr>
<th>conditions</th>
<td>{{ macros.simple_checkbox_table("condition", todo.conditions, "condition", "condition_candidates") }}</td>
</tr>
-
<tr>
<th>blockers</th>
<td>{{ macros.simple_checkbox_table("blocker", todo.blockers, "condition", "condition_candidates") }}</td>
</tr>
<tr>
<th>blockers</th>
<td>{{ macros.simple_checkbox_table("blocker", todo.blockers, "condition", "condition_candidates") }}</td>
</tr>
-
<tr>
<th>enables</th>
<td>{{ macros.simple_checkbox_table("enables", todo.enables, "condition", "condition_candidates") }}</td>
</tr>
<tr>
<th>enables</th>
<td>{{ macros.simple_checkbox_table("enables", todo.enables, "condition", "condition_candidates") }}</td>
</tr>
-
<tr>
<th>disables</th>
<td>{{ macros.simple_checkbox_table("disables", todo.disables, "condition", "condition_candidates") }}</td>
</tr>
<tr>
<th>disables</th>
<td>{{ macros.simple_checkbox_table("disables", todo.disables, "condition", "condition_candidates") }}</td>
</tr>
-
<tr>
<th>parents</th>
<td>
<tr>
<th>parents</th>
<td>
@@
-66,17
+56,15
@@
{% endfor %}
</td>
</tr>
{% endfor %}
</td>
</tr>
-
<tr>
<th>children</th>
<td>{{ macros.simple_checkbox_table("adopt", todo.children, "todo", "todo_candidates", "adopt", true) }}<br />
<tr>
<th>children</th>
<td>{{ macros.simple_checkbox_table("adopt", todo.children, "todo", "todo_candidates", "adopt", true) }}<br />
-make: <input name="make" list="process_candidates" autocomplete="off" /></td>
+make: <input
type="text"
name="make" list="process_candidates" autocomplete="off" /></td>
</tr>
</tr>
-
</table>
</table>
+
{{ macros.edit_buttons() }}
</form>
{{ macros.edit_buttons() }}
</form>
-
{{ macros.datalist_of_titles("condition_candidates", condition_candidates) }}
{{ macros.datalist_of_titles("process_candidates", process_candidates) }}
<datalist id="todo_candidates">
{{ macros.datalist_of_titles("condition_candidates", condition_candidates) }}
{{ macros.datalist_of_titles("process_candidates", process_candidates) }}
<datalist id="todo_candidates">