From 3dea5a2f335084511ecb40971bb45b43c42bc0e3 Mon Sep 17 00:00:00 2001 From: Rodolphe Quiedeville Date: Thu, 10 Mar 2005 09:57:19 +0000 Subject: [PATCH] Ajoute les infos de fournisseur et de fichier cdr --- htdocs/telephonie/communication.class.php | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/htdocs/telephonie/communication.class.php b/htdocs/telephonie/communication.class.php index 8d213de00af..9e32b2b2f5a 100644 --- a/htdocs/telephonie/communication.class.php +++ b/htdocs/telephonie/communication.class.php @@ -167,6 +167,11 @@ class CommunicationTelephonique { return $error; } + /* + * Enregistre la ligne de communications dans llx_telephonie_communications_details + * + * + */ function logsql($db) { @@ -184,17 +189,19 @@ class CommunicationTelephonique { substr($this->date, 6,4)); - $sql = "INSERT INTO llx_telephonie_communications_details"; + $sql = "INSERT INTO ".MAIN_DB_PREFIX."telephonie_communications_details"; $sql .= " (ligne, date, numero, duree"; $sql .= ", tarif_achat_temp, tarif_achat_fixe, tarif_vente_temp, tarif_vente_fixe"; - $sql .= ", cout_achat, cout_vente, remise,dest,fourn_montant)"; + $sql .= ", cout_achat, cout_vente, remise,dest, fourn_montant"; + $sql .= " , fichier_cdr, fk_fournisseur)"; $sql .= " VALUES ("; $sql .= "'$this->ligne','".$db->idate($this->dateheure)."','$this->numero','$this->duree'"; $sql .= ", '$this->cout_temp_achat','$this->cout_fixe_achat','$this->cout_temp_vente','$this->cout_fixe_vente'"; $sql .= ", '$this->cout_achat','$this->cout_vente', '$this->remise'"; - $sql .= ",'".addslashes($this->tarif_libelle_vente)."','$this->montant')"; + $sql .= ",'".addslashes($this->tarif_libelle_vente)."','$this->montant'"; + $sql .= ",'".$this->fichier_cdr."','".$this->fournisseur."')"; if (! $db->query($sql)) {