refactor: improve data formatting and UI
- move date and duration functions to a shared function - remove duplicate code - redesigned the deployment executions tab - added start and end times for backups, scheduled tasks, deployments and docker cleanup executions - calculated the duration for backups, scheduled tasks, deployments and Docker cleanup executions - redesigned status badges with colors to make it easier to see your current status - removed dependency on dayjs - fixed calculation of execution time was sometimes incorrect
This commit is contained in:
@@ -141,17 +141,4 @@ class Executions extends Component
|
||||
|
||||
return $lines->count() > ($this->currentPage * $this->logsPerPage);
|
||||
}
|
||||
|
||||
public function formatDateInServerTimezone($date)
|
||||
{
|
||||
$serverTimezone = $this->serverTimezone;
|
||||
$dateObj = new \DateTime($date);
|
||||
try {
|
||||
$dateObj->setTimezone(new \DateTimeZone($serverTimezone));
|
||||
} catch (\Exception) {
|
||||
$dateObj->setTimezone(new \DateTimeZone('UTC'));
|
||||
}
|
||||
|
||||
return $dateObj->format('Y-m-d H:i:s T');
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user