@extends('accounting::layouts.app') @section('title') @yield('tab-title') @endsection @section('content') @include('accounting::layouts.nav') {{-- Content Header (Page header) --}} @yield('tab-title') {{-- Main content --}} {{-- --}} {{-- --}} @php $nav_items = [ 'accounting/transactions/sales?type=payment' => trans_choice('accounting::general.sales', 2), 'accounting/transactions/expenses' => trans_choice('accounting::general.expense', 2), 'accounting/transactions/purchases?type=purchase_order' => trans_choice('accounting::general.purchase', 2), ]; function isActiveTab($url) { $first_two_segments = request()->segment(1) . '/' . request()->segment(2) . '/' . request()->segment(3); return $first_two_segments == getUrlWithoutParams($url); } @endphp {{-- Loop through the nav items to print the side nav --}} @foreach ($nav_items as $url => $label) {{ $label }} @endforeach @yield('tab-content') {{-- --}} @yield('modal-content') {{-- /.content --}} @stop @section('javascript') @yield('tab-javascript') @endsection