diff --git a/htdocs/accountancy/class/accountancysystem.class.php b/htdocs/accountancy/class/accountancysystem.class.php index c64ede9953a..3cc09c24193 100644 --- a/htdocs/accountancy/class/accountancysystem.class.php +++ b/htdocs/accountancy/class/accountancysystem.class.php @@ -59,15 +59,15 @@ class AccountancySystem function create($user) { $now=dol_now(); - - $sql = "INSERT INTO ".MAIN_DB_PREFIX."accountingsystem"; + + $sql = "INSERT INTO ".MAIN_DB_PREFIX."accounting_system"; $sql.= " (date_creation, fk_user_author, numero,intitule)"; $sql.= " VALUES (".$this->db->idate($now).",".$user->id.",'".$this->numero."','".$this->intitule."')"; $resql = $this->db->query($sql); if ($resql) { - $id = $this->db->last_insert_id(MAIN_DB_PREFIX."accountingsystem"); + $id = $this->db->last_insert_id(MAIN_DB_PREFIX."accounting_system"); if ($id > 0) { diff --git a/htdocs/admin/accounting.php b/htdocs/admin/accounting.php index 571fc5a5672..6f2cd2e51e6 100644 --- a/htdocs/admin/accounting.php +++ b/htdocs/admin/accounting.php @@ -41,9 +41,9 @@ $compta_mode = defined('COMPTA_MODE')?COMPTA_MODE:'RECETTES-DEPENSES'; if ($action == 'setcomptamode') { $compta_mode = GETPOST('compta_mode','alpha'); - + $res = dolibarr_set_const($db, 'COMPTA_MODE', $compta_mode,'chaine',0,'',$conf->entity); - + if (! $res > 0) $error++; if (! $error) @@ -60,9 +60,9 @@ if ($action == 'setcomptamode') if ($action == 'setchart') { $chartofaccounts = GETPOST('chartofaccounts','alpha'); - + $res = dolibarr_set_const($db, 'CHARTOFACCOUNTS', $chartofaccounts,'chaine',0,'',$conf->entity); - + if (! $res > 0) $error++; if (! $error) @@ -81,9 +81,9 @@ if ($action == 'update' || $action == 'add') $constvalue = GETPOST('constvalue','alpha'); $consttype = GETPOST('consttype','alpha'); $constnote = GETPOST('constnote','alpha'); - + $res = dolibarr_set_const($db, $constname, $constvalue, $consttype, 0, $constnote, $conf->entity); - + if (! $res > 0) $error++; if (! $error) @@ -157,13 +157,13 @@ if (! empty($conf->global->ACCOUNTING_SELECTCHART) && ! empty($conf->accounting- { print ''; print_titre($langs->trans("Definechartofaccounts")); - + print '