48 lines
1.7 KiB
PHP
48 lines
1.7 KiB
PHP
<div>
|
|
<table class="p-2" wire:poll.5s>
|
|
<thead>
|
|
<tr>
|
|
<th class="px-4 py-2">Bot</th>
|
|
<th class="px-4 py-2">Status</th>
|
|
<th class="px-4 py-2">Started At</th>
|
|
<th class="px-4 py-2">Finished At</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody class="text-center">
|
|
@foreach ($logs as $log)
|
|
<tr>
|
|
<td class="px-4 py-2">
|
|
{{ $log->bot->name }}
|
|
</td>
|
|
<td
|
|
@class([
|
|
"text-red-400" => $log->status === "failed",
|
|
"text-green-400" => $log->status === "success",
|
|
"text-yellow-400" => $log->status === "pending",
|
|
]),
|
|
class="px-4 py-2"
|
|
@if ($log->status === "failed")
|
|
wire:click="showError({{ $log->id }})"
|
|
style="cursor: pointer;"
|
|
@endif
|
|
>
|
|
{{ $log->status }}
|
|
@if ($log->status === "failed")
|
|
<i class="fas fa-exclamation-circle ml-1"></i>
|
|
@endif
|
|
</td>
|
|
<td class="px-4 py-2">
|
|
{{ $log->started_at ?? "" }}
|
|
</td>
|
|
<td class="px-4 py-2">
|
|
{{ $log->finished_at ?? "" }}
|
|
</td>
|
|
</tr>
|
|
@endforeach
|
|
</tbody>
|
|
</table>
|
|
<div class="mt-4">
|
|
{{ $logs->links() }}
|
|
</div>
|
|
</div>
|