From 776be334246bb7f1ad8868a3d52dbfa738da9133 Mon Sep 17 00:00:00 2001 From: Rodolphe Quiedeville Date: Tue, 8 Jul 2003 19:54:03 +0000 Subject: [PATCH] =?UTF-8?q?R=E9solution=20du=20bug=20sur=20les=20filtres?= =?UTF-8?q?=20en=20rapport=20a=20la=20societe?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- htdocs/facture.class.php3 | 2 +- htdocs/fichinter/fichinter.class.php3 | 2 +- htdocs/notify.class.php | 3 ++- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/htdocs/facture.class.php3 b/htdocs/facture.class.php3 index b5d5b4162c9..28efec8bc78 100644 --- a/htdocs/facture.class.php3 +++ b/htdocs/facture.class.php3 @@ -289,7 +289,7 @@ class Facture $mesg = "La facture ".$this->ref." a été validée.\n"; $notify = New Notify($this->db); - $notify->send($action_notify, $mesg, $filepdf); + $notify->send($action_notify, $this->socidp, $mesg, $filepdf); return $result; } diff --git a/htdocs/fichinter/fichinter.class.php3 b/htdocs/fichinter/fichinter.class.php3 index 0841be22307..029d69243ee 100644 --- a/htdocs/fichinter/fichinter.class.php3 +++ b/htdocs/fichinter/fichinter.class.php3 @@ -215,7 +215,7 @@ class Fichinter $mesg = "La fiche d'intervention ".$this->ref." a été validée.\n"; $notify = New Notify($this->db); - $notify->send($action_notify, $mesg, $filepdf); + $notify->send($action_notify, $this->societe_id, $mesg, $filepdf); return 1; } diff --git a/htdocs/notify.class.php b/htdocs/notify.class.php index fc3ff00355d..c575838f6ac 100644 --- a/htdocs/notify.class.php +++ b/htdocs/notify.class.php @@ -43,12 +43,13 @@ class Notify * * */ - Function send($action, $texte, $file="") + Function send($action, $socid, $texte, $file="") { $sql = "SELECT s.nom, c.email, c.idp, c.name, c.firstname, a.titre,n.rowid"; $sql .= " FROM llx_socpeople as c, llx_action_def as a, llx_notify_def as n, llx_societe as s"; $sql .= " WHERE n.fk_contact = c.idp AND a.rowid = n.fk_action"; $sql .= " AND n.fk_soc = s.idp AND n.fk_action = ".$action; + $sql .= " AND s.idp = ".$socid; $result = $this->db->query($sql); if ($result)