@extends('layouts.app') @section('title','Profit & Loss') @section('page_title','Profit & Loss Statement') @section('content')

Profit & Loss

{{ $from }} to {{ $to }}

@include('reports.partials.date-filter')
Revenue
AED {{ number_format($income,2) }}
Cost of Revenue
AED {{ number_format($cost,2) }}
Gross Profit
AED {{ number_format($gross,2) }}
Net Profit
AED {{ number_format($net,2) }}
@foreach(['income'=>'Revenue','cost_of_revenue'=>'Cost of Revenue','expense'=>'Operating Expenses'] as $type=>$label)@foreach($rows->get($type,collect()) as $a)@if(abs($a->amount)>0.0001)@endif @endforeach @endforeach
SectionCodeAccountAmount
{{ $label }}{{ $a->code }}{{ $a->name }}{{ number_format($a->amount,2) }}
@endsection