@php
// تحديد عدد الفواتير المطلوبة
$numDates = count($bills_collection);
// استدعاء الدالة مع تحديد عدد التواريخ المطلوبة
$orderedDates = generateRandomDate($from_date, $to_date, $numDates);
@endphp
@php
$total_order_items = 0;
$total_order = 0;
$vat_order = 0;
@endphp
@foreach ($bills as $productIndex => $bill)
@php
$product_with_quantity = $bill['product']->price * $bill['quantity'];
$vat_amount = ((double) setting('vat_percentage') * $product_with_quantity) / 100;
$total_order_items += $product_with_quantity;
$vat_order += $vat_amount;
$total_order += ($vat_amount + $product_with_quantity);
@endphp
@endforeach
| # |
{{ trans('dashboard.product.name') }} |
{{ trans('dashboard.product.price') }} |
{{ trans('dashboard.product.quantity') }} |
{{ trans('dashboard.bill.total_products_amount') }} |
{{ trans('dashboard.bill.vat_amount') }} |
{{ trans('dashboard.bill.total_amount') }} |
@php
$total_order_items = 0;
$total_order = 0;
$vat_order = 0;
@endphp
@foreach ($bills as $productIndex => $bill)
@php
$product_with_quantity = $bill['product']->price * $bill['quantity'];
$vat_amount = ((double) setting('vat_percentage') * $product_with_quantity) / 100;
$total_order_items += $product_with_quantity;
$vat_order += $vat_amount;
$total_order += ($vat_amount + $product_with_quantity);
@endphp
| {{ $loop->iteration }} |
{{ $bill['product']->name }} |
{{ number_format($bill['product']->price, 2) }} |
{{ $bill['quantity'] }} |
{{ number_format($product_with_quantity, 2) }} |
{{ number_format($vat_amount, 2) }} |
{{ number_format($vat_amount + $product_with_quantity, 2) }} |
@endforeach
| الإجمالي |
{{ number_format($total_order_items, 2) }} |
{{ number_format($vat_order, 2) }} |
{{ number_format($total_order, 2) }} |