@use('App\Services\Date') @extends('reports::layouts.master') @section('title', __('reports::reports.General Ledger')) @section('page-link') @endsection @section('action_buttons')
@if(LaravelLocalization::getCurrentLocale() === 'en') @else @endif @if(request()->all()) @can('reports.general-ledger.export') @endcan @endif
@endsection @section('section_title') @lang('reports::reports.General Ledger') @endsection @section('form-open-tag')
@lang('Filter')
@error('fiscal_year_id') @enderror @error('from') @enderror @error('to') @enderror
@endsection @section('koolreport') @if(request()->all())

@lang('reports::reports.General Ledger')

{{ $data['companyName'] }}

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

@foreach ($data['accounts'] as $account) @if($account && count($account['transactions'])) @foreach($account['transactions'] as $transaction) @endforeach @endif @endforeach
@lang('reports::reports.account') @lang('reports::reports.general_ledger.transactions_type') @lang('reports::reports.journal_number') @lang('reports::reports.reference_name') @lang('reports::reports.description') @lang('reports::reports.general_ledger.amount') @lang('reports::reports.general_ledger.balance')
{{ $account['code'] }} - {{ $account['name'] }}
@lang('reports::reports.opening_balance') @if($account['openingBalance']<0) ({{ number_format(abs($account['openingBalance']),2) }}) @else {{ number_format($account['openingBalance'],2) }} @endif
{{ Date::format($transaction['date'], 'date') }} {{ $transaction['transaction_type'] }} @if(isset($transaction['journal_id'])) {{ $transaction['journal_number'] }} @endif {{ $transaction['reference_person'] }} {{ $transaction['journal_description'] }} @if($transaction['value']<0) ({{ number_format(abs($transaction['value']),2) }}) @else {{ number_format($transaction['value'],2) }} @endif @if($transaction['balance_after_transaction']<0) ({{ number_format(abs($transaction['balance_after_transaction']),2) }}) @else {{ number_format($transaction['balance_after_transaction'],2) }} @endif
@lang('reports::reports.total') {{ $account['name'] }} @if($account['total']<0) ({{ number_format(abs($account['total']),2) }}) @else {{ number_format($account['total'],2) }} @endif
@endif @endsection @section('filter-by-dates') @endsection @section('extra_scripts_filter_by_date') @endsection