@extends("admin.layouts.app") @section("title", __("admin.products.title")) @section("content")
@foreach(["" => "All", "active" => "Active", "suspended" => "Suspended", "terminated" => "Terminated", "pending" => "Pending", "cancelled" => "Cancelled"] as $val => $label) @php $isActive = (request("status","") == $val); @endphp $val]) }}" style="display:inline-block;padding:8px 16px;font-size:13px;text-decoration:none;color:{{ $isActive ? "#1a4d80" : "#666" }};font-weight:{{ $isActive ? "700" : "400" }};border-bottom:{{ $isActive ? "3px solid #1a4d80" : "3px solid transparent" }};margin-bottom:-1px;"> {{ $label }} @endforeach
@forelse($services as $service) @php $badgeClass = match(strtolower($service->status ?? "")) { "active" => "badge-active", "pending" => "badge-pending", "suspended" => "badge-suspended", "terminated" => "badge-terminated", "cancelled" => "badge-cancelled", default => "badge-cancelled", }; @endphp @empty @endforelse
{{ __('common.table.id') }} {{ __('common.table.product') }} {{ __('common.table.client') }} {{ __('common.table.domain') }} {{ __('common.table.billing_cycle') }} {{ __('common.table.amount') }} {{ __('admin.services.next_due') }} {{ __('common.table.status') }} {{ __('common.table.actions') }}
{{ $service->id }} {{ $service->product?->name ?? "N/A" }} @if($service->client) client_id) }}" style="color:#337ab7;text-decoration:none;">{{ $service->client->full_name }} @else N/A @endif {{ $service->domain ?? "-" }} {{ ucfirst($service->billing_cycle ?? "-") }} ${{ number_format($service->amount, 2) }} {{ $service->next_due_date?->format("d M Y") ?? "-" }} {{ ucfirst($service->status ?? "") }} {{ __('common.actions.view') }}
{{ __('admin.services.no_services') }}
{{ $services->withQueryString()->links() }}
@endsection