# |
{{-- Date | --}}
Account Code |
Description |
Amount |
|
@php
$salesTotal= 0;
$costofsalesTotal=0;
$grossprofit = 0;
$expenceTotal= 0;
$otherIncomeTotal= 0;
$profit = 0;
$count = 1;
@endphp
Sales |
@foreach ($sales as $value)
{{ $count++ }} |
{{ $value->acc_code }} |
{{ $value->acc_name }} |
{{ number_format($value->credit-$value->debit, 2, '.', ',') }} |
|
@php
$salesTotal+=$value->credit-$value->debit;
@endphp
@endforeach
Total Sales : | {{ number_format($salesTotal, 2, '.', ',') }} | |
Cost of Sales |
@foreach ($costofsales as $value)
{{ $count++ }} |
{{ $value->acc_code }} |
{{ $value->acc_name }} |
{{ number_format($value->debit-$value->credit, 2, '.', ',') }} |
|
@php
$costofsalesTotal+=$value->debit-$value->credit;
@endphp
@endforeach
Total Cost of Sales : | {{ number_format($costofsalesTotal, 2, '.', ',') }} | |
@php
$grossprofit=($salesTotal)-($costofsalesTotal)
@endphp
Gross Profit : |
{{ number_format($grossprofit, 2, '.', ',') }} | |
Expences |
@foreach ($expences as $value)
{{ $count++ }} |
{{ $value->acc_code }} |
{{ $value->acc_name }} |
{{ number_format($value->debit-$value->credit, 2, '.', ',') }} |
|
@php
$expenceTotal+=$value->debit-$value->credit;
@endphp
@endforeach
Total Expences : | {{ number_format($expenceTotal, 2, '.', ',') }} | |
Other Income |
@foreach ($otherIncome as $value)
{{ $count++ }} |
{{ $value->acc_code }} |
{{ $value->acc_name }} |
{{ number_format($value->credit-$value->debit, 2, '.', ',') }} |
|
@php
$otherIncomeTotal+=$value->credit-$value->debit;
@endphp
@endforeach
Total Other Income : | {{ number_format($otherIncomeTotal, 2, '.', ',') }} | |
@php
$profit=($otherIncomeTotal+$grossprofit)-($expenceTotal)
@endphp
Net Profit : |
{{ number_format($profit, 2, '.', ',') }} | |