@extends($activeTemplate . 'layouts.master') @section('panel')
@lang('Invoice Number') | @lang('Total Items') @lang('Sale Date') | @lang('Created At') @lang('Customer') @lang('Total Amount') | @lang('Purchase Value') @lang('Profit/Loss Amount') @forelse($sales as $sale) @php $totalSaleAmount = $sale->total; $purchaseAmount = $sale->total_purchase_value; $profitLossAmount = $totalSaleAmount - $purchaseAmount; @endphp
{{ __($sale->invoice_number) }} {{ __($sale->sale_details_count) }} @lang('Items')
{{ showDateTime($sale->sale_date, 'Y-m-d') }} {{ showDateTime($sale->created_at) }}
{{ __(@$sale->customer->name) }} {{ __(@$sale->customer->name) }}
{{ showAmount($totalSaleAmount) }} {{ showAmount($purchaseAmount) }}
{{ showAmount($totalSaleAmount - $purchaseAmount) }} @empty @endforelse
@if ($sales->hasPages()) {{ paginateLinks($sales) }} @endif
@endsection