@if (!empty($search))

{{ __('Đang tìm kiếm:') }} "{{ $search }}"

@endif
@forelse($services->all() as $invoice) @if ($status === 'full' || $invoice->status == $status) @php $invoiceItem = $invoice->invoiceItem->first(); $product = $invoiceItem ? $invoiceItem->product : null; // Get service module info for IP $moduleService = $invoiceItem ? $invoiceItem->GetRelidProduct() : null; $ipAddress = ''; if ($moduleService) { if ($invoiceItem->product_type == 4 && isset($moduleService->ipAddress)) { $ipAddress = $moduleService->ipAddress->ip ?? ''; } } @endphp @endif @empty @endforelse
{{ __('Tên sản phẩm') }} IP {{ __('Giá tiền') }} Specs {{ __('Ngày hết hạn') }} {{ __('Trạng thái') }} {{ __('Gia hạn tự động') }} {{ __('Thao tác') }}
{{ $product ? $product->name : 'N/A' }}
{{ $ipAddress ?: 'N/A' }} {{ number_format($invoice->total ?? 0, 0, ',', '.') }} đ
@if ($product)
CPU: {{ $product->cpu ?? 'N/A' }} Core
RAM: {{ $product->ram ? $product->ram . ' MB' : 'N/A' }}
Disk: {{ $product->disk ? $product->disk . ' GB' : 'N/A' }}
@else
{{ __('Không có thông tin') }}
@endif
OS: {{ $invoiceItem && $invoiceItem->os ? $invoiceItem->os->osGroup->name . ' ' . $invoiceItem->os->version : 'N/A' }}
{{ __('Hết hạn') }} @if ($invoice->due_date) @php $dueDate = \Illuminate\Support\Carbon::parse($invoice->due_date); $isExpiringSoon = $dueDate->diffInDays(now()) <= 7 && $dueDate->isFuture(); @endphp {{ $dueDate->format('d/m/Y') }} @else N/A @endif
{{ __('Đã thanh toán') }} @if ($invoice->date_paid) @php $paidDate = \Illuminate\Support\Carbon::parse($invoice->date_paid); @endphp {{ $paidDate->format('d/m/Y') }} @else {{ __('Chưa thanh toán') }} @endif
{!! $invoice->getStatus() !!} {{ __('Xem chi tiết') }}

{{ __('emptyValue') }}

{{ __('Chưa có dịch vụ nào được tạo') }}

{{ $services->links() }}