diff --git a/web/app/Filament/Resources/BackupResource/Pages/ManageBackups.php b/web/app/Filament/Resources/BackupResource/Pages/ManageBackups.php index 22eb507..75594f9 100644 --- a/web/app/Filament/Resources/BackupResource/Pages/ManageBackups.php +++ b/web/app/Filament/Resources/BackupResource/Pages/ManageBackups.php @@ -28,10 +28,6 @@ class ManageBackups extends ManageRecords return [ - Actions\Action::make('restoring') - ->label('Restoring backup...') - ->icon('heroicon-o-clock'), - Actions\Action::make('restore') ->hidden($restoringBackup) ->icon('heroicon-o-cloud-arrow-up') diff --git a/web/app/Livewire/JobQueueNotifications.php b/web/app/Livewire/JobQueueNotifications.php index b7e6d0b..fa8d54f 100644 --- a/web/app/Livewire/JobQueueNotifications.php +++ b/web/app/Livewire/JobQueueNotifications.php @@ -17,14 +17,18 @@ class JobQueueNotifications extends Component foreach ($getJobs as $job) { $job->payload = json_decode($job->payload); if (isset($job->payload->displayName)) { - $jobClassInstance = new $job->payload->displayName; $displayName = 'Unknown Job'; - if (method_exists($jobClassInstance, 'getDisplayName')) { - $displayName = $jobClassInstance->getDisplayName(); - } else { + + try { + $jobClassInstance = new $job->payload->displayName(); + if (method_exists($jobClassInstance, 'getDisplayName')) { + $displayName = $jobClassInstance->getDisplayName(); + } + } catch (\Exception $e) { $explodeDisplayName = explode('\\', $job->payload->displayName); $displayName = end($explodeDisplayName); } + $jobs[] = [ 'id' => $job->id, 'displayName' => $displayName, diff --git a/web/resources/views/filament/job-queue-notifications.blade.php b/web/resources/views/filament/job-queue-notifications.blade.php index 7b3e267..1e8e679 100644 --- a/web/resources/views/filament/job-queue-notifications.blade.php +++ b/web/resources/views/filament/job-queue-notifications.blade.php @@ -1,22 +1,30 @@ +
@foreach($jobs as $job) -
+
-
- {{ $job['displayName']}} +
+ Runnning...
-
+ {{--
-
+
--}}
- Running... +
+ {{ $job['displayName']}} +
+
+ +
+
@endforeach +