Code

Added acls for FAI objects
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Fri, 14 Jul 2006 05:55:19 +0000 (05:55 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Fri, 14 Jul 2006 05:55:19 +0000 (05:55 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@4144 594d385d-05f5-0310-b6e9-bd551577e9d8

15 files changed:
plugins/admin/fai/class_faiHook.inc
plugins/admin/fai/class_faiManagement.inc
plugins/admin/fai/class_faiPackage.inc
plugins/admin/fai/class_faiPartitionTable.inc
plugins/admin/fai/class_faiProfile.inc
plugins/admin/fai/class_faiScript.inc
plugins/admin/fai/class_faiTemplate.inc
plugins/admin/fai/class_faiVariable.inc
plugins/admin/fai/tabsHook.inc
plugins/admin/fai/tabsPackage.inc
plugins/admin/fai/tabsPartition.inc
plugins/admin/fai/tabsProfile.inc
plugins/admin/fai/tabsScript.inc
plugins/admin/fai/tabsTemplate.inc
plugins/admin/fai/tabsVariable.inc

index 7659b66550f646c261934ed480f725cf4f381593..5d370753518651d23227629f3fdd398edf4f4f2e 100644 (file)
@@ -466,6 +466,19 @@ class faiHook extends plugin
       $this->handle_object_tagging($sub_dn, $this->gosaUnitTag);
     }
   }
+
+  /* Return plugin informations for acl handling */ 
+  function plInfo()
+  {
+    return (array(  
+          "plDescription"     => _("FAI hook"),
+          "plSelfModify"      => FALSE,
+          "plDepends"         => array("objectClass" => "FAIclass"),
+          "cn"                => _("Name"),
+          "description"       => _("Description"),
+          "FAItast"           => _("Task"),
+          "FAIscript"         => _("FAI script")));
+  }
 }
 
 // vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler:
index 057cf420be16857aefa87ef33a4f49b040349bfa..ed479f75f706b06018ba398114b1d8eaabcbe0ac 100644 (file)
@@ -574,24 +574,29 @@ class faiManagement extends plugin
                if(($this->dialog != NULL) && (isset($this->dialog->config))){
                        $display .= $this->dialog->execute();
                        /* Don't show buttons if tab dialog requests this */
-                       if (((isset($this->dialog->current))&&($this->dialog->by_object[$this->dialog->current]->is_dialog))){
-                               
-                       }elseif(((isset($this->dialog->current))&&(!$this->dialog->by_object[$this->dialog->current]->is_dialog))){
-                               $display.= "<p style=\"text-align:right\">\n";
-                               $display.= "<input type=\"submit\" name=\"edit_finish\" style=\"width:80px\" value=\""._("Ok")."\">\n";
-                               $display.= "&nbsp;\n";
-        if ($this->dn != "new"){
-          $display.= "<input type=submit name=\"edit_apply\" value=\""._("Apply")."\">\n";
+
+      if(isset($this->dialog->current)){
+
+        $obj = $this->dialog->by_object[$this->dialog->current];
+
+        if((isset($obj->is_dialog) && (!$obj->is_dialog)) || (isset($obj->dialog) && (!$obj->dialog))){
+
+          $display.= "<p style=\"text-align:right\">\n";
+          $display.= "<input type=\"submit\" name=\"edit_finish\" style=\"width:80px\" value=\""._("Ok")."\">\n";
           $display.= "&nbsp;\n";
+          if ($this->dn != "new"){
+            $display.= "<input type=submit name=\"edit_apply\" value=\""._("Apply")."\">\n";
+            $display.= "&nbsp;\n";
+          }
+          $display.= "<input type=\"submit\" name=\"edit_cancel\" value=\""._("Cancel")."\">\n";
+          $display.= "</p>";
+        }elseif(!isset($this->dialog->current)){
+          $display.= "<p style=\"text-align:right\">\n";
+          $display.= "<input type=\"submit\" name=\"edit_continue\" value=\""._("Continue")."\">&nbsp;";
+          $display.= "<input type=\"submit\" name=\"edit_cancel\" value=\""._("Cancel")."\">\n";
+          $display.= "</p>";
         }
-                               $display.= "<input type=\"submit\" name=\"edit_cancel\" value=\""._("Cancel")."\">\n";
-                               $display.= "</p>";
-                       }elseif(!isset($this->dialog->current)){
-                               $display.= "<p style=\"text-align:right\">\n";
-                               $display.= "<input type=\"submit\" name=\"edit_continue\" value=\""._("Continue")."\">&nbsp;";
-                               $display.= "<input type=\"submit\" name=\"edit_cancel\" value=\""._("Cancel")."\">\n";
-                               $display.= "</p>";
-                       }
+      }
                        return($display);
                }
                
index 3c35bf7551344762365b7bd4f852b284d96e02ad..a07c24240f40e50219970b4cf2a89e494eb67661 100644 (file)
@@ -532,6 +532,21 @@ class faiPackage extends plugin
       }
     }
   }
+
+  /* Return plugin informations for acl handling */ 
+  function plInfo()
+  {
+    return (array(  
+          "plDescription"     => _("FAI Package list"),
+          "plSelfModify"      => FALSE,
+          "plDepends"         => array("objectClass" => "FAIclass"),
+          "cn"                => _("Name"),
+          "description"       => _("Description"),
+          "FAIpackage"        => _("Packages"),
+          "FAIdebianSection"  => _("Section"),
+          "FAIinstallMethod"  => _("Install Method"),
+          "FAIdebianRelease"  => _("Release")));
+  }
 }
 
 // vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler:
index c299d6d9ae84c0aeaa75eecd33648337da85b0c0..3acf00d825b5909edaf8097e1c6a269422a89cf3 100644 (file)
@@ -478,6 +478,25 @@ class faiPartitionTable extends plugin
     }
     $this->handle_post_events("add");
   }
+
+  
+  /* Return plugin informations for acl handling */ 
+  function plInfo()
+  {
+    return (array(  
+          "plDescription"     => _("FAI partition table"),
+          "plSelfModify"      => FALSE,
+          "plDepends"         => array("objectClass" => "FAIclass"),
+          "cn"                => _("Name"),
+          "FAIpartitionType"  => _("Partition type"),
+          "FAIpartitionNr"    => _("Partition no."),
+          "FAIfsType"         => _("File system type"),
+          "FAImountPoint"     => _("Mount point"),
+          "FAIpartitionSize"  => _("Partition size"),
+          "FAImountOptions"   => _("Mount options"),
+          "FAIfsOptions"      => _("File system options"),
+          "FAIpartitionFlags" => _("Partition flags")));
+  }
 }
 
 // vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler:
index f09f4ddb3b5ff4aebb699f369fa349642bcfd9c9..ee863431416191c0c2efb2b1182c6e4a82f7bc60 100644 (file)
@@ -16,10 +16,6 @@ class faiProfile extends plugin
   /* ObjectClasses for this Object*/
   var $objectclasses    = array("top","FAIclass","FAIprofile");
 
-  /* Class name of the Ldap ObjectClass for the Sub Object */
-  var $subClass         = "FAIscriptEntry";
-  var $subClasses       = array("top","FAIclass","FAIscriptEntry");
-
   /* Specific attributes */
   var $old_cn           = "";
   var $cn               = "";       // The class name for this object
@@ -427,6 +423,20 @@ class faiProfile extends plugin
     $this->handle_object_tagging();
     show_ldap_error($ldap->get_error(), sprintf(_("Saving of FAI/profile with dn '%s' failed."),$this->dn));
   }
+
+
+  /* Return plugin informations for acl handling */ 
+  function plInfo()
+  {
+    return (array(  
+          "plDescription"     => _("FAI profile"),
+          "plSelfModify"      => FALSE,
+          "plDepends"         => array("objectClass" => "FAIclass"),
+          "cn"                => _("Name"),
+          "description"       => _("Description"),
+          "FAIclass"          => _("FAI classes")));
+  }
+
 }
 
 // vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler:
index 7f0bce31986570cead5fb307e58a24cd71ed72ec..2610db8aeb7f11680549e9a240681fedd28c07a6 100644 (file)
@@ -441,6 +441,19 @@ class faiScript extends plugin
       $this->handle_object_tagging($sub_dn, $this->gosaUnitTag);
     }
   }
+  
+  /* Return plugin informations for acl handling */ 
+  function plInfo()
+  {
+    return (array(  
+          "plDescription"     => _("FAI script"),
+          "plSelfModify"      => FALSE,
+          "plDepends"         => array("objectClass" => "FAIclass"),
+          "cn"                => _("Name"),
+          "description"       => _("Description"),
+          "FAIpriority"       => _("Script priority"),
+          "FAIscript"         => _("FAI script")));
+  }
 }
 
 // vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler:
index a9fbd7bbb04e4400d04229a9c7a866e0a5781d2b..b0fb680a86ded18912afc5046af2faf1b727d56e 100644 (file)
@@ -405,6 +405,21 @@ class faiTemplate extends plugin
       $this->handle_object_tagging($sub_dn, $this->gosaUnitTag);
     }
   }
+  
+  /* Return plugin informations for acl handling */ 
+  function plInfo()
+  {
+    return (array(  
+          "plDescription"     => _("FAI template"),
+          "plSelfModify"      => FALSE,
+          "plDepends"         => array("objectClass" => "FAIclass"),
+          "cn"                => _("Name"),
+          "description"       => _("Description"),
+          "FAItemplateFile"   => _("Template file"),
+          "FAItemplatePath"   => _("Template path"),
+          "FAIowner"          => _("File owner"),
+          "FAImode"           => _("File permissions")));
+  }
 }
 
 // vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler:
index 2656b942b83543c6873c0eac74b8347c9498f80a..09e1fb6f62d6d9258016805774a28831b78975b6 100644 (file)
@@ -373,6 +373,18 @@ class faiVariable extends plugin
       $this->handle_object_tagging($sub_dn, $this->gosaUnitTag);
     }
   }
+  
+  /* Return plugin informations for acl handling */ 
+  function plInfo()
+  {
+    return (array(  
+          "plDescription"     => _("FAI variable"),
+          "plSelfModify"      => FALSE,
+          "plDepends"         => array("objectClass" => "FAIclass"),
+          "cn"                => _("Name"),
+          "description"       => _("Description"),
+          "FAIvariableContent"=> _("Variable content")));
+  }
 }
 
 // vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler:
index 3220f56317ef9d6ef8fdf56523167333b3e0ff19..0a2a6b772b81997dc2e7363e2d143232603bbc8c 100644 (file)
@@ -7,6 +7,8 @@ class tabsHook extends tabs
   function tabsHook($config, $data, $dn)
   {
        tabs::tabs($config, $data, $dn);
+       /* Add references/acls/snapshots */
+       $this->addSpecialTabs();
   }
 
   function check()
index 7a82adcab7c1133afa9868cada502c7ea68358c9..57a5c6e96ddc67db5d2ce550f69680e6881e0931 100644 (file)
@@ -7,6 +7,9 @@ class tabsPackage extends tabs
   function tabsPackage($config, $data, $dn)
   {
        tabs::tabs($config, $data, $dn);
+
+       /* Add references/acls/snapshots */
+       $this->addSpecialTabs();
   }
 
   function check()
index 18596362b26e2d229037ea82c33b2926ac557de0..a6243aca193c8319d75ff57d6897eb3f9deac30d 100644 (file)
@@ -7,6 +7,9 @@ class tabsPartition extends tabs
   function tabsPartition($config, $data, $dn)
   {
        tabs::tabs($config, $data, $dn);
+
+       /* Add references/acls/snapshots */
+       $this->addSpecialTabs();
   }
 
   function check()
index f8a7a2a07ff294b5ad10eda8e4a73e2e1f1bbefd..a51653b2d466a9af88ae06f0397f83819af5c1ba 100644 (file)
@@ -7,6 +7,9 @@ class tabsProfile extends tabs
   function tabsProfile($config, $data, $dn)
   {
        tabs::tabs($config, $data, $dn);
+
+       /* Add references/acls/snapshots */
+       $this->addSpecialTabs();
   }
 
   function check()
index 1f51edd97e2d84be4fde68589b20d9e8b73c49ed..69ddfc9635329c68b069f6ca9eb38e4494c56ea8 100644 (file)
@@ -7,6 +7,9 @@ class tabsScript extends tabs
   function tabsScript($config, $data, $dn)
   {
        tabs::tabs($config, $data, $dn);
+
+       /* Add references/acls/snapshots */
+       $this->addSpecialTabs();
   }
 
   function check()
index 0c06e51526b66f2c03900954114eb3dce280fe3b..2b765e05d07a5d0dcc3580b63182ebb844435ad0 100644 (file)
@@ -7,6 +7,9 @@ class tabsTemplate extends tabs
   function tabsTemplate($config, $data, $dn)
   {
        tabs::tabs($config, $data, $dn);
+
+       /* Add references/acls/snapshots */
+       $this->addSpecialTabs();
   }
 
   function check()
index 3d8eb568393c78ac1e77db68c967721cf16670be..aca820a3e7d780d55668c923e6647e3ac8173ba6 100644 (file)
@@ -7,6 +7,9 @@ class tabsVariable extends tabs
   function tabsVariable($config, $data, $dn)
   {
        tabs::tabs($config, $data, $dn);
+
+       /* Add references/acls/snapshots */
+       $this->addSpecialTabs();
   }
 
   function check()