diff --git a/htdocs/accountancy/customer/card.php b/htdocs/accountancy/customer/card.php
index eb7156eee82..60d9cdc8218 100644
--- a/htdocs/accountancy/customer/card.php
+++ b/htdocs/accountancy/customer/card.php
@@ -119,7 +119,7 @@ if (!empty($id)) {
print '';
print '';
- print load_fiche_titre($langs->trans('CustomersVentilation'), '', 'title_setup');
+ print load_fiche_titre($langs->trans('CustomersVentilation'), '', 'title_accountancy');
dol_fiche_head();
diff --git a/htdocs/accountancy/customer/lines.php b/htdocs/accountancy/customer/lines.php
index 10742b863d2..4a20d6e3764 100644
--- a/htdocs/accountancy/customer/lines.php
+++ b/htdocs/accountancy/customer/lines.php
@@ -37,6 +37,8 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/company.lib.php';
// Load translation files required by the page
$langs->loadLangs(array("bills", "compta", "accountancy", "productbatch"));
+$optioncss = GETPOST('optioncss', 'aZ'); // Option for the css output (always '' except when 'print')
+
$account_parent = GETPOST('account_parent');
$changeaccount = GETPOST('changeaccount');
// Search Getpost
@@ -389,7 +391,7 @@ if ($result) {
print '
'.$objp->tva_intra.' | ';
print '';
- print $codecompta.' ';
+ print $codecompta.' ';
print img_edit();
print '';
print ' | ';
diff --git a/htdocs/accountancy/expensereport/card.php b/htdocs/accountancy/expensereport/card.php
index 5d9bc60c6ac..1ee6a9e5541 100644
--- a/htdocs/accountancy/expensereport/card.php
+++ b/htdocs/accountancy/expensereport/card.php
@@ -121,7 +121,7 @@ if (!empty($id)) {
print '';
print '';
- print load_fiche_titre($langs->trans('ExpenseReportsVentilation'), '', 'title_setup');
+ print load_fiche_titre($langs->trans('ExpenseReportsVentilation'), '', 'title_accountancy');
dol_fiche_head();
diff --git a/htdocs/accountancy/expensereport/lines.php b/htdocs/accountancy/expensereport/lines.php
index 56f7ee6ba96..f77ee12071d 100644
--- a/htdocs/accountancy/expensereport/lines.php
+++ b/htdocs/accountancy/expensereport/lines.php
@@ -36,6 +36,8 @@ require_once DOL_DOCUMENT_ROOT . '/core/lib/date.lib.php';
// Load translation files required by the page
$langs->loadLangs(array("compta","bills","other","accountancy","trips","productbatch"));
+$optioncss = GETPOST('optioncss', 'aZ'); // Option for the css output (always '' except when 'print')
+
$account_parent = GETPOST('account_parent', 'int');
$changeaccount = GETPOST('changeaccount');
// Search Getpost
diff --git a/htdocs/accountancy/supplier/card.php b/htdocs/accountancy/supplier/card.php
index 622ac801fbc..ebbcb4a20df 100644
--- a/htdocs/accountancy/supplier/card.php
+++ b/htdocs/accountancy/supplier/card.php
@@ -121,7 +121,7 @@ if (!empty($id)) {
print '';
print '';
- print load_fiche_titre($langs->trans('SuppliersVentilation'), '', 'title_setup');
+ print load_fiche_titre($langs->trans('SuppliersVentilation'), '', 'title_accountancy');
dol_fiche_head();
diff --git a/htdocs/accountancy/supplier/lines.php b/htdocs/accountancy/supplier/lines.php
index e6ef6ac1291..e3079fa1dad 100644
--- a/htdocs/accountancy/supplier/lines.php
+++ b/htdocs/accountancy/supplier/lines.php
@@ -39,6 +39,8 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/company.lib.php';
// Load translation files required by the page
$langs->loadLangs(array("compta", "bills", "other", "accountancy", "productbatch"));
+$optioncss = GETPOST('optioncss', 'aZ'); // Option for the css output (always '' except when 'print')
+
$account_parent = GETPOST('account_parent');
$changeaccount = GETPOST('changeaccount');
// Search Getpost
diff --git a/htdocs/core/class/html.formaccounting.class.php b/htdocs/core/class/html.formaccounting.class.php
index 7292fe8c235..461a6a12947 100644
--- a/htdocs/core/class/html.formaccounting.class.php
+++ b/htdocs/core/class/html.formaccounting.class.php
@@ -277,9 +277,15 @@ class FormAccounting extends Form
$out = '';
$options = array();
+
+ if ($showempty == 2)
+ {
+ $options['0'] = '--- '.$langs->trans("None").' ---';
+ }
+
if ($usecache && ! empty($this->options_cache[$usecache]))
{
- $options = $this->options_cache[$usecache];
+ $options = array_merge($options, $this->options_cache[$usecache]);
$selected=$selectid;
}
else
@@ -333,14 +339,10 @@ class FormAccounting extends Form
if ($usecache)
{
$this->options_cache[$usecache] = $options;
+ unset($this->options_cache[$usecache]['0']);
}
}
- if ($showempty == 2)
- {
- $options['0'] = $langs->trans("None");
- }
-
$out .= Form::selectarray($htmlname, $options, $selected, ($showempty > 0 ? 1 : 0), 0, 0, '', 0, 0, 0, '', $morecss, 1);
return $out;