@props(['state' => 'pending']) @php $pendingStates = [ \App\Models\Billing\Invoice::STATUS_PENDING, \App\Models\Helpdesk\SupportTicket::STATUS_OPEN, \App\Models\Helpdesk\SupportTicket::STATUS_ANSWERED, \App\Models\Billing\Invoice::STATUS_DRAFT, \App\Models\Provisioning\Service::STATUS_PENDING, 'unreferenced', ]; $successStates = [ \App\Models\Billing\Invoice::STATUS_PAID, \App\Models\Provisioning\Service::STATUS_ACTIVE, 'approved', 'completed', 'yes', ]; $failedStates = [ \App\Models\Billing\Invoice::STATUS_FAILED, \App\Models\Provisioning\Service::STATUS_EXPIRED, 'rejected', 'no' ]; $neutralStates = [ \App\Models\Billing\Invoice::STATUS_REFUNDED, \App\Models\Helpdesk\SupportTicket::STATUS_CLOSED, \App\Models\Provisioning\Service::STATUS_SUSPENDED, \App\Models\Provisioning\Service::STATUS_CANCELLED, 'hidden', 'disabled', ]; @endphp @if (in_array($state, $pendingStates)) {{ __('global.states.'. $state) }} @endif @if (in_array($state, $successStates)) {{ __('global.states.'. $state) }} @endif @if (in_array($state, $failedStates)) {{ __('global.states.'. $state) }} @endif @if (in_array($state, $neutralStates)) {{ __('global.states.'. $state) }} @endif @if ($state == 'low') {{ __('helpdesk.priorities.'. $state) }} @endif @if ($state == 'medium') {{ __('helpdesk.priorities.'. $state) }} @endif @if ($state == 'high') {{ __('helpdesk.priorities.'. $state) }} @endif