diff --git a/include/action.common.inc.php b/include/action.common.inc.php index eb6ff979b..c60f13ab3 100644 --- a/include/action.common.inc.php +++ b/include/action.common.inc.php @@ -149,7 +149,7 @@ if ($sub_action == "update") $act->get(); $act->fromArray($_POST); $error_id=$e->getCode(); - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; } } //---------------------------------------------------------------------- @@ -296,7 +296,7 @@ if ($sub_action == "save_action_st2") echo ''; $sub_action="add_action"; $error_id=$e->getCode(); - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; } } //-------------------------------------------------------------------------------- diff --git a/include/ajax/ajax_card.php b/include/ajax/ajax_card.php index 11c6e7044..628acb640 100644 --- a/include/ajax/ajax_card.php +++ b/include/ajax/ajax_card.php @@ -118,7 +118,7 @@ case 'rmfa': { $cn->rollback(); record_log($e->getMessage()); - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; echo $e->getMessage(); } $html=ob_get_contents(); diff --git a/include/ajax/ajax_display_letter.php b/include/ajax/ajax_display_letter.php index 7e8f8007c..9a90996c0 100644 --- a/include/ajax/ajax_display_letter.php +++ b/include/ajax/ajax_display_letter.php @@ -38,7 +38,7 @@ try { }catch (Exception $e ) { record_log($e->getMessage()); - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; return; } diff --git a/include/ajax/ajax_ledger.php b/include/ajax/ajax_ledger.php index 7f93ea81f..29b797a78 100644 --- a/include/ajax/ajax_ledger.php +++ b/include/ajax/ajax_ledger.php @@ -161,7 +161,7 @@ case 'rmop': } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; $e->getMessage(); $cn->rollback(); } @@ -207,7 +207,7 @@ case 'de': } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; echo Icon_Action::close($div); echo '

'._("Désolé il y a une erreur").'

'; } @@ -512,7 +512,7 @@ case 'save': } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; if ( DEBUG ) echo $e->getMessage(); alert(_( "Changement impossible: on ne peut pas changer la date dans une période fermée")); } @@ -570,7 +570,7 @@ case 'reverseop': } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; echo $e->getMessage(); $cn->rollback(); } diff --git a/include/ajax/ajax_periode.php b/include/ajax/ajax_periode.php index 367546ef2..5ef93d85b 100644 --- a/include/ajax/ajax_periode.php +++ b/include/ajax/ajax_periode.php @@ -205,7 +205,7 @@ switch ($act) } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; $html=$e->getTrace(); throw $e; } diff --git a/include/ajax/ajax_tva_parameter.php b/include/ajax/ajax_tva_parameter.php index cf2107aa0..0e92bbc02 100644 --- a/include/ajax/ajax_tva_parameter.php +++ b/include/ajax/ajax_tva_parameter.php @@ -42,7 +42,7 @@ try } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; return; } diff --git a/include/anc_key.inc.php b/include/anc_key.inc.php index a2b343f43..da0ab116f 100644 --- a/include/anc_key.inc.php +++ b/include/anc_key.inc.php @@ -56,7 +56,7 @@ switch ($op) } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; echo span($e->getMessage(), ' class="notice"'); Anc_Key::display_list(); Anc_Key::key_add(); diff --git a/include/card_attr.inc.php b/include/card_attr.inc.php index 88e3d9a9b..d0fa1fbab 100644 --- a/include/card_attr.inc.php +++ b/include/card_attr.inc.php @@ -56,7 +56,7 @@ if ( isset($_POST['save'])) } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; alert($e->getMessage()); $cn->rollback(); } diff --git a/include/cfgledger.inc.php b/include/cfgledger.inc.php index 679827d06..56561e503 100644 --- a/include/cfgledger.inc.php +++ b/include/cfgledger.inc.php @@ -62,7 +62,7 @@ if ( $action_frm == 'update') } catch (Exception $e) { record_log($e->getMessage()); - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; alert($e->getMessage()); } } @@ -88,7 +88,7 @@ if ($action_frm == 'delete' ) catch (Exception $e) { record_log($e->getMessage()); - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; alert ($e->getMessage()); } @@ -111,7 +111,7 @@ if (isset($_POST['add'])) catch (Exception $e) { record_log($e->getMessage()); - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; alert($e->getMessage()); } } @@ -146,7 +146,7 @@ switch ($sa) catch (Exception $e) { record_log($e->getMessage()); - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; alert($e->getMessage()); } break; diff --git a/include/class/acc_bilan.class.php b/include/class/acc_bilan.class.php index 398a3eb81..a7f81cfc1 100644 --- a/include/class/acc_bilan.class.php +++ b/include/class/acc_bilan.class.php @@ -284,7 +284,7 @@ class Acc_Bilan } catch(Exception $Ex) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; echo $Ex->getMessage(); throw $Ex; } diff --git a/include/class/acc_ledger.class.php b/include/class/acc_ledger.class.php index d43dcd933..e1c85d3ce 100644 --- a/include/class/acc_ledger.class.php +++ b/include/class/acc_ledger.class.php @@ -373,7 +373,7 @@ class Acc_Ledger extends jrn_def_sql } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; $this->db->rollback(); throw $e; } @@ -834,7 +834,7 @@ class Acc_Ledger extends jrn_def_sql } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; if ($e->getCode()==1) { echo _("Aucune période ouverte"); @@ -1357,7 +1357,7 @@ class Acc_Ledger extends jrn_def_sql } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; $this->db->rollback(); echo _('OPERATION ANNULEE '); echo '
'; @@ -2134,7 +2134,7 @@ class Acc_Ledger extends jrn_def_sql catch (Exception $e) { $cn->rollback(); - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; } $cn->commit(); } @@ -2385,7 +2385,7 @@ class Acc_Ledger extends jrn_def_sql } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; throw $e; } } @@ -2642,7 +2642,7 @@ class Acc_Ledger extends jrn_def_sql } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; throw $e; } } diff --git a/include/class/acc_ledger_fin.class.php b/include/class/acc_ledger_fin.class.php index 6392d8602..22ff0f0c1 100644 --- a/include/class/acc_ledger_fin.class.php +++ b/include/class/acc_ledger_fin.class.php @@ -1003,7 +1003,7 @@ class Acc_Ledger_Fin extends Acc_Ledger __FILE__ . ':' . __LINE__ . ' ' . $e->getMessage(); $this->db->rollback(); - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; throw new Exception($r); } $this->db->commit(); diff --git a/include/class/acc_ledger_info.class.php b/include/class/acc_ledger_info.class.php index 44efb7fb2..137d67290 100644 --- a/include/class/acc_ledger_info.class.php +++ b/include/class/acc_ledger_info.class.php @@ -63,7 +63,7 @@ class Acc_Ledger_Info } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; echo "Echec sauvegarde info additionnelles"; throw $e; } @@ -86,7 +86,7 @@ class Acc_Ledger_Info } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; $this->cn->rollback(); echo "Echec sauvegarde info additionnelles"; throw $e; diff --git a/include/class/acc_ledger_purchase.class.php b/include/class/acc_ledger_purchase.class.php index 4365cfdc3..523cd59c8 100644 --- a/include/class/acc_ledger_purchase.class.php +++ b/include/class/acc_ledger_purchase.class.php @@ -944,7 +944,7 @@ class Acc_Ledger_Purchase extends Acc_Ledger }//end try catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; echo ''. 'Erreur dans l\'enregistrement '. __FILE__.':'.__LINE__.' '. @@ -1051,7 +1051,7 @@ class Acc_Ledger_Purchase extends Acc_Ledger } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; if ($e->getCode() == 1 ) { throw new Exception( _("Aucune période ouverte")); diff --git a/include/class/acc_ledger_sold.class.php b/include/class/acc_ledger_sold.class.php index 1979e7522..50cfbb49a 100644 --- a/include/class/acc_ledger_sold.class.php +++ b/include/class/acc_ledger_sold.class.php @@ -607,7 +607,7 @@ class Acc_Ledger_Sold extends Acc_Ledger { } } } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; echo '' . 'Erreur dans l\'enregistrement ' . __FILE__ . ':' . __LINE__ . ' ' . diff --git a/include/class/acc_report.class.php b/include/class/acc_report.class.php index 0c15e17ce..d08753521 100644 --- a/include/class/acc_report.class.php +++ b/include/class/acc_report.class.php @@ -216,7 +216,7 @@ class Acc_Report } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; $this->db->rollback(); echo $e->getMessage(); } @@ -258,7 +258,7 @@ class Acc_Report } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; $this->db->rollback(); echo $e->getMessage(); } diff --git a/include/class/anc_group_operation.class.php b/include/class/anc_group_operation.class.php index c5e45061d..991998822 100644 --- a/include/class/anc_group_operation.class.php +++ b/include/class/anc_group_operation.class.php @@ -74,7 +74,7 @@ class Anc_Group_Operation } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; echo $e->getTrace(); $this->db->rollback(); throw new Exception($e); @@ -260,7 +260,7 @@ class Anc_Group_Operation } catch (Exception $ex) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; echo ''. 'Erreur dans l\'enregistrement '. __FILE__.':'.__LINE__.' '. diff --git a/include/class/anc_key.class.php b/include/class/anc_key.class.php index ed06eb074..2ad6340f1 100644 --- a/include/class/anc_key.class.php +++ b/include/class/anc_key.class.php @@ -268,7 +268,7 @@ class Anc_Key { if ( DEBUG ) { echo $e->getTraceAsString(); } else { echo _('erreur').$e->getMessage();} - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; $cn->rollback(); } } diff --git a/include/class/anc_operation.class.php b/include/class/anc_operation.class.php index d6f7b59f9..672f393e2 100644 --- a/include/class/anc_operation.class.php +++ b/include/class/anc_operation.class.php @@ -491,7 +491,7 @@ class Anc_Operation } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; } } /*!\brief display the form for PA diff --git a/include/class/default_menu.class.php b/include/class/default_menu.class.php index acb85207f..8b973d62e 100644 --- a/include/class/default_menu.class.php +++ b/include/class/default_menu.class.php @@ -106,7 +106,7 @@ class Default_Menu } } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; echo $e->getMessage(); throw $e; } diff --git a/include/class/document_modele.class.php b/include/class/document_modele.class.php index 7c29a8333..af8d254c4 100644 --- a/include/class/document_modele.class.php +++ b/include/class/document_modele.class.php @@ -194,7 +194,7 @@ class Document_modele } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; rollback($this->cn); return ; } @@ -360,7 +360,7 @@ class Document_modele } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; rollback($this->cn); return ; } diff --git a/include/class/document_type.class.php b/include/class/document_type.class.php index 92ffc823b..74ebafdaf 100644 --- a/include/class/document_type.class.php +++ b/include/class/document_type.class.php @@ -103,7 +103,7 @@ class Document_type } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; alert(j(_("Impossible d'ajouter [$p_value] ") . $e->getMessage())); } } @@ -120,7 +120,7 @@ class Document_type } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; alert(" Erreur " . $e->getMessage()); } } @@ -133,7 +133,7 @@ class Document_type } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; alert("Erreur " . $e->getMessage()); } } diff --git a/include/class/dossier.class.php b/include/class/dossier.class.php index ecd439e1a..51ea7f03f 100644 --- a/include/class/dossier.class.php +++ b/include/class/dossier.class.php @@ -326,7 +326,7 @@ class Dossier { echo_warning($e->getMessage()); - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; $cn->rollback(); } } diff --git a/include/class/fiche.class.php b/include/class/fiche.class.php index 50bb3fb25..999b50271 100644 --- a/include/class/fiche.class.php +++ b/include/class/fiche.class.php @@ -925,7 +925,7 @@ class Fiche } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString()); $this->cn->rollback(); throw ($e); return; @@ -1117,7 +1117,7 @@ class Fiche $e->getMessage(). ''; record_log($e->getMessage()); - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; $this->cn->rollback(); return; } diff --git a/include/class/fiche_attr.class.php b/include/class/fiche_attr.class.php index 98cea2e90..5ddb70971 100644 --- a/include/class/fiche_attr.class.php +++ b/include/class/fiche_attr.class.php @@ -99,7 +99,7 @@ class Fiche_Attr $this->cn->exec_sql($this->ad_extra); }catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; throw new Exception ("La requête SQL ".h($this->ad_extra)." est invalide "); } } @@ -161,7 +161,7 @@ class Fiche_Attr ); } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; throw $e; } @@ -185,7 +185,7 @@ class Fiche_Attr ); }catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; throw $e; } diff --git a/include/class/periode.class.php b/include/class/periode.class.php index 16ca96d80..7cca1f516 100644 --- a/include/class/periode.class.php +++ b/include/class/periode.class.php @@ -273,7 +273,7 @@ class Periode catch (Exception $e) { record_log($e->getMessage()." - ".$e->getCode()); - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; $this->cn->rollback(); throw $e; } @@ -495,7 +495,7 @@ class Periode } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; $this->cn->rollback(); throw $e; } diff --git a/include/class/pre_op_ach.class.php b/include/class/pre_op_ach.class.php index fb9640e77..7caa7668d 100644 --- a/include/class/pre_op_ach.class.php +++ b/include/class/pre_op_ach.class.php @@ -104,7 +104,7 @@ class Pre_op_ach extends Pre_operation_detail } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; echo ($e->getMessage()); $this->db->rollback(); } diff --git a/include/class/pre_op_advanced.class.php b/include/class/pre_op_advanced.class.php index 2c110fe45..51ba703e5 100644 --- a/include/class/pre_op_advanced.class.php +++ b/include/class/pre_op_advanced.class.php @@ -98,7 +98,7 @@ class Pre_Op_Advanced extends Pre_operation_detail } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; echo ($e->getMessage()); $this->db->rollback(); } diff --git a/include/class/pre_op_fin.class.php b/include/class/pre_op_fin.class.php index f293eb253..e443605ef 100644 --- a/include/class/pre_op_fin.class.php +++ b/include/class/pre_op_fin.class.php @@ -86,7 +86,7 @@ class Pre_op_fin extends Pre_operation_detail } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; echo ($e->getMessage()); $this->db->rollback(); } diff --git a/include/class/pre_op_ods.class.php b/include/class/pre_op_ods.class.php index d886768aa..dc30e34f6 100644 --- a/include/class/pre_op_ods.class.php +++ b/include/class/pre_op_ods.class.php @@ -78,7 +78,7 @@ class Pre_op_ods extends Pre_operation_detail } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; echo ($e->getMessage()); $this->db->rollback(); } diff --git a/include/class/pre_op_ven.class.php b/include/class/pre_op_ven.class.php index c76252c1b..2ffe031cd 100644 --- a/include/class/pre_op_ven.class.php +++ b/include/class/pre_op_ven.class.php @@ -102,7 +102,7 @@ class Pre_op_ven extends Pre_operation_detail } catch (Exception $e) { - record_log($e->getTraceAsString()); + record_log($e->getMessage()." ".$e->getTraceAsString());; echo ($e->getMessage()); $this->db->rollback(); }