mirror of
https://github.com/itflow-org/itflow
synced 2026-11-28 07:08:58 +00:00
QoL 54: booking lengths, dispatch board lengths and cron run times written 1h 30m like logged time, decimal hours written 12.5 h including project hours, and the client export minutes in the same form
This commit is contained in:
@@ -189,16 +189,16 @@ $took = function ($seconds) {
|
||||
return 'under 0.1 s';
|
||||
}
|
||||
if ($seconds < 10) {
|
||||
return rtrim(rtrim(number_format($seconds, 1), '0'), '.') . ' s';
|
||||
return rtrim(rtrim(number_format($seconds, 1), '0'), '.') . 's';
|
||||
}
|
||||
if ($seconds < 60) {
|
||||
return round($seconds) . ' s';
|
||||
return round($seconds) . 's';
|
||||
}
|
||||
$minutes = intdiv(intval(round($seconds)), 60);
|
||||
if ($minutes < 60) {
|
||||
return $minutes . ' min ' . (intval(round($seconds)) % 60) . ' s';
|
||||
return $minutes . 'm ' . (intval(round($seconds)) % 60) . 's';
|
||||
}
|
||||
return intdiv($minutes, 60) . ' h ' . ($minutes % 60) . ' min';
|
||||
return intdiv($minutes, 60) . 'h ' . ($minutes % 60) . 'm';
|
||||
};
|
||||
// Job names in a sentence - "Mail Queue", "Mail Queue and Backup", "Mail Queue, Backup and Nightly Tasks" - each a link to its row
|
||||
$job_names = function ($list) {
|
||||
|
||||
Reference in New Issue
Block a user