@extends('layouts.app') @section('title', 'Hotspot') @section('content')

Hotspot & vouchers

Time-limited and data-capped access sold over the counter or online.

Vouchers
@include('components.kpi', ['label' => 'Active sessions', 'value' => number_format($counts['sessions']), 'variant' => 'good', 'href' => '#sessions']) @include('components.kpi', ['label' => 'Vouchers available', 'value' => number_format($counts['available']), 'variant' => 'info', 'href' => route('hotspot.vouchers', ['status' => 'available'])]) @include('components.kpi', ['label' => 'Sold', 'value' => number_format($counts['sold']), 'href' => route('hotspot.vouchers', ['status' => 'sold'])]) @include('components.kpi', ['label' => 'Revenue', 'value' => money($counts['revenue']), 'variant' => 'good', 'href' => '#']) @include('components.kpi', ['label' => 'Locations', 'value' => $counts['locations'], 'href' => route('hotspot.locations')]) @include('components.kpi', ['label' => 'Plans', 'value' => $counts['plans'], 'href' => route('hotspot.plans')])

Redemptions — 14 days

@include('components.chart', [ 'series' => collect($redemptions)->map(fn ($p) => [ 'label' => \Carbon\Carbon::parse($p['date'])->format('d M'), 'value' => $p['total'], ])->all(), 'type' => 'bar', 'format' => 'number', 'height' => 190, ])

Hotspot plans

@forelse ($plans as $plan) @empty @endforelse
PlanPriceTimeDataSpeed
{{ $plan->name }} {{ money($plan->price) }} {{ $plan->time_limit_min ? $plan->time_limit_min.' min' : 'Unlimited' }} {{ $plan->data_limit_mb ? human_bytes($plan->data_limit_mb * 1048576) : 'Unlimited' }} {{ $plan->download_limit ? round($plan->download_limit / 1024).' / '.round($plan->upload_limit / 1024).' Mbps' : '—' }} {{ $plan->is_active ? 'active' : 'inactive' }}
@include('components.empty-state', ['icon' => '☍', 'title' => 'No hotspot plans', 'action' => ''])

Recent hotspot sessions

@forelse ($sessions as $session) @empty @endforelse
UsernameLocationStartedStoppedDuration TrafficIPStatus
{{ $session->username }} {{ $session->location?->name ?? '—' }} {{ $session->started_at?->format('d M H:i') ?? '—' }} {{ $session->stopped_at?->format('d M H:i') ?? '—' }} {{ $session->duration_label }} {{ human_bytes($session->total_octets) }} {{ $session->framed_ip ?: '—' }} {{ $session->is_online ? 'online' : 'closed' }}
@include('components.empty-state', ['icon' => '☍', 'title' => 'No hotspot sessions yet'])
@if ($sessions->hasPages())
{{ $sessions->links('partials.pagination') }}
@endif
{{-- Modals --}} @endsection