| {{ __('home.Invoice_no') }} | {{ __('home.clietName') }} | {{ __('home.date') }} | {{ __('home.branch') }} | {{ __('home.total') }} | {{ __('home.operations') }} |
|---|---|---|---|---|---|
| {{ $product->id }} | {{ $product->customer->name }} | {{ $product->created_at->format('Y-m-d') }} | {{ $product->branch->name }} | @php // حساب الإجماليات والخصومات // الحساب الموحد (نفس الشاشة والطباعة و PDF) $items = App\Models\offer_price_to_customer_items::where('order_id', $product->id)->get(); $totalWithTax = \App\Support\QuotationTotals::calculate($items, $product->discount ?? 0, $avtRate)['grand_total']; @endphp{{ number_format($totalWithTax, 2) }} |