Code

Added storage RDN properties.
[gosa.git] / gosa-plugins / goto / admin / applications / class_applicationGeneric.inc
index a8aa74c78081676e4ac4cf564ba6c1d0b1e157a9..bf11b1f7aba247fc43dd11fe70a9124912a42532 100644 (file)
@@ -208,8 +208,6 @@ class application extends plugin
 
   function remove_from_parent()
   {
-    restore_error_handler();
-
     /* Parse release out of object dn */
     $release = preg_replace("/".preg_quote(get_ou("applicationRDN").$this->base, '/')."$/i","",$this->dn);
     $release = preg_replace("/^cn=[^,]+,/","",$release);
@@ -432,9 +430,6 @@ class application extends plugin
     /* Check for existing application */
     $ldap= $this->config->get_ldap_link();
     $ldap->cd($this->config->current["BASE"]);
-
-    $tmp = $this->config->search("faiManagement", "CLASS",array('menu','tabs'));
-
     if($this->is_release()){
       $base = $this->parent->parent->app_release;
     }else{
@@ -513,11 +508,9 @@ class application extends plugin
     if(isset($this->parent->parent)){
       return($this->parent->parent->IsReleaseManagementActivated());
     }else{
+
       /* Check if we should enable the release selection */
-      $tmp = $this->config->search("faiManagement", "CLASS",array('menu','tabs'));
-      if(!empty($tmp)){
-        return(true);
-      }
+      return($this->config->pluginEnabled("faiManagement"));
     }
     return(FALSE);
   }
@@ -584,30 +577,42 @@ class application extends plugin
       #FIXME FAIscript seams to ununsed within this class... */
   static function plInfo()
   {
-    return (array(
-          "plShortName"   => _("Generic"),
-          "plDescription" => _("Application generic"),
-          "plSelfModify"  => FALSE,
-          "plDepends"     => array(),
-          "plPriority"    => 0,
-          "plSection"     => array("administration"),
-          "plCategory"    => array("application" => array("description"  => _("Application"),
-                                                          "objectClass"  => "gosaApplication")),
+      return (array(
+                  "plShortName"   => _("Generic"),
+                  "plDescription" => _("Application generic"),
+                  "plSelfModify"  => FALSE,
+                  "plDepends"     => array(),
+                  "plPriority"    => 0,
+                  "plSection"     => array("administration"),
+                  "plCategory"    => array("application" => array("description"  => _("Application"),
+                          "objectClass"  => "gosaApplication")),
+                  "plProperties" =>
+                  array(
+                      array(
+                          "name"          => "applicationRDN",
+                          "type"          => "rdn",
+                          "default"       => "ou=apps,",
+                          "description"   => "The 'applicationRDN' statement defines the location where new applications will be created. The default is 'ou=apps,'.",
+                          "check"         => "gosaProperty::isRdn",
+                          "migrate"       => "",
+                          "group"         => "plugin",
+                          "mandatory"     => FALSE)),
+
           "plProvidedAcls"=> array(
-            "cn"                => _("Name"),
-            "base"              => _("Base"),
-            "description"       => _("Description"),
-            "gosaApplicationExecute"  => _("Execute"),
-            "gosaApplicationName"     => _("Name"),
-            "gosaApplicationIcon"     => _("Icon"),
-            "gotoLogonScript"         => _("Script content"),
-
-            "execForGroupmembers" => _("Only executable for members"),              // G
-            "placeOnDesktop"      => _("Place icon on members desktop"),            // D
-            "placeOnKicker"       => _("Place entry in members launch bar"),        // L
-            "placeInStartmenu"    => _("Place entry in members startmenu"),         // M
-            "overwriteConfig"      => _("Replace user configuration on startup"))  // O
-            ));
+                  "cn"                => _("Name"),
+                  "base"              => _("Base"),
+                  "description"       => _("Description"),
+                  "gosaApplicationExecute"  => _("Execute"),
+                  "gosaApplicationName"     => _("Name"),
+                  "gosaApplicationIcon"     => _("Icon"),
+                  "gotoLogonScript"         => _("Script content"),
+
+                  "execForGroupmembers" => _("Only executable for members"),              // G
+                  "placeOnDesktop"      => _("Place icon on members desktop"),            // D
+                  "placeOnKicker"       => _("Place entry in members launch bar"),        // L
+                  "placeInStartmenu"    => _("Place entry in members startmenu"),         // M
+                  "overwriteConfig"      => _("Replace user configuration on startup"))  // O
+              ));
   }
 }
 // vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler: