@extends('layouts.dashboard') @section('title', trans('dashboard.title') . ' | ' . config('app.name', 'EMZatca')) @section('header_title', trans('dashboard.title')) @section('content')

{{ trans('dashboard.overview') }} {{ $tenant->is_sandbox ? trans('dashboard.env_sandbox_name') : trans('dashboard.env_production_name') }}

{{ trans('dashboard.dashboard_day_view') }}

{{ trans('dashboard.quick_tour') }}
@if(!$hasReadyDevice)

{{ trans('dashboard.onboarding_alert_title') }}

{{ trans('dashboard.onboarding_alert_desc') }}

{{ trans('dashboard.complete_onboarding_btn') }}
@endif
{{ trans('dashboard.invoices_this_month') }} ({{ trans('dashboard.total_invoices') }}: {{ number_format($totalInvoicesCount) }})
{{ number_format($monthInvoicesCount) }}
{{ trans('dashboard.first_month_for_you') }}
{{ trans('dashboard.total_sales_label') }}
{{ number_format($monthSalesTotal, 2) }}
{{ trans('dashboard.cleared_invoices') }}: {{ number_format($clearedCount) }}
{{ trans('dashboard.acceptance_rate_label') }}
{{ $acceptanceRate }}%
{{ trans('dashboard.accepted_of_total', ['accepted' => $clearedCount + $reportedCount, 'total' => max(0, $totalInvoicesCount)]) }}
{{ trans('dashboard.drafts_waiting') }}
{{ $draftsCount }}
{{ trans('dashboard.complete_and_issue') }}

{{ trans('dashboard.connection_status_title') }}

{{ trans('dashboard.fatoora_platform') }} @if($hasReadyDevice) {{ trans('dashboard.status_connected') }} @else {{ trans('dashboard.status_not_connected') }} @endif
{{ trans('dashboard.csid_certificate') }} {{ $readyDevice?->certificate_expires_at ? $readyDevice->certificate_expires_at->format('Y/m/d') : '2029/01/09' }}
{{ trans('dashboard.zatca_env') }} {{ $tenant->is_sandbox ? trans('dashboard.env_sandbox_name') : trans('dashboard.env_production_name') }}
@if($tenant->is_sandbox) @endif

{{ trans('dashboard.issued_invoices_12_weeks') }}

{{ trans('dashboard.legend_accepted') }}
{{ trans('dashboard.legend_current_week') }}

{{ trans('dashboard.recent_invoices') }}

{{ trans('dashboard.view_all_invoices') }}
@forelse($recentInvoices as $inv) @empty @endforelse
{{ trans('dashboard.invoice_number') }} {{ trans('dashboard.client') }} {{ trans('dashboard.total_amount') }} {{ trans('dashboard.status_in_zatca') }} {{ trans('dashboard.action') }}
{{ $inv->invoice_number }} {{ $inv->buyer_name }} {{ number_format($inv->total, 2) }} @if($inv->status->value === 'cleared') {{ trans('dashboard.cleared_badge') }} @elseif($inv->status->value === 'reported') {{ trans('dashboard.reported_badge') }} @else {{ $inv->status->label() }} @endif {{ trans('dashboard.details_link') }}
{{ trans('dashboard.no_invoices_yet') }}
@endsection