First working release.
Other files (not .docx) support is not guaranteed
This commit is contained in:
9
modules/time_tools/time_diff.py
Normal file
9
modules/time_tools/time_diff.py
Normal file
@@ -0,0 +1,9 @@
|
||||
import datetime
|
||||
|
||||
|
||||
def compute_time_diff(date_first, time_first,
|
||||
date_second, time_second):
|
||||
dt1 = datetime.datetime.combine(date_first, time_first)
|
||||
dt2 = datetime.datetime.combine(date_second, time_second)
|
||||
|
||||
return int((max(dt1, dt2) - min(dt1, dt2)).total_seconds() / 60)
|
||||
Reference in New Issue
Block a user