diff --git a/htdocs/accountancy/bookkeeping/card.php b/htdocs/accountancy/bookkeeping/card.php index 77c9a4a135e..f4e7ff8ae0a 100644 --- a/htdocs/accountancy/bookkeeping/card.php +++ b/htdocs/accountancy/bookkeeping/card.php @@ -213,6 +213,18 @@ if ($action == 'create') { $conf->global->ACCOUNTING_MISCELLANEOUS_JOURNAL => $conf->global->ACCOUNTING_MISCELLANEOUS_JOURNAL, $conf->global->ACCOUNTING_EXPENSEREPORT_JOURNAL => $conf->global->ACCOUNTING_EXPENSEREPORT_JOURNAL ); + + $sql = 'SELECT DISTINCT accountancy_journal FROM '.MAIN_DB_PREFIX.'bank_account WHERE clos=0'; + $resql=$db->query($sql); + if (!$resql) { + setEventMessages($db->lasterror,null,'errors'); + } else { + while ($obj_bank=$db->fetch_object($resql)) { + if (!empty($obj_bank->accountancy_journal)) { + $code_journal_array[$obj_bank->accountancy_journal]=$obj_bank->accountancy_journal; + } + } + } $book = new BookKeeping($db); $next_num_mvt = $book->getNextNumMvt(); diff --git a/htdocs/accountancy/journal/bankjournal.php b/htdocs/accountancy/journal/bankjournal.php index b33becb3f47..b6ae5b295d8 100644 --- a/htdocs/accountancy/journal/bankjournal.php +++ b/htdocs/accountancy/journal/bankjournal.php @@ -577,9 +577,9 @@ else $period = $form->select_date($date_start, 'date_start', 0, 0, 0, '', 1, 0, 1) . ' - ' . $form->select_date($date_end, 'date_end', 0, 0, 0, '', 1, 0, 1); $varlink = 'id_account='.$id_bank_account; + report_header($nom, $nomlink, $period, $periodlink, $description, $builddate, $exportlink, array('action' => ''), '', $varlink); - print ''; print ''; diff --git a/htdocs/core/lib/functions.lib.php b/htdocs/core/lib/functions.lib.php index 0e6214560c4..51e47c0ee8a 100644 --- a/htdocs/core/lib/functions.lib.php +++ b/htdocs/core/lib/functions.lib.php @@ -2985,7 +2985,11 @@ function print_barre_liste($titre, $page, $file, $options='', $sortfield='', $so // Left if ($picto && $titre) print ''.img_picto('', $picto, '', $pictoisfullpath).''; - print '
'.$titre.'
'; + print '
'.$titre; + if (!empty($totalnboflines) && !empty($titre)) { + print ' ('.$totalnboflines.')'; + } + print '
'; // Center if ($center) diff --git a/htdocs/core/lib/report.lib.php b/htdocs/core/lib/report.lib.php index e8cecacf589..fa05e632983 100644 --- a/htdocs/core/lib/report.lib.php +++ b/htdocs/core/lib/report.lib.php @@ -48,8 +48,6 @@ function report_header($nom,$variante,$period,$periodlink,$description,$builddat if(! empty($varlink)) $varlink = '?'.$varlink; - if(! empty($varlink)) $varlink = '?'.$varlink; - $h=0; $head[$h][0] = $_SERVER["PHP_SELF"].$varlink; $head[$h][1] = $langs->trans("Report");