@extends('admin.layouts.master') @section('css') @endsection @section('contents')
@if(auth()->user()->can('create_supports') )
@endif
@include('admin.supports.search_form')
@forelse($supports as $support) @php $typeLabel = $support->type ? (function($v){ return is_array($v) ? implode(', ',$v) : (string)$v; })(getTrans($support->type->display_name, lang())) : '-'; $priorityClass = match(strtolower($support->priority ?? '')) { 'high' => 'badge-danger', 'medium' => 'badge-warning', default => 'badge-info', }; $statusClass = match($support->status) { 'open' => 'badge-success', 'closed' => 'badge-danger', default => 'badge-secondary', }; $statusLabel = match($support->status) { 'open' => __('Open'), 'closed' => __('Closed'), default => __('Pending'), }; @endphp @empty @endforelse
# {{ __('Title') }} {{ __('Owner') }} {{ __('Type') }} {{ __('Priority') }} {{ __('Status') }} {{ __('Messages') }} {{ __('Created') }} {{ __('Actions') }}
{{ $support->id }} {{ \Illuminate\Support\Str::limit($support->title, 45) }} @if($support->body)
{{ \Illuminate\Support\Str::limit($support->body, 55) }} @endif
@if($support->supportable) @else - @endif {{ $typeLabel }} {{ $support->priority ?? '-' }} {{ $statusLabel }} {{ $support->threads_count }} {{ custom_date($support->created_at) }} @if($support->createdByUser)
{{ __('by') }} {{ $support->createdByUser->name }} @endif
@can('delete_supports') @endcan
{{ __('No support tickets found.') }}
@include('admin.components.advanced-pagination', ['paginator' => $supports])
@endsection @section('scripts') @endsection