diff --git a/htdocs/opensurvey/class/opensurveysondage.class.php b/htdocs/opensurvey/class/opensurveysondage.class.php index 61c65a6244136e900fc406e488ccfc8c245b04a7..84c08a2e125b2093943f3a38399b0a4eb151d58b 100644 --- a/htdocs/opensurvey/class/opensurveysondage.class.php +++ b/htdocs/opensurvey/class/opensurveysondage.class.php @@ -179,7 +179,6 @@ class Opensurveysondage extends CommonObject global $langs; $sql = "SELECT"; - //$sql.= " t.rowid,"; $sql.= " t.id_sondage,"; $sql.= " t.commentaires,"; $sql.= " t.mail_admin,"; @@ -193,8 +192,7 @@ class Opensurveysondage extends CommonObject $sql.= " t.sujet,"; $sql.= " t.tms"; $sql.= " FROM ".MAIN_DB_PREFIX."opensurvey_sondage as t"; - if ($id > 0) $sql.= " WHERE t.rowid = ".$this->db->escape($id); - else $sql.= " WHERE t.id_sondage = '".$this->db->escape($numsurvey)."'"; + $sql.= " WHERE t.id_sondage = '".$this->db->escape($numsurvey)."'"; dol_syslog(get_class($this)."::fetch sql=".$sql, LOG_DEBUG); $resql=$this->db->query($sql); @@ -204,8 +202,6 @@ class Opensurveysondage extends CommonObject { $obj = $this->db->fetch_object($resql); - //$this->id = $obj->rowid; - $this->id_sondage = $obj->id_sondage; $this->commentaires = $obj->commentaires; $this->mail_admin = $obj->mail_admin; @@ -283,7 +279,6 @@ class Opensurveysondage extends CommonObject $sql.= " canedit=".$this->db->escape($this->canedit).","; $sql.= " allow_comments=".$this->db->escape($this->allow_comments); - //$sql.= " WHERE rowid=".$this->id; $sql.= " WHERE id_sondage='".$this->db->escape($this->id_sondage)."'"; $this->db->begin();