Skip to content

Commit

Permalink
Fix clearing filters
Browse files Browse the repository at this point in the history
  • Loading branch information
eldy committed Nov 6, 2016
1 parent 3ae4ecf commit c372d0a
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions htdocs/compta/bank/bankentries.php
Expand Up @@ -526,6 +526,9 @@
if ($page < 0) $page = 0;
}

// If not account defined $mode_balance_ok=false
if (empty($account)) $mode_balance_ok=false;
// If a search is done $mode_balance_ok=false
if (! empty($search_ref)) $mode_balance_ok=false;
if (! empty($req_nb)) $mode_balance_ok=false;
if (! empty($type)) $mode_balance_ok=false;
Expand Down Expand Up @@ -878,6 +881,12 @@
// If we are in a situation where we need/can show balance, we calculate the start of balance
if (! $balancecalculated && ! empty($arrayfields['balance']['checked']) && $mode_balance_ok)
{
if (! $account)
{
dol_print_error('', 'account is not defined but $mode_balance_ok is true');
exit;
}

//Loop on each record
$sign = 1;
$i = 0;
Expand Down

0 comments on commit c372d0a

Please sign in to comment.