@use('App\Services\Date') @extends('reports::layouts.master_pdf') @php $subdomain = request()->route()->parameter('subdomain'); $is_student = app(\Hyn\Tenancy\Repositories\HostnameRepository::class)->findByHostname($subdomain)->website->company->is_student; @endphp @section('koolreport') @isset($data['accounts'])
@if($is_student) @include('draft_report') @endif

@lang('reports::reports.Cash Flow Direct')

{{ $data['companyName'] }}

{{$data['dates']['from']}} @lang('to') {{$data['dates']['to']}}

@foreach($data['cash_flow_direct'] as $cashFlowData) @if($cashFlowData['subsections']) @foreach($cashFlowData['subsections'] as $section) @if($section['accounts']) @foreach($section['accounts'] as $account) @php if(isset($account['tree'])){ $tree=$account['tree']['directChildren']; } $displayNegative = true; @endphp @isset($account['tree']) {!! generateHTMLForBalanceSheet($tree,1, $displayNegative) !!} @endisset @if($account['current_balance'] != $account['total']) @endif @endforeach @else @endif @endforeach @endif @if($cashFlowData['accounts']) @foreach($cashFlowData['accounts'] as $account) @php if(isset($account['tree'])){ $tree=$account['tree']['directChildren']; } $displayNegative = true; @endphp @isset($account['tree']) {!! generateHTMLForBalanceSheet($tree,1, $displayNegative) !!} @endisset @if($account['current_balance']!=$account['total']) @endif @endforeach @endif @endforeach
@lang('reports::reports.total')
{{$cashFlowData['name']}}
{{$section['name']}}
@lang('reports::reports.total') {{$account['name']}} @if($account['total'] < 0) ({{number_format(abs($account['total']),2)}}) @else {{number_format($account['total'],2)}} @endif
{{$section['total_label']}} {{number_format($section['total'], 2)}}
{{$section['name']}} {{number_format($section['total'], 2)}}
{{$cashFlowData['total_label']}} {{number_format($cashFlowData['total'], 2)}}
@lang('reports::reports.total') {{$account['name']}} @if($account['total'] < 0) ({{number_format(abs($account['total']),2)}}) @else {{number_format($account['total'],2)}} @endif
{{$cashFlowData['total_label']}} {{number_format($cashFlowData['total'], 2)}}
{{__('reports::reports.cash_flow_direct.net_change_in_cash')}} {{number_format($data['net_change_in_cash'], 2)}}
{{__('reports::reports.cash_flow_direct.total_cash_equivalents')}} {{number_format($data['total_cash_equivalents'], 2)}}
{{__('reports::reports.cash_flow_direct.available_cash_duration')}} {{number_format($data['available_cash_duration'], 2)}}
@lang('reports::reports.accrual_basis') {{ Date::format(now(), 'datetime') }}
@endisset @endsection