@extends('backend.layouts.app') @push('style') @endpush @section('content')
@if (session('success'))
{{ session('success') }}
@endif
{{ $ticket->subject }}

Ticket ID: {{ $ticket->ticket_number }} | Created: {{ $ticket->created_at->format('d M Y, h:i A') }} | Status: {{ ucfirst($ticket->status) }}


{{ $ticket->details }}

{{-- conversation messages --}}
@forelse($ticket->replies as $reply)
@if (!$reply->is_admin)
User Avatar
@endif
{{-- delete cross --}} {{ $reply->reply_text }} @if ($reply->attachment) @endif {{ $reply->created_at->format('d M Y, h:i A') }}
@if ($reply->is_admin)
Admin Avatar
@endif
@empty

No messages yet.

@endforelse
{{-- reply form --}} @if ($ticket->status == 'open')
@csrf
{{-- paperclip icon as file input --}}
{{-- chat-style input --}} {{-- send button --}}
@error('message')
{{ $message }}
@enderror @error('attachment')
{{ $message }}
@enderror
@else
This ticket is closed. You cannot reply further.
@endif
{{-- sidebar --}}
Tickets
@foreach ($tickets as $t)
#{{ $t->ticket_number }}
status === 'open' ? 'checked' : '' }}>
@endforeach
@endsection @push('script') @endpush