From 80a1f576dc7b9f3d9ebf8615b30d4a484d8b8818 Mon Sep 17 00:00:00 2001 From: Rodolphe Quiedeville Date: Wed, 21 Jul 2004 15:20:37 +0000 Subject: [PATCH] Ajout fonction update_note --- htdocs/facture.class.php | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/htdocs/facture.class.php b/htdocs/facture.class.php index e856cd9b372..07fe2db7a78 100644 --- a/htdocs/facture.class.php +++ b/htdocs/facture.class.php @@ -909,6 +909,30 @@ class Facture return 'Payée'; } } + + + /** + * Mets à jour les commentaires + * + */ + Function update_note($note) + { + $sql = "UPDATE ".MAIN_DB_PREFIX."facture SET note = '$note'"; + $sql .= " WHERE rowid =". $this->id; + + if ($this->db->query($sql) ) + { + return 1; + } + else + { + print $this->db->error() . ' in ' . $sql; + return -1; + } + } + + + } class FactureLigne