@if (isset($data) && $data->count() > 0) @php $i = 1; @endphp
| {{ __('home.Invoice_no') }} | {{ __('home.sallerName') }} | {{ __('home.clietName') }} | {{ __('home.date') }} | {{ __('home.branch') }} | {{ __('home.total') }} | {{ __('home.paymentmethod') }} | {{ __('home.operations') }} |
|---|---|---|---|---|---|---|---|
| {{ $product->id }} | {{ $product->user->name ?? '' }} | {{ $product->customer->name ?? '' }} | {{ $product->created_at }} | {{ $product->branch->name ?? '' }} | {{ number_format($product->creaditamount + $product->bankamount + $product->Bank_transfer + $product->cashamount, 2) }} | @php // تحديد طريقة الدفع $pay = match($product->Pay) { 'Cash' => __('report.cash'), 'Shabka' => __('report.shabka'), 'Credit' => __('report.credit'), 'Bank_transfer' => __('home.Bank_transfer'), default => __('home.Partition of the amount'), }; // إعداد بيانات الواتساب $phone = "966" . substr($product->customer->phone ?? 0, 1); $link = "https://demoo.ebdeaclients.online/ar/generate_pdf/" . $product->id; $message = "يسرنا خدمتك مرفق لكم فاتورتكم " . "فضلا لتحميل فاتورتك رقم : {$product->id}: {$link}\n" . "For download your invoice number :{$product->id } press here : {$link}"; $waLink = "https://web.whatsapp.com/send?phone={$phone}&text=" . urlencode($message); @endphp{{ $pay }} |