Improvements to finding idle nodes, last_session actually only shows the last time the remote polled us
This commit is contained in:
@@ -1,3 +1,6 @@
|
||||
@use(App\Models\SystemLog)
|
||||
@use(Carbon\Carbon)
|
||||
|
||||
@extends('layouts.app')
|
||||
@section('htmlheader_title')
|
||||
Stats
|
||||
@@ -119,7 +122,7 @@
|
||||
<div class="card-header p-2">
|
||||
<span class="card-title w-100 text-dark" style="font-size: 125%;"><i class="bi bi-pc-display"></i> Systems
|
||||
<button type="button" class="btn float-end me-0" style="background-color: black; color: white;">
|
||||
{{ number_format(\App\Models\System::where('last_session','>=',\Carbon\Carbon::now()->subWeek()->startOfDay())->count()) }}
|
||||
{{ number_format(SystemLog::distinct('system_id')->where('created_at','>=',Carbon::now()->subWeek()->startOfDay())->count()) }}
|
||||
</button>
|
||||
</span>
|
||||
</div>
|
||||
@@ -188,7 +191,7 @@
|
||||
<td class="text-end">{{ number_format($o->uncollected_echomail ?? 0) }}</td>
|
||||
<td class="text-end">{{ number_format($o->uncollected_netmail ?? 0) }}</td>
|
||||
<td class="text-end">{{ number_format($o->uncollected_files ?? 0) }}</td>
|
||||
<td>{{ $o->system->last_session?->format('Y-m-d H:i') }}</td>
|
||||
<td>{{ $o->system->last_seen?->format('Y-m-d H:i') }}</td>
|
||||
<td>{{ is_null($o->system->pollmode) ? 'HOLD' : ($o->system->pollmode ? 'CRASH' : 'DAILY') }}</td>
|
||||
<td>{{ $o->system->autohold ? 'YES' : 'NO' }}</td>
|
||||
</tr>
|
||||
|
Reference in New Issue
Block a user