@extends('layouts.user') @section('title', 'Ticket #' . $ticket->id) @section('page-title', 'Ticket #' . $ticket->id) @section('content')
{{ $ticket->subject }}
@php $statusClass = [ 'open' => 'success', 'in_progress' => 'primary', 'resolved' => 'info', 'closed' => 'secondary' ][$ticket->status] ?? 'secondary'; @endphp {{ ucfirst(str_replace('_', ' ', $ticket->status)) }} @php $priorityClass = [ 'low' => 'success', 'medium' => 'warning', 'high' => 'danger' ][$ticket->priority] ?? 'secondary'; @endphp {{ ucfirst($ticket->priority) }} Priority
Category: {{ ucfirst($ticket->category) }}
Created: {{ $ticket->created_at->format('M j, Y H:i') }}
Last Updated: {{ $ticket->updated_at->format('M j, Y H:i') }}
Assigned To: @if($ticket->assignedTo) {{ $ticket->assignedTo->name }} @else Not assigned yet @endif
Conversation
{{ strtoupper(substr($ticket->user->name, 0, 1)) }}
{{ $ticket->user->name }}
{{ $ticket->created_at->format('M j, Y H:i') }}
Original Message
{!! nl2br(e($ticket->description)) !!} @if($ticket->attachments->count() > 0)
Attachments:
@foreach($ticket->attachments as $attachment) {{ $attachment->original_name }} @endforeach
@endif
@foreach($ticket->replies as $reply)
{{ strtoupper(substr($reply->user->name, 0, 1)) }}
{{ $reply->user->name }} @if($reply->is_admin_reply) Support Team @endif
{{ $reply->created_at->format('M j, Y H:i') }}
{!! nl2br(e($reply->message)) !!} @if($reply->attachments->count() > 0)
Attachments:
@foreach($reply->attachments as $attachment) {{ $attachment->original_name }} @endforeach
@endif
@endforeach @if($ticket->replies->count() === 0)

No replies yet. Our support team will respond soon.

@endif
@if($ticket->status !== 'closed')
Add Reply
@csrf
@error('message')
{{ $message }}
@enderror
@error('attachments')
{{ $message }}
@enderror Maximum file size: 5MB each. Supported formats: JPG, PNG, GIF, PDF, DOC, DOCX
@if($ticket->status === 'resolved') @endif
@else
This ticket is closed. You cannot reply to closed tickets.
@endif
Ticket Actions
@if($ticket->status === 'open' || $ticket->status === 'in_progress') @endif @if($ticket->status !== 'closed') @endif Create New Ticket
Ticket Information
Ticket ID:
#{{ $ticket->id }}
Category:
{{ ucfirst($ticket->category) }}
Priority:
@php $priorityClass = [ 'low' => 'success', 'medium' => 'warning', 'high' => 'danger' ][$ticket->priority] ?? 'secondary'; @endphp {{ ucfirst($ticket->priority) }}
Status:
@php $statusClass = [ 'open' => 'success', 'in_progress' => 'primary', 'resolved' => 'info', 'closed' => 'secondary' ][$ticket->status] ?? 'secondary'; @endphp {{ ucfirst(str_replace('_', ' ', $ticket->status)) }}
Created:
{{ $ticket->created_at->format('M j, Y H:i') }}
Last Update:
{{ $ticket->updated_at->format('M j, Y H:i') }}
Support Information

Need immediate assistance?

Phone: {{ $supportPhone }}
Email: {{ $supportEmail }}
Hours: 9 AM - 6 PM (BST)
@endsection @push('scripts') @endpush @push('styles') @endpush