@if ( $code->parent_code_id == null)
{{ $code['code_no'] }}
@else
{{ $code['code_no'] }}
@endif
@if ($code->descendants->isNotEmpty() || $code->parent_code_id == null)
{{ $code['code_title'] }}
@else
{{ $code['code_title'] }}
@endif
@if (count($code->descendants) == 0)
@error('code_no')
{{ $message }}
@enderror
@endif
@if ($code->descendants->isNotEmpty())
@foreach ($code->descendants as $descendant)
@if ($descendant->code_active === 'YES')
@include('budget.partials.inputField', ['code' => $descendant, 'node'=>$node+1, 'budgetInfo' => $budgetInfo ?? null])
@endif
@endforeach