• R/O
  • SSH
  • HTTPS

pworg: Commit


Commit MetaInfo

Revision7 (tree)
Zeit2021-10-01 04:32:29
Autormateuszviste

Log Message

todo items that are done are styled differently

Ändern Zusammenfassung

Diff

--- trunk/index.php (revision 6)
+++ trunk/index.php (revision 7)
@@ -74,6 +74,16 @@
7474 echo '<input type="hidden" name="formtype" value="' . $formtype . '">' . "\n";
7575 echo '<input type="hidden" name="id" value="' . $id . '">' . "\n";
7676
77+ if ($formtype === 'TODO') {
78+ echo "status: ";
79+ if ($obj['doneday'] == 0) {
80+ echo "not done";
81+ } else {
82+ echo "done since " . day2formdate($obj['doneday']);
83+ }
84+ echo "<br><br>\n";
85+ }
86+
7787 if (($formtype === 'TODO') || ($formtype === 'MEMO')) {
7888 echo "notbefore:<br>\n";
7989 if (!empty($obj)) {
@@ -369,10 +379,12 @@
369379 }
370380 if ($row['doneday'] == 0) {
371381 $checkbox = '&#9744;';
382+ $classname = 'todo';
372383 } else {
373384 $checkbox = '&#9745;';
385+ $classname = 'tododone';
374386 }
375- echo ' <div class="todo"><a href="?day=' . $day . '&amp;a=todocheck&amp;id=' . $row['id'] . '">' . $checkbox . '</a> <a href="?a=todo&amp;day=' . $day . '&amp;id=' . $row['id'] . '">' . htmlspecialchars($row['title']) . "</a></div>\n";
387+ echo ' <div class="' . $classname . '"><a href="?day=' . $day . '&amp;a=todocheck&amp;id=' . $row['id'] . '">' . $checkbox . '</a> <a href="?a=todo&amp;day=' . $day . '&amp;id=' . $row['id'] . '">' . htmlspecialchars($row['title']) . "</a></div>\n";
376388 }
377389 $sqlres->finalize();
378390 echo "</div>\n";
--- trunk/style.css (revision 6)
+++ trunk/style.css (revision 7)
@@ -74,7 +74,7 @@
7474 margin-top: 1em;
7575 }
7676
77-div.event, div.eventpast, div.memo, div.todo {
77+div.event, div.eventpast, div.memo, div.todo, div.tododone {
7878 margin: 0.2em 0;
7979 border: 1px #ccc solid;
8080 border-radius: 0.25em;
@@ -91,6 +91,10 @@
9191 background: #ffd;
9292 }
9393
94+div.tododone {
95+ background: #eee;
96+}
97+
9498 div.eventpast {
9599 color: #222;
96100 background: #eec;
@@ -197,6 +201,11 @@
197201 background: inherit;
198202 }
199203
204+ div.event, div.eventpast, div.todo, div.tododone, div.memo {
205+ background: #111;
206+ border-color: #888;
207+ }
208+
200209 div.event {
201210 background: #222;
202211 }
@@ -203,13 +212,16 @@
203212
204213 div.eventpast {
205214 color: #666;
206- background: #111;
207215 }
208216
209217 div.todo {
210- background: #111;
211218 }
212219
220+ div.tododone {
221+ border-color: #666;
222+ color: #999;
223+ }
224+
213225 div.memo {
214226 background: #222;
215227 }
Show on old repository browser