diff --git a/htdocs/accountancy/admin/card.php b/htdocs/accountancy/admin/card.php
index 1b3943ebd82..822a4d19bcd 100644
--- a/htdocs/accountancy/admin/card.php
+++ b/htdocs/accountancy/admin/card.php
@@ -37,6 +37,7 @@ $langs->load("accountancy");
$mesg = '';
$action = GETPOST('action');
+$backtopage = GETPOST('backtopage');
$id = GETPOST('id', 'int');
$rowid = GETPOST('rowid', 'int');
$cancel = GETPOST('cancel');
@@ -51,6 +52,13 @@ $object = new AccountingAccount($db);
* Action
*/
+if (GETPOST('cancel'))
+{
+ $urltogo=$backtopage?$backtopage:dol_buildpath('/accountancy/admin/account.php',1);
+ header("Location: ".$urltogo);
+ exit;
+}
+
if ($action == 'add' && $user->rights->accounting->chartofaccount)
{
if (! $cancel) {
@@ -106,7 +114,9 @@ if ($action == 'add' && $user->rights->accounting->chartofaccount)
}
if (! $error)
{
- header("Location: account.php");
+ setEventMessages("RecordCreatedSuccessfully",null,'mesgs');
+ $urltogo=$backtopage?$backtopage:dol_buildpath('/accountancy/admin/account.php',1);
+ header("Location: ".$urltogo);
exit;
}
}
diff --git a/htdocs/accountancy/admin/fiscalyear.php b/htdocs/accountancy/admin/fiscalyear.php
index ff904ea96f2..4127f5e4ee2 100644
--- a/htdocs/accountancy/admin/fiscalyear.php
+++ b/htdocs/accountancy/admin/fiscalyear.php
@@ -80,7 +80,7 @@ $max = 100;
$form = new Form($db);
-$title = $langs->trans('FiscalYears');
+$title = $langs->trans('AccountingPeriods');
$helpurl = "";
llxHeader('', $title, $helpurl);
@@ -106,7 +106,7 @@ if ($result) {
$i = 0;
- $title = $langs->trans('FiscalYears');
+ $title = $langs->trans('AccountingPeriods');
print_barre_liste($title, $page, $_SERVER["PHP_SELF"], $params, $sortfield, $sortorder, '', $num, $nbtotalofrecords, 'title_accountancy', 0, '', '', $limit, 1);
// Load attribute_label
diff --git a/htdocs/accountancy/admin/index.php b/htdocs/accountancy/admin/index.php
index 84234b2d535..b013e8b7bd3 100644
--- a/htdocs/accountancy/admin/index.php
+++ b/htdocs/accountancy/admin/index.php
@@ -50,12 +50,12 @@ $action = GETPOST('action', 'alpha');
// Parameters ACCOUNTING_* and others
$list = array (
- 'ACCOUNTING_LIMIT_LIST_VENTILATION',
- 'ACCOUNTING_LENGTH_DESCRIPTION', // adjust size displayed for lines description for dol_trunc
- 'ACCOUNTING_LENGTH_DESCRIPTION_ACCOUNT', // adjust size displayed for select account description for dol_trunc
+ //'ACCOUNTING_LIMIT_LIST_VENTILATION', Useless, we can change value dynamically, so we use default global setup
'ACCOUNTING_MANAGE_ZERO',
'ACCOUNTING_LENGTH_GACCOUNT',
- 'ACCOUNTING_LENGTH_AACCOUNT'
+ 'ACCOUNTING_LENGTH_AACCOUNT' ,
+ 'ACCOUNTING_LENGTH_DESCRIPTION', // adjust size displayed for lines description for dol_trunc
+ 'ACCOUNTING_LENGTH_DESCRIPTION_ACCOUNT', // adjust size displayed for select account description for dol_trunc
);
$list_account = array (
@@ -246,24 +246,20 @@ if (! empty($user->admin) || ! empty($user->rights->accountancy->chartofaccount)
$var = true;
print '
';
print "| " . $langs->trans("Selectchartofaccounts") . " | ";
- print "";
+ print ' | ';
print ' |