[Getan-commits] [PATCH] Fixes ability to change length of saved entries

Wald Commits scm-commit at wald.intevation.org
Tue Feb 28 12:15:33 CET 2017


# HG changeset patch
# User Bernhard Reiter <bernhard at intevation.de>
# Date 1488280496 -3600
# Node ID ee98d0b45967e079e3cd9f136f6568d508432639
# Parent  84f9b1eeb8b633ef4d230beb2a5f3f395a32e5ac
Fixes ability to change length of saved entries.

.. in the subcase that the saved length was less than a full hour.

diff -r 84f9b1eeb8b6 -r ee98d0b45967 getan/states.py
--- a/getan/states.py	Fri Feb 10 15:30:56 2017 +0100
+++ b/getan/states.py	Tue Feb 28 12:14:56 2017 +0100
@@ -859,7 +859,7 @@
             self.footer.set_edit_text(
                 "{:d}:{:d}".format(hours, int(total_minutes % 60)))
         else:
-            self.footer.set_edit_text(int(minutes))
+            self.footer.set_edit_text("{:d}".format(total_minutes))
 
         self.footer.set_edit_pos(len(self.footer.edit_text))
         self.entry = entry


More information about the Getan-commits mailing list