diff --git a/htdocs/compta/bank/bankentries_list.php b/htdocs/compta/bank/bankentries_list.php index 902a96ec16c..d57e2cf5591 100644 --- a/htdocs/compta/bank/bankentries_list.php +++ b/htdocs/compta/bank/bankentries_list.php @@ -496,7 +496,7 @@ if (dol_strlen($search_dv_end) > 0) $sql .= " AND b.datev <= '".$db->idate($sear if ($search_ref) $sql .= natural_search("b.rowid", $search_ref, 1); if ($search_req_nb) $sql .= natural_search("b.num_chq", $search_req_nb); if ($search_num_releve) $sql .= natural_search("b.num_releve", $search_num_releve); -if ($search_conciliated != '' && $search_conciliated != '-1') $sql .= " AND b.rappro = ".$search_conciliated; +if ($search_conciliated != '' && $search_conciliated != '-1') $sql .= " AND b.rappro = ".urlencode($search_conciliated); if ($search_thirdparty) $sql .= natural_search("s.nom", $search_thirdparty); if ($search_description) { @@ -861,6 +861,10 @@ if ($resql) $varpage = empty($contextpage) ? $_SERVER["PHP_SELF"] : $contextpage; $selectedfields = $form->multiSelectArrayWithCheckbox('selectedfields', $arrayfields, $varpage); // This also change content of $arrayfields + // When action is 'reconcile', we force to have the column num_releve always enabled (otherwise we can't make reconciliation). + if ($action == 'reconcile') { + $arrayfields['b.num_releve']['checked'] = 1; + } print '
| '; - print price(price2num($balance, 'MT'), 1, $langs); + if ($search_conciliated !== '0') { + print price(price2num($balance, 'MT'), 1, $langs); + } print ' | '; } if (!empty($arrayfields['balance']['checked'])) { print ''; - print price(price2num($balance, 'MT'), 1, $langs); + if ($search_conciliated !== '0') { + print price(price2num($balance, 'MT'), 1, $langs); + } + print ' | '; + } + if (!empty($arrayfields['b.num_releve']['checked'])) + { + print ''; + print ''; + print ' '; print ' | '; } - - print ''; - print ''; - print ' '; - print ' | '; print ''; print ' '; print ' | ';