value => $thisbranch,
branchname => $branches->{$thisbranch}->{'branchname'},
);
- $row{'selected'} = 1 if( $thisbranch eq $data->{branchcode}) ;
+ $row{'selected'} = 1 if( $thisbranch && $data->{branchcode} && $thisbranch eq $data->{branchcode}) ;
push @branchloop, \%row;
}
$template->param( branchloop => \@branchloop );
push @{$budget_loop}, {
b_id => $r->{budget_id},
b_txt => $r->{budget_name},
+ b_active => $r->{budget_period_active},
b_sel => ( $r->{budget_id} == $budget_id ) ? 1 : 0,
};
}