@extends('layouts.app')
@section('title', 'PON '.$pon->pon_port)
@section('content')
@php
$pct = $pon->ports_total > 0 ? round($pon->ports_used / $pon->ports_total * 100, 1) : 0;
$byHealth = $pon->onus->groupBy('optical_health');
@endphp
{{ $pon->pon_port }}
{{ $pon->olt?->name ?: 'Unassigned OLT' }}
@if ($pon->splitter) · {{ $pon->splitter }} @endif
@if ($pon->cabinet) · {{ $pon->cabinet }} @endif
Edit
@if ($pon->onus()->count() === 0)
@endif
@include('components.kpi', ['label' => 'Split ratio', 'value' => '1:'.$pon->split_ratio, 'variant' => 'info'])
@include('components.kpi', ['label' => 'Ports used', 'value' => $pon->ports_used.' / '.$pon->ports_total,
'variant' => $pct >= 100 ? 'bad' : ($pct >= 90 ? 'warn' : 'good')])
@include('components.kpi', ['label' => 'ONTs attached', 'value' => (string) $pon->onus->count()])
@include('components.kpi', ['label' => 'Reach', 'value' => $pon->distance_km ? $pon->distance_km.' km' : '—'])
@foreach (['excellent', 'good', 'degraded', 'critical', 'unknown'] as $h)
@if (($byHealth[$h] ?? collect())->count() > 0)
@include('components.kpi', [
'label' => title_case_words($h).' signal',
'value' => (string) ($byHealth[$h] ?? collect())->count(),
'variant' => $h === 'critical' ? 'bad' : ($h === 'degraded' ? 'warn' : 'good'),
'href' => route('fibre.onus', ['pon_id' => $pon->id, 'health' => $h]),
])
@endif
@endforeach
ONTs on this port
{{ title_case_words($pon->status) }}
@if ($pon->onus->isEmpty())
@include('components.empty-state', [
'icon' => '📡',
'title' => 'No ONTs on this port',
'message' => 'ONTs are registered when a fibre service is activated.',
])
@else
| Serial | Vendor / model | Service | Customer |
Rx | Tx | Optical |
Distance | Last seen | Status |
@foreach ($pon->onus as $onu)
| {{ $onu->serial_number }} |
{{ $onu->vendor ?: '—' }} {{ $onu->model }} |
@if ($onu->service)
{{ $onu->service->service_number }}
@else unbound @endif
|
{{ $onu->service?->customer?->display_name ?: '—' }} |
{{ $onu->rx_power_dbm !== null ? $onu->rx_power_dbm.' dBm' : '—' }} |
{{ $onu->tx_power_dbm !== null ? $onu->tx_power_dbm.' dBm' : '—' }} |
{{ title_case_words($onu->optical_health) }} |
{{ $onu->distance_km ? $onu->distance_km.' km' : '—' }} |
{{ $onu->last_seen_at?->diffForHumans() ?: 'never' }} |
{{ title_case_words($onu->status) }} |
@endforeach
@endif
@endsection