Code

Added acls for printer glpi
[gosa.git] / plugins / admin / systems / class_workstationGeneric.inc
index 0cd3d31912a2d4e32ffbc4c9d7d5c01fa903ac34..b61573302a721d87d37dca48e8418335b18429c1 100644 (file)
@@ -194,7 +194,7 @@ class workgeneric extends plugin
     foreach($_POST as $name => $value){
       if(preg_match("/^chooseBase/",$name) && $once && $this->acl_is_writeable("base")){
         $once = false;
-        $this->dialog = new baseSelectDialog($this->config,$this);
+        $this->dialog = new baseSelectDialog($this->config,$this,$this->get_allowed_bases());
         $this->dialog->setCurrentBase($this->base);
       }
     }
@@ -244,7 +244,7 @@ class workgeneric extends plugin
 
     $smarty->assign("cn", $this->cn);
     $smarty->assign("l", $this->l);
-    $smarty->assign("bases", $this->config->idepartments);
+    $smarty->assign("bases", $this->get_allowed_bases());
     $smarty->assign("staticAddress", "");
 
     $tmp = array();
@@ -338,10 +338,6 @@ class workgeneric extends plugin
             $this->is_modified= TRUE;
           }
         }
-      }else{
-
-        print_red(sprintf(_("You are not allowed to move this object to '%s'."),LDAP::fix($_POST['base'])));
-        $this->set_acl_base('dummy,'.$this->base);
       }
     }
     $this->netConfigDNS->save_object();