Files
erpnext/erpnext/projects
Marc Ramser 0670765baa fix(Timesheet): only update to_time if it's more than 1 second off (#47703)
* Only update to_time if it's more than 1 second off

Before, to_time was updated even when it was almost the same as the expected time (like 17:20 vs 17:19:59.998). This causes problems because of small rounding errors and caused valid times like 17:20 to be reset. Now, to_time is only updated if the difference is greater than 1 second.

To reproduce the current error:

From Time 09:00:00
To Time 17:20:00 Save
To Time is 17:19:59

* Change data to self in timesheet

* Update timesheet_detail.py
2025-06-03 11:58:00 +05:30
..
2024-03-10 19:45:40 +05:30