Code

Added some checks
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 25 Jan 2006 09:06:07 +0000 (09:06 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 25 Jan 2006 09:06:07 +0000 (09:06 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@2573 594d385d-05f5-0310-b6e9-bd551577e9d8

plugins/admin/systems/class_glpiAccount.inc
plugins/admin/systems/class_glpiAttachmentPool.inc

index a949632ea29f06e2a84a6d4d45dc0397a1f30eda..71036a3ac0e99a27c6a6a0a252c49430880a298e 100644 (file)
@@ -224,7 +224,6 @@ class glpiAccount extends plugin
     
     /* Remove Attachment fro this tab 
      */
-
     $once = true;
     foreach($_POST as $name => $value){
       if((preg_match("/^delAttachment_/",$name))&&($once)){
@@ -672,7 +671,6 @@ class glpiAccount extends plugin
       }
       $tmp = $this->handle->getComputerInformations($this->dn);
       $this->handle->addDevicesToComputer($this->usedDevices,$tmp[0]['ID']);
-      $this->handle->addAttachmentsToComputer($this->usedAttachments,$tmp[0]['ID']);
     }
   }
 
index 896ed980bb6407af1f6a73f3dd47c8c22ab5e4d0..25c39880cf02135af620abad071c9e72134c6f3c 100644 (file)
@@ -113,6 +113,7 @@ class glpiAttachmentPool extends plugin
 
       }else{
         $this->parent->handle->deleteAttachment($this->delAttach);
+        @unlink("/etc/gosa/glpi/".$this->filename);
         $attach     = $this->parent->handle->getAttachments();
       }
     }