@extends('layouts/acc_layout') @if ($operation == 'view') @section('title', '| View Budget') @else @section('title', '| Edit Budget') @endif @section('content')
| Transaction Heads | Monthly Budget | Total | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| {{ $month }} | @endforeach|||||||||||||
| $ledger->name[$ledger->code] | "; $childParentConfigs = []; $totalValue = 0; foreach ($GLOBALS['months'] as $key => $month) { $monthWithoutComa = str_replace(', ', '', $month); foreach ($childrens as $key => $child) { $parentConfigs = $GLOBALS['budgetConfig']->where('child', $child->child)->where('childNature', $child->childNature); $childParentConfigs[$key] = $parentConfigs; $childrens[$key]->month = $monthWithoutComa; } $style = 'style="width:80px;text-align: right;'; $readonly = 'readonly'; $function = ''; if ($ledger->isGroupHead) { $style .= 'background-color: #cbd5d6;"'; } elseif (in_array($ledger->id, $GLOBALS['childLedgerIds']) && $configAsChild != null && $configAsChild->childNature == $nature) { $style .= 'background-color: #bab5b5;"'; } else { $style .= '"'; $readonly = $GLOBALS['operation'] == 'view' ? 'readonly' : ''; if ($GLOBALS['operation'] == 'edit') { $function = "onInput='changeChildren(" . htmlspecialchars(json_encode($childrens, true), ENT_QUOTES, 'UTF-8') . ', this, ' . htmlspecialchars(json_encode($monthWithoutComa), ENT_QUOTES, 'UTF-8') . ',' . htmlspecialchars(json_encode($childParentConfigs), ENT_QUOTES, 'UTF-8') . ");'"; } } $value = (float) @$GLOBALS['budgetDetails'][$nature][$month][$ledger->id]; $totalValue += $value; $trString .= ""; } $trString .= " | $totalValue | |||||||||||
| Receipt | |||||||||||||
| Payment | |||||||||||||
| Difference | @foreach ($months as $key => $month) @php $monthWithoutComa = str_replace(', ', '', $month); @endphp@endforeach | ||||||||||||