@extends('organizer.layout') @section('content')
{{ __('Ticket Details') }} - #{{ $ticket->id }}

{{ $ticket->subject }}

@if ($ticket->status == 1) {{ __('Pending') }} @elseif($ticket->status == 2) {{ __('Open') }} @else {{ __('Closed') }} @endif {{ $ticket->created_at->format('d-m-Y') }} {{ date('h.i A', strtotime($ticket->created_at)) }}

{{ $ticket->description }}

@if ($ticket->attachment) {{ __('Download Attachment') }} @endif
{{ __('Replies') }}
@if (count($ticket->messages) > 0) @foreach ($ticket->messages as $reply) @if ($reply->type == 2) @php $admin = App\Models\Admin::where('id', $reply->user_id)->first(); @endphp
...
{{ $admin->username }}
{{ $admin->id == 1 ? __('Super Admin') : $admin->role->name }}

{!! $reply->reply !!}

@if ($reply->file) {{ __('Download') }} @endif
@else @if ($reply->type == 3) @php $organizer = App\Models\Organizer::where('id', $reply->user_id)->first(); @endphp
@if ($organizer->photo) user-photo @else user-photo @endif
{{ $organizer->username }}
{{ __('Organizer') }}

{!! $reply->reply !!}

@if ($reply->file) {{ __('Download') }} @endif
@endif @endif @endforeach @endif
@if ($ticket->status == 2)
{{ __('Reply to Ticket') }}
@csrf

{{ __('Upload only ZIP Files, Max File Size is 5 MB') }}

@endif
@endsection @section('script') @endsection