@php
$columns = [
['label' => 'Sl No', 'column' => 'id', 'sort' => true],
['label' => 'Name', 'column' => 'name', 'sort' => true],
['label' => 'Email', 'column' => 'email', 'sort' => true],
['label' => 'Order Date', 'column' => 'order_date', 'sort' => true],
['label' => 'Sub Total', 'column' => 'sub_total', 'sort' => true],
['label' => 'Tax Total', 'column' => 'tax_total', 'sort' => true],
['label' => 'Grand Total', 'column' => 'grand_total', 'sort' => true],
['label' => 'Status', 'column' => 'status', 'sort' => true],
];
@endphp
@foreach ($columns as $column)
|
{{ $column['label'] }} |
@endforeach
@foreach ($orders as $key => $item)
| {{ $key + 1 }} |
{{ $item->name }} |
{{ $item->email }} |
{{ $item->order_date }} |
{{ $item->sub_total }} |
{{ $item->tax_total }} |
{{ $item->grand_total }} |
{{ $item->status }}
|
@endforeach