@extends('layouts.app')
@section('title', __('medaccounting::lang.reports'))
@section('content')
<section class="content-header"><h1>@lang('medaccounting::lang.reports')</h1>
    <p>@lang('medaccounting::lang.reports_help')</p>
</section>
<section class="content">
    <div class="row">
        @php
            $cards = [
                ['route' => 'medacc.reports.trial_balance',    'label' => 'trial_balance',    'icon' => 'fa-balance-scale'],
                ['route' => 'medacc.reports.general_ledger',   'label' => 'general_ledger',   'icon' => 'fa-book'],
                ['route' => 'medacc.reports.income_statement', 'label' => 'income_statement', 'icon' => 'fa-line-chart'],
                ['route' => 'medacc.reports.balance_sheet',    'label' => 'balance_sheet',    'icon' => 'fa-columns'],
                ['route' => 'medacc.reports.departmental',     'label' => 'departmental_pl',  'icon' => 'fa-sitemap'],
            ];
        @endphp
        @foreach($cards as $c)
        <div class="col-md-4">
            @component('components.widget', ['class' => 'box-primary', 'title' => __('medaccounting::lang.' . $c['label'])])
                <p><i class="fa {{ $c['icon'] }} fa-2x text-muted"></i></p>
                <a href="{{ route($c['route'], ['from' => $from, 'to' => $to]) }}" class="btn btn-default btn-sm">
                    <i class="fa fa-arrow-right"></i> @lang('medaccounting::lang.open_report')
                </a>
            @endcomponent
        </div>
        @endforeach
    </div>
</section>
@endsection
