@section('site_title', formatTitle([$monitor->name, __('Monitor'), config('settings.title')])) @include('monitors.header')
{{ __('Uptime') }}
@php $fromNew = (\Carbon\Carbon::createFromFormat('Y-m-d', $range['from'], Auth::user()->timezone ?? config('settings.timezone'))->startOfDay()->lt($monitor->created_at) ? $monitor->created_at : \Carbon\Carbon::createFromFormat('Y-m-d', $range['from'], Auth::user()->timezone ?? config('settings.timezone'))->startOfDay()); $toNew = (\Carbon\Carbon::createFromFormat('Y-m-d', $range['to'], Auth::user()->timezone ?? config('settings.timezone'))->isSameDay((clone $now)) || \Carbon\Carbon::createFromFormat('Y-m-d', $range['to'], Auth::user()->timezone ?? config('settings.timezone'))->gt((clone $now)) ? (clone $now) : \Carbon\Carbon::createFromFormat('Y-m-d', $range['to'], Auth::user()->timezone ?? config('settings.timezone'))->addDay()->startOfDay()); @endphp
@php \Carbon\Carbon::disableHumanDiffOption(\Carbon\Carbon::NO_ZERO_DIFF); @endphp
{{ formatDiffWithSpacing($fromNew->diffForHumans((clone $toNew)->subMicroseconds($totalIncidentsDuration), ['syntax' => true, 'parts' => 2, 'join' => true, 'short' => true])) }}
@include('icons.info', ['class' => 'width-4 height-4 fill-current text-muted'])
@php \Carbon\Carbon::enableHumanDiffOption(\Carbon\Carbon::NO_ZERO_DIFF); @endphp
{{ formatUptimePercentageNumber((\Carbon\Carbon::createFromFormat('Y-m-d', $range['from'], Auth::user()->timezone ?? config('settings.timezone'))->startOfDay()->lt($monitor->created_at->tz(Auth::user()->timezone ?? config('settings.timezone'))) ? $monitor->created_at->tz(Auth::user()->timezone ?? config('settings.timezone'))->diffInMicroseconds($toNew) : \Carbon\Carbon::createFromFormat('Y-m-d', $range['from'], Auth::user()->timezone ?? config('settings.timezone'))->startOfDay()->diffInMicroseconds($toNew)), $totalIncidentsDuration, 2, __('.'), __(',')) }}%
{{ __('Response time') }}
{{ __(':number checks', ['number' => number_format($totalChecks, 0, __('.'), __(','))]) }}
{{ ($totalChecksResponseTime ? number_format((($totalChecksResponseTime / $totalChecks) / 1000), 0, __('.'), __(',')) : '0') }} ms
{{ __('Incidents') }}
@php \Carbon\Carbon::disableHumanDiffOption(\Carbon\Carbon::NO_ZERO_DIFF); @endphp
{{ formatDiffWithSpacing((clone $now)->diffForHumans((clone $now)->subMicroseconds($totalIncidentsDuration), ['syntax' => true, 'parts' => 2, 'join' => true, 'short' => true])) }}
@include('icons.info', ['class' => 'width-4 height-4 fill-current text-muted'])
@php \Carbon\Carbon::enableHumanDiffOption(\Carbon\Carbon::NO_ZERO_DIFF); @endphp
{{ $totalIncidents ?: '0' }}
{{ __('Checks') }}
@if(count($checks) == 0) {{ __('No data') }}. @else
{{ __('Response status code') }}
{{ __('Response time') }}
@foreach($checks as $check)
{{ $check->response_status_code }}
{{ ($check->response_time ? number_format(($check->response_time / 1000), 0, __('.'), __(',')) : 0) }} ms
@endforeach
@endif
@if(count($checks) > 0) @endif
{{ __('Incidents') }}
@if(count($incidents) == 0)
@include('icons.check-circle-filled', ['class' => 'width-4 height-4 fill-current text-success ' . (__('lang_dir') == 'rtl' ? 'ml-2' : 'mr-2')])
{{ __('No incidents found.') }}
@else
{{ __('Cause') }}
{{ __('Duration') }}
@foreach($incidents as $incident)
@include('icons.' . ($incident->status == 'resolved' ? 'check-circle-filled' : ($incident->status == 'unresolved' ? 'error-filled' : 'offline-bolt-filled')), ['class' => 'width-4 height-4 fill-current ' . ($incident->status == 'resolved' ? 'text-success' : ($incident->status == 'unresolved' ? 'text-danger' : 'text-warning'))])​
@php \Carbon\Carbon::disableHumanDiffOption(\Carbon\Carbon::NO_ZERO_DIFF); @endphp {{ formatDiffWithSpacing($incident->started_at->diffForHumans($incident->ended_at ?? \Carbon\Carbon::now(), ['syntax' => true, 'parts' => 2, 'join' => true, 'short' => true])) }} @php \Carbon\Carbon::enableHumanDiffOption(\Carbon\Carbon::NO_ZERO_DIFF); @endphp
@endforeach
@endif
@if(count($incidents) > 0) @endif
{{ __('Report generated on :date at :time (UTC :offset).', ['date' => (clone $now)->tz(Auth::user()->timezone ?? config('settings.timezone'))->format(__('Y-m-d')), 'time' => (clone $now)->tz(Auth::user()->timezone ?? config('settings.timezone'))->format('H:i:s'), 'offset' => (clone $now)->tz(Auth::user()->timezone ?? config('settings.timezone'))->getOffsetString()]) }} {{ __('Refresh report') }}