Attempt to fix unpaid hours not displaying
This commit is contained in:
parent
ebfc4ddc05
commit
5c67ec76b2
3 changed files with 10 additions and 5 deletions
|
@ -70,10 +70,15 @@ class SessionData {
|
|||
|
||||
static String GetUnpaidHours() {
|
||||
// This is the inverted value of paid hours. We get total hours and subtract it from the paid hours. This gives us the unpaid hours.
|
||||
Duration totalTime = EndTime.difference(StartTime);
|
||||
Duration unpaid = _GetPaidHours() - totalTime;
|
||||
Time totalHoursWorked = Time.fromNotation(GetPaidHours());
|
||||
|
||||
return Duration2Notation(unpaid);
|
||||
Duration totalDuration = EndTime.difference(StartTime);
|
||||
Time totalTime = Time.fromDuration(totalDuration);
|
||||
|
||||
Time unpaid = totalTime.copy();
|
||||
unpaid.subtract(totalHoursWorked);
|
||||
|
||||
return unpaid.toString();
|
||||
}
|
||||
|
||||
static String GetTotalMilesAsString() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue