@extends('layouts.template') @section('template')

CUSTOMER SALES REPORT

{!! csrf_field() !!}

@if(isset($all_sales))
List Sales
@if(isset($all_sales)) @php $qty = 0; $total =0 ; $temp_date = ''; @endphp @foreach($all_sales as $key => $single_sales) @php $qty += $single_sales->quantity; $total += $single_sales->sales_price * $single_sales->quantity; @endphp @endforeach @endif
Sl No. Date Item Qty Price Total Invoice No.
{{ ++$key }} @if($temp_date != date('d M, Y',strtotime($single_sales->sales_date))) {{ date('d M, Y',strtotime($single_sales->sales_date)) }} @endif @php $temp_date = date('d M, Y',strtotime($single_sales->sales_date)); @endphp {{ $single_sales->item_name }} {{ $single_sales->quantity }} {{ $single_sales->sales_price }} {{ $net = ($single_sales->sales_price * $single_sales->quantity) + ($single_sales->item_vat/100) * ($single_sales->sales_price * $single_sales->quantity) }} {{ $single_sales->memo_no }}

Total Quantity: {{ $qty }}

Total Amount: {{ number_format($total,2) }}

@endif
@endsection