phpcompta-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Phpcompta-dev] r4690 - phpcompta/trunk/include


From: phpcompta-dev
Subject: [Phpcompta-dev] r4690 - phpcompta/trunk/include
Date: Mon, 9 Jan 2012 13:42:22 +0100 (CET)

Author: danydb
Date: 2012-01-09 13:42:22 +0100 (Mon, 09 Jan 2012)
New Revision: 4690

Modified:
   phpcompta/trunk/include/class_fiche_attr.php
Log:
bug attribut fiche : add blank : label add exception

Modified: phpcompta/trunk/include/class_fiche_attr.php
===================================================================
--- phpcompta/trunk/include/class_fiche_attr.php        2012-01-09 12:35:11 UTC 
(rev 4689)
+++ phpcompta/trunk/include/class_fiche_attr.php        2012-01-09 12:42:22 UTC 
(rev 4690)
@@ -138,6 +138,7 @@
     }
     public function insert()
     {
+        try{
         $this->verify();
         /*  please adapt */
         $sql="insert into attr_def(ad_text
@@ -151,12 +152,18 @@
                          array( 
$this->ad_text,$this->ad_type,$this->ad_size,$this->ad_extra
                               )
                      );
+        } catch (Exception $e)
+        {
+            throw ($e);
+        }
 
     }
 
     public function update()
     {
-        if ( $this->verify() != 0 ) return;
+        try 
+        {
+         $this->verify();
         if ( $this->ad_id < 9000) return;
         /*   please adapt */
         $sql=" update attr_def set ad_text = $1
@@ -168,6 +175,11 @@
                        ,$this->ad_type
                        ,$this->ad_id,$this->ad_size,$this->ad_extra)
              );
+        }catch (Exception $e)
+        {
+            throw ($e);
+        }
+        
 
     }
     /**




reply via email to

[Prev in Thread] Current Thread [Next in Thread]