| {{ __('Code') }} | {{ __('Machine') }} | {{ __('Product / Slot') }} | {{ __('Expiry') }} | {{ __('Status') }} | {{ __('Actions') }} |
|---|---|---|---|---|---|
| @if($code->status === 'active' && $code->expires_at->isFuture()) code }}'; activeTicketUrl = '{{ $code->ticket_url }}'; showQrModal = true" class="text-lg font-black font-mono text-cyan-600 dark:text-cyan-400 tracking-widest bg-cyan-50 dark:bg-cyan-500/10 px-4 py-1.5 rounded-xl border border-cyan-100 dark:border-cyan-500/20 shadow-sm cursor-pointer hover:bg-cyan-100 dark:hover:bg-cyan-500/20 transition-all"> {{ $code->code }} @else {{ $code->code }} @endif |
{{ $code->machine?->name ?? '-' }}
{{
$code->machine?->serial_no }}
|
@php
$slot = $code->machine?->slots->where('slot_no', $code->slot_no)->first();
$productName = $slot ? ($slot->product?->name ?? __('Empty')) : __('Empty');
@endphp
{{
$productName
}}
{{
__('Slot')
}}: {{ $code->slot_no }}
|
{{ $code->expires_at->format('Y-m-d H:i') }}
{{ $code->expires_at->diffForHumans() }}
|
@php
$displayStatus = $code->status === 'active' && $code->expires_at->isPast() ?
'expired' :
$code->status;
@endphp
|
@if($code->status === 'active' && $code->expires_at->isFuture())
@endif
@if($code->status === 'active' && $code->expires_at->isFuture())
{{-- View QR Code Button --}}
@endif
@if($code->status === 'active' && $code->expires_at->isFuture())
@endif
|
{{ $code->machine?->name ?? '-' }}
{{ __('Slot') }}
{{ $code->slot_no }} @php $slotMobile = $code->machine?->slots->where('slot_no', $code->slot_no)->first(); $prodMobile = $slotMobile ? ($slotMobile->product?->name ?? __('Empty')) : __('Empty'); @endphp ({{ $prodMobile }})
{{ __('Expiry') }}
{{ $code->expires_at->format('m-d H:i') }} {{ $code->expires_at->diffForHumans() }}