Code

Prepared for multiple asterisk servers
[gosa.git] / plugins / admin / fai / class_faiSummaryTab.inc
index 162236676e18903cb4add01832570c66a59ec66d..034f8cefe107b388f1f5a2a2cb6ee0acc628486e 100644 (file)
@@ -168,6 +168,14 @@ class faiSummaryTab extends plugin{
   /* This function calls all nescessary functions to generate the fai class summary tree */
   function execute() 
   {
+
+    /* Skip this if fai is deactivated */
+    $tmp = search_config($this->config->data,"faiManagement","CLASS");
+    if(empty($tmp)){
+      $str = "<h2>"._("You can't use this plugin until FAI is activated.")."</h2>";
+      return $str;
+    }    
+
     /* Check if we must (re)init the this tab */
     if(!$this->InitCalled){
       $this->init();
@@ -376,11 +384,6 @@ class faiSummaryTab extends plugin{
     $dn                    = $this->Releases [$this->Release];
     $resolvedClasses  = get_all_objects_for_given_base($dn,"(&(objectClass=FAIclass)(cn=".$class."))");
 
-    /* Check acls -> are we allowed to view the config summary ? */
-    if(!$this->acl_is_readable("readable")) {
-      return;
-    }
-
     /* Try to fetch all types of fai objects with the given cn  */
     foreach($resolvedClasses as $obj){