Commit 0a7f3ec4 authored by Dan Pascu's avatar Dan Pascu

Fixed computing hours in history entries

parent db69878d
...@@ -133,7 +133,7 @@ class HistoryEntry(object): ...@@ -133,7 +133,7 @@ class HistoryEntry(object):
if self.duration: if self.duration:
result += ' for ' result += ' for '
if self.duration.days > 0 or self.duration.seconds > 3600: if self.duration.days > 0 or self.duration.seconds > 3600:
result += '%i hours, ' % (self.duration.days*3600*24 + int(self.duration.seconds/3600)) result += '%i hours, ' % (self.duration.days*24 + int(self.duration.seconds/3600))
secs = self.duration.seconds % 3600 secs = self.duration.seconds % 3600
result += '%02i:%02i' % (int(secs/60), secs % 60) result += '%02i:%02i' % (int(secs/60), secs % 60)
if self.reason: if self.reason:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment