@extends('layouts.app') @section('title', 'Ticket #' . $ticket->id . ' - TicketHub Central') @section('content')

{{ $currentSite->name }}

{{ $currentSite->code }}

{{ $currentSite->is_active ? 'Connected' : 'Offline' }}

Ticket #{{ $ticket->id }}

@if($ticket->support_closed) Closed by Support @elseif($ticket->closed) Closed @else Open @endif Created {{ $ticket->created?->format('M d, Y \a\t H:i') }}
@if($ticket->support_closed && $ticket->closed)
@csrf @method('PATCH')
@else
@csrf @method('PATCH')
@endif

Ticket Description

{!! $ticket->content ?? '

No description provided.

' !!}
@php $ticketOnlyFiles = $ticket->files->whereNull('comment_id'); @endphp @if($ticketOnlyFiles->isNotEmpty())

Ticket Attachments ({{ $ticketOnlyFiles->count() }})

@foreach($ticketOnlyFiles as $file) @include('partials.file-thumbnail', ['file' => $file]) @endforeach
@endif

Comments ({{ $ticket->comments->count() }})

@if($ticket->comments->isEmpty())

No comments yet

@else
@foreach($ticket->comments as $comment)

{{ $comment->support_reply ? ($comment->support_by ?? 'Support Agent') : 'Customer' }}

@if($comment->support_reply) Support @endif
@if($comment->support_reply && ($comment->support_by == Auth::user()->name)) @if(!$comment->support_by == Auth::user()->name) @endif @endif {{ $comment->created?->format('M d, Y H:i') }} @if($comment->updated && $comment->updated != $comment->created) (edited) @endif
{!! $comment->content !!}
@php $commentFiles = $ticket->files->where('comment_id', $comment->id); @endphp @if($commentFiles->isNotEmpty())

Attachments:

@foreach($commentFiles as $file) @include('partials.file-thumbnail-small', ['file' => $file]) @endforeach
@endif
@endforeach
@endif
@csrf
@error('content')

{{ $message }}

@enderror

You can also paste or drag images directly into the editor above.

User Information

@if($ticket->user)

{{ $ticket->user->name }}

{{ $ticket->user->username }}


Type {{ $ticket->user->type }}
Status {{ $ticket->user->status === 'A' ? 'Active' : 'Suspended' }}
@else

User information not available

@endif

Ticket Details

Category {{ $ticket->category ?? '—' }}
Priority {{ $ticket->type ?? '—' }}
MAC Address {{ $ticket->mac ?? '—' }}

Box {{ $ticket->box ?? '—' }}
Box IP {{ $ticket->box_ip ?? '—' }}
ISP {{ $ticket->box_isp ?? '—' }}
@if($ticket->vod_category)
VOD Category {{ $ticket->vod_category }}
@endif
Read Status @if($ticket->read) Read @else Unread @endif
Last Updated {{ $ticket->updated?->format('M d, Y H:i') }}

All Files ({{ $ticket->files->count() }})

@if($ticket->files->isEmpty())

No attachments

@else
@foreach($ticket->files as $file) @php $fileUrl = \App\Helpers\FileHelper::getFileUrl($site, $file->file); @endphp

{{ basename($file->file) }}

{{ $file->created?->format('M d, Y') }}

@endforeach
@endif
@endsection