@extends('layouts.user') @section('title', 'Support Tickets') @section('page-title', 'Support Tickets') @section('content')
My Support Tickets
New Ticket
@if($tickets->count() > 0)
@foreach($tickets as $ticket) @endforeach
Ticket ID Subject Category Priority Status Last Update Actions
#{{ $ticket->id }}
{{ $ticket->subject }} @if($ticket->replies_count > 0) {{ $ticket->replies_count }} replies @endif
Created: {{ $ticket->created_at->format('M j, Y') }}
{{ ucfirst($ticket->category) }} @php $priorityClass = [ 'low' => 'success', 'medium' => 'warning', 'high' => 'danger' ][$ticket->priority] ?? 'secondary'; @endphp {{ ucfirst($ticket->priority) }} @php $statusClass = [ 'open' => 'success', 'in_progress' => 'primary', 'resolved' => 'info', 'closed' => 'secondary' ][$ticket->status] ?? 'secondary'; @endphp {{ ucfirst(str_replace('_', ' ', $ticket->status)) }} {{ $ticket->updated_at->diffForHumans() }}
@if($ticket->status !== 'closed') @endif
Showing {{ $tickets->firstItem() }} to {{ $tickets->lastItem() }} of {{ $tickets->total() }} tickets
{{ $tickets->links() }}
@else

No Support Tickets

You haven't created any support tickets yet.

Create Your First Ticket
@endif
@if($tickets->count() > 0)
Open Tickets
{{ $stats['open_tickets'] }}
In Progress
{{ $stats['in_progress_tickets'] }}
Resolved
{{ $stats['resolved_tickets'] }}
Total Tickets
{{ $stats['total_tickets'] }}
@endif @endsection @push('scripts') @endpush