diff --git a/htdocs/admin/accountant.php b/htdocs/admin/accountant.php index da98e18d04f..e48ce5f2382 100644 --- a/htdocs/admin/accountant.php +++ b/htdocs/admin/accountant.php @@ -34,8 +34,7 @@ $contextpage = GETPOST('contextpage', 'aZ') ?GETPOST('contextpage', 'aZ') : 'adm // Load translation files required by the page $langs->loadLangs(array('admin', 'companies')); -if (!$user->admin) -{ +if (!$user->admin) { accessforbidden(); } @@ -48,14 +47,12 @@ $error = 0; $parameters = array(); $reshook = $hookmanager->executeHooks('doActions', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks -if ($reshook < 0) -{ +if ($reshook < 0) { setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); } if (($action == 'update' && !GETPOST("cancel", 'alpha')) -|| ($action == 'updateedit')) -{ +|| ($action == 'updateedit')) { dolibarr_set_const($db, "MAIN_INFO_ACCOUNTANT_NAME", GETPOST("nom", 'alphanohtml'), 'chaine', 0, '', $conf->entity); dolibarr_set_const($db, "MAIN_INFO_ACCOUNTANT_ADDRESS", GETPOST("address", 'alphanohtml'), 'chaine', 0, '', $conf->entity); dolibarr_set_const($db, "MAIN_INFO_ACCOUNTANT_TOWN", GETPOST("town", 'alphanohtml'), 'chaine', 0, '', $conf->entity); @@ -70,8 +67,7 @@ if (($action == 'update' && !GETPOST("cancel", 'alpha')) dolibarr_set_const($db, "MAIN_INFO_ACCOUNTANT_CODE", GETPOST("code", 'alphanohtml'), 'chaine', 0, '', $conf->entity); dolibarr_set_const($db, "MAIN_INFO_ACCOUNTANT_NOTE", GETPOST("note", 'restricthtml'), 'chaine', 0, '', $conf->entity); - if ($action != 'updateedit' && !$error) - { + if ($action != 'updateedit' && !$error) { setEventMessages($langs->trans("SetupSaved"), null, 'mesgs'); header("Location: ".$_SERVER["PHP_SELF"]); exit; @@ -122,7 +118,7 @@ print ''; print ''; print ''."\n"; -// Name of Accountant Company +// Name of Accountant Company print ''."\n";
'.$langs->trans("CompanyInfo").''.$langs->trans("Value").'
'; print 'global->MAIN_INFO_ACCOUNTANT_NAME) ? ' autofocus="autofocus"' : '').'>