diff --git a/timetagger/app/dialogs.py b/timetagger/app/dialogs.py index 27551cc..91e1826 100644 --- a/timetagger/app/dialogs.py +++ b/timetagger/app/dialogs.py @@ -2837,7 +2837,9 @@ def open(self, t1=None, t2=None, tags=None): close_but = self.maindiv.children[0].children[-1] close_but.onclick = self.close self._date_range.innerHTML = ( - t1_date + "  –  " + t2_date + dt.format_isodate(t1_date) + + "  –  " + + dt.format_isodate(t2_date) ) self._date_range.innerHTML += ( "  " @@ -3040,7 +3042,7 @@ def _generate_table_rows(self, t1, t2): date = dt.time2localstr(record.t1).split(" ")[0] year = int(date.split("-")[0]) if group_period == "day": - period = "-".join(reversed(date.split("-"))) + period = dt.format_isodate(date) elif group_period == "week": week = dt.get_weeknumber(record.t1) period = f"{year}W{week}" @@ -3114,7 +3116,7 @@ def _generate_table_rows(self, t1, t2): "record", record.key, duration, - sd1, + dt.format_isodate(sd1), st1, st2, to_str(record.get("ds", "")), # strip tabs and newlines @@ -3261,8 +3263,8 @@ def _save_as_pdf(self): # ) tagname = self._tags.join(" ") if self._tags else "all" - d1 = reversed(self._t1_date.split("-")).join("-") - d2 = reversed(self._t2_date.split("-")).join("-") + d1 = dt.format_isodate(self._t1_date) + d2 = dt.format_isodate(self._t2_date) doc.setFontSize(11) doc.text("Tags: ", margin + 20, margin + 15, {"align": "right"}) doc.text(tagname, margin + 20, margin + 15) @@ -3877,6 +3879,12 @@ def open(self, callback=None): +
Show dates as:
+
Show time as: