@extends('shaun_core::admin.layouts.master') @section('content')
@if(auth()->user()->isSuperAdmin())
{{formatNumberNoRound($userCount)}}
{{__('Online')}}
{{formatNumberNoRound($userOnlineCount)}}/{{formatNumberNoRound($userCount)}}
@php $percent = round($userOnlineCount/$userCount,2)*100; @endphp
{{__('Last online 15 days ago')}}
{{formatNumberNoRound($userActiveCount)}}/{{formatNumberNoRound($userCount)}}
@php $percent = round($userActiveCount/$userCount,2)*100; @endphp
{{__('Last online more than 15 days')}}
{{formatNumberNoRound($userInActiveCount)}}/{{formatNumberNoRound($userCount)}}
@php $percent = round($userInActiveCount/$userCount,2)*100; @endphp
{{formatNumberNoRound($pageCount)}}
{{__('Online')}}
{{formatNumberNoRound($pageOnlineCount)}}/{{formatNumberNoRound($pageCount)}}
@php $percent = 0; if ($pageCount) { $percent = round($pageOnlineCount/$pageCount,2)*100; } @endphp
{{__('Last online 15 days ago')}}
{{formatNumberNoRound($pageActiveCount)}}/{{formatNumberNoRound($pageCount)}}
@php $percent = 0; if ($pageCount) { $percent = round($pageActiveCount/$pageCount,2)*100; } @endphp
{{__('Last online more than 15 days')}}
{{formatNumberNoRound($pageInActiveCount)}}/{{formatNumberNoRound($pageCount)}}
@php $percent = 0; if ($pageCount) { $percent = round($pageInActiveCount/$pageCount,2)*100; } @endphp
{{__('Site Info')}}
{{__('Files')}}
{{$fileCount}}

{{__('Posts')}}
{{$postCount}}

{{__('Groups')}}
{{$groupCount}}

{{__('Hashtags')}}
{{$hashtagCount}}

{{__('Reports')}}
{{$reportCount}}

{{__('Listings')}}
{{$listingCount}}

@if(setting('shaun_event.enable'))
{{__('Events')}}
{{$eventCount}}
@endif {{-- Plugin-contributed Site Info rows. Replaces the hardcoded per-package count blocks core used to ship (e.g. the pre-extraction Courses row that read $courseCount from DashboardController::index). Each plugin's ApplicationServiceProvider::boot() registers a filter: Hook::addFilter('admin.dashboard.site_info_rows', fn(array $rows) => array_merge($rows, [[ 'label' => __('elearning::Courses'), 'count' => Course::count(), 'permission' => 'admin.elearning.manage_courses', 'route' => 'admin.elearning.courses.index', ]])); Same surface adds the rest (livestream, paid_content, chat, …) without any further Blade edit per plugin. --}} @foreach(\Packages\ShaunSocial\Plugins\Hook\Hook::applyFilters('admin.dashboard.site_info_rows', []) as $pluginRow)
@if(!empty($pluginRow['route']) && !empty($pluginRow['permission'])) @hasPermission($pluginRow['permission']) {{ $pluginRow['label'] }} @else {{ $pluginRow['label'] }} @endHasPermission @elseif(!empty($pluginRow['route'])) {{ $pluginRow['label'] }} @else {{ $pluginRow['label'] }} @endif
{{ $pluginRow['count'] ?? 0 }}
@endforeach
{{__('Posts')}}
{{__('Groups')}}
{{__('Listings')}}
@if(setting('shaun_event.enable')) @endif @hasPermission('admin.setting.site,admin.setting.general')
{{__('Notes')}}
@endHasPermission @else
{{__('Welcome to admin dashboard')}}
@endif
@stop @push('scripts-body') @endpush