diff --git a/include/class/acc_balance.class.php b/include/class/acc_balance.class.php index 446b2ef8d..d2ecc88ca 100644 --- a/include/class/acc_balance.class.php +++ b/include/class/acc_balance.class.php @@ -448,14 +448,5 @@ class Acc_Balance $p_pdf->write_cell(10,6,$side); $p_pdf->line_new(); } - static function test_me () - { - require 'class/user.class.php'; - global $g_user; - $cn=Dossier::connect(); - $g_user=new User($cn); - $a=new Acc_Balance($cn); - $a->get_row(163, 175, 1); - var_dump($a); - } + } diff --git a/include/class/acc_ledger.class.php b/include/class/acc_ledger.class.php index c21754054..3fe53f67c 100644 --- a/include/class/acc_ledger.class.php +++ b/include/class/acc_ledger.class.php @@ -1047,7 +1047,11 @@ class Acc_Ledger extends jrn_def_sql */ if ($this->check_periode()==false||!isset($p_array['period'])) { - $periode->find_periode($e_date); + try { + $periode->find_periode($e_date); + } catch (Exception $e) { + throw new Exception(_("Période inexistante"), 6, $e); + } } else { @@ -2531,7 +2535,7 @@ class Acc_Ledger extends jrn_def_sql /* Numbering (only FIN) */ $num_op=new ICheckBox('numb_operation'); echo dossier::hidden(); - echo HtmlInput::hidden('ac', $_REQUEST['ac']); + echo HtmlInput::hidden('ac', $http->request('ac')); echo $hidden; $cn=$this->db; diff --git a/include/class/acc_ledger_info.class.php b/include/class/acc_ledger_info.class.php index 689879b06..44efb7fb2 100644 --- a/include/class/acc_ledger_info.class.php +++ b/include/class/acc_ledger_info.class.php @@ -199,20 +199,4 @@ class Acc_Ledger_Info $this->insert(); } } - static function test_me() - { - echo "Dossier = ".Dossier::id(); - $cn=Dossier::connect(); - $a=new Acc_Ledger_Info($cn); - $a->jr_id=3; - $a->id_type='BON_COMMANDE'; - $a->ji_value='BON'; - var_dump($a); - $a->insert(); - - $a->set_jrn_id(7); - $a->set_type('OTHER'); - $a->set_value('Autre test'); - $a->insert(); - } } diff --git a/include/lib/pdf_core.class.php b/include/lib/pdf_core.class.php index f85fcd206..4664cf49c 100644 --- a/include/lib/pdf_core.class.php +++ b/include/lib/pdf_core.class.php @@ -253,7 +253,7 @@ class PDF_Core extends TFPDF parent::Ln($this->bigger); $this->bigger=0; } - /** + /** * If the step is even then return 1 and set the backgroup color to blue , otherwise * returns 0, and set the background color to white * It is use to compute alternated colored row , it the parameter fill in write_cell and