@extends('admin.layouts.app') @section('title', 'Analytics') @section('page_title', 'Analytics Intelligence') @section('content') @php $tab = $tab ?? 'overview'; $kpis = $kpis ?? []; $tabs = [ 'overview' => ['label' => 'Overview', 'hint' => 'Command center'], 'visitors' => ['label' => 'Visitors', 'hint' => 'Traffic identity'], 'unique' => ['label' => 'Unique', 'hint' => 'IPs & visitors'], 'sessions' => ['label' => 'Sessions', 'hint' => 'Duration & quality'], 'pages' => ['label' => 'Pages', 'hint' => 'Paths & bounce'], 'geography' => ['label' => 'Geography', 'hint' => 'Countries & cities'], 'devices' => ['label' => 'Devices', 'hint' => 'Browser & OS'], 'sources' => ['label' => 'Sources', 'hint' => 'Referrers & UTM'], 'engagement' => ['label' => 'Engagement', 'hint' => 'Scroll & CTAs'], 'funnels' => ['label' => 'Funnels', 'hint' => 'Abandonment'], 'ips' => ['label' => 'IP intel', 'hint' => 'Address ledger'], 'log' => ['label' => 'Event log', 'hint' => 'Raw stream'], ]; $ranges = [1 => '24h', 7 => '7d', 14 => '14d', 30 => '30d', 90 => '90d']; $maxTrend = max(1, collect($trend ?? [])->max('events') ?: 1); $maxHourly = max(1, collect($hourly ?? [])->max('total') ?: 1); @endphp

Intelligence · Behavioural analytics

Analytics command center

Visitors, unique IPs, geography, devices, sources, engagement, and abandonment — a full behavioural picture of {{ config('app.name', 'Apex Admins') }}.

@foreach($ranges as $value => $label) {{ $label }} @endforeach
Page views {{ number_format($kpis['page_views'] ?? 0) }} Sessions {{ number_format($kpis['sessions'] ?? 0) }} Visitors {{ number_format($kpis['visitors'] ?? 0) }} Unique IPs {{ number_format($kpis['unique_ips'] ?? 0) }} Countries {{ number_format($kpis['countries'] ?? 0) }} Conv. rate {{ number_format($kpis['conversion_rate'] ?? 0, 1) }}% Abandonment {{ number_format($kpis['abandonment_rate'] ?? 0, 1) }}% Bounce {{ number_format($kpis['bounce_rate'] ?? 0, 1) }}%
@foreach ($tabs as $key => $meta) {{ $meta['label'] }} {{ $meta['hint'] }} @endforeach
@include('admin.analytics.tabs.'.$tab)
@endsection