Code

Replaced some search_config calls with config->search
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Fri, 21 Sep 2007 13:22:40 +0000 (13:22 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Fri, 21 Sep 2007 13:22:40 +0000 (13:22 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@7375 594d385d-05f5-0310-b6e9-bd551577e9d8

plugins/admin/fai/class_divListFai.inc
plugins/admin/fai/class_faiManagement.inc
plugins/admin/fai/class_faiSummaryTab.inc
plugins/admin/groups/class_groupApplication.inc
plugins/admin/groups/class_groupGeneric.inc
plugins/admin/groups/class_groupManagement.inc
plugins/admin/mimetypes/tabs_mimetypes.inc

index 860be1ac2e20b1db59d76de91b71573c6ffb7fa4..7b66f47b8eb7a8494b968d0142068482aac028b7 100644 (file)
@@ -94,8 +94,8 @@ class divListFai extends MultiSelectWindow
       /* Check if there are post commands available for fai management.
        * If not, grey out freeze/branch and release remove buttons.
        */
-      $r = ("" != search_config($this->config->data,"faiManagement","POSTREMOVE"));
-      $c = ("" != search_config($this->config->data,"faiManagement","POSTCREATE"));
+      $r = $this->config->search("faiManagement", "POSTREMOVE");
+      $c = $this->config->search("faiManagement", "POSTCREATE");
 
       $smarty = get_smarty();
       $smarty->assign("allow_create", $c);
index 3ad80f9a58f4056db9dd17446999ce5581f771c6..61e9c5241045898d74787c4db84630936b1ee616 100644 (file)
@@ -366,7 +366,7 @@ class faiManagement extends plugin
       /* Check if we have a post remove method configured
        *  else skip this operation. (Skip:Button in the ui should be disabled in this case too)
        */
-      if("" != search_config($this->config->data,"faiManagement","POSTREMOVE")){
+      if("" != $this->config->search("faiManagement", "POSTREMOVE",array('tabs'))){
 
         /* Load permissions for selected 'dn' and check if
            we're allowed to remove this 'dn' */
@@ -391,7 +391,7 @@ class faiManagement extends plugin
       /* Check if we have a post remove method configured
        *  else skip this operation. (Skip:Button in the ui should be disabled in this case too)
        */
-      if("" != search_config($this->config->data,"faiManagement","POSTREMOVE")){
+      if("" != $this->config->search("faiManagement", "POSTREMOVE",array('tabs'))){
 
         $bb =  $this->DivListFai->selectedBranch;
         if(!isset($ldap)){
@@ -591,7 +591,7 @@ class faiManagement extends plugin
     /* Check if we have a post create method configured
      *  else skip this operation. (Skip:Button in the ui should be disabled in this case too)
      */
-    if("" != search_config($this->config->data,"faiManagement","POSTCREATE")){
+    if("" != $this->config->search("faiManagement", "POSTCREATE",array('tabs'))){
       if(($s_action == "branch_branch")||($this->dispNewBranch)){
         $this->dispNewBranch=true;
         $smarty->assign("iframe",false);
@@ -608,7 +608,7 @@ class faiManagement extends plugin
     /* Check if we have a post create method configured
      *  else skip this operation. (Skip:Button in the ui should be disabled in this case too)
      */
-    if("" != search_config($this->config->data,"faiManagement","POSTCREATE")){
+    if("" != $this->config->search("faiManagement", "POSTCREATE",array('tabs'))){
       if(($s_action == "freeze_branch")||($this->dispNewFreeze)){
         $this->dispNewFreeze = true;
         $smarty->assign("iframe",false);
index a6fa6dab02d61b752bd1448ac73c994da6e6badd..0ba1257a6a7d804a65ccf705a37af573f2d99c67 100644 (file)
@@ -170,7 +170,7 @@ class faiSummaryTab extends plugin{
   {
 
     /* Skip this if fai is deactivated */
-    $tmp = search_config($this->config->data,"faiManagement","CLASS");
+    $tmp = $this->config->search("faiManagement", "CLASS");
     if(empty($tmp)){
       $str = "<h2>"._("You can't use this plugin until FAI is activated.")."</h2>";
       return $str;
index 5d9ab683a6815ec072cf45a82a20c64b7d976fb9..b4312c7de15a91ecbe8090c90d256113ca1cfeab 100644 (file)
@@ -45,7 +45,7 @@ class appgroup extends plugin
   {
    
     /* Check if we have relase mangement enabled and prepare group application for release management */ 
-    $tmp = search_config($config->data,"faiManagement","CLASS");
+    $tmp = $this->config->search("faiManagement", "CLASS");
     if(!empty($tmp)){
       $this->enableReleaseManagement = true;
       $this->objectclasses  [] = "FAIreleaseTag";
@@ -539,7 +539,7 @@ class appgroup extends plugin
           $ldap= $this->config->get_ldap_link();
 
           /* Check if we have release management enabled */
-          $tmp = search_config($this->config->data,"faiManagement","CLASS");
+          $tmp = $this->config->search("faiManagement", "CLASS");
           if(!empty($tmp)){
     
             /* Get application parameter from ldap */
@@ -1015,7 +1015,7 @@ class appgroup extends plugin
     $this->apps= array();
 
     /* Special handling for release managed apps */
-    $tmp = search_config($this->config->data,"faiManagement","CLASS");
+    $tmp = $this->config->search("faiManagement", "CLASS");
     if(!empty($tmp) && count($this->Releases)){
       $this->enableReleaseManagement = true;
 
@@ -1071,7 +1071,7 @@ class appgroup extends plugin
 
     /* Get all apps ... */
     $res = get_list("objectClass=gosaApplication","application",$this->config->current['BASE'],array("gosaApplicationParameter","cn"),GL_SUBSEARCH); 
-    $tmp = search_config($this->config->data,"faiManagement","CLASS");
+    $tmp = $this->config->search("faiManagement", "CLASS");
     $this->AllAppsForRelease = array();
     if(!empty($tmp)){
       $tmp = array_flip($this->Releases);
index 36b46eae9c7b7410bd011d73a29c11c70ede96fc..b8c214933d925c0894b699fc17ec1783b84765d2 100644 (file)
@@ -264,13 +264,13 @@ class group extends plugin
       $smarty->assign("samba3", "");
     }
 
-    if(search_config($this->config->data['MENU'], "nagiosaccount", "CLASS")){
+    if($this->config->search("nagiosaccount", "CLASS",array('menu'))){
       $smarty->assign("nagios",true);
     }else{
       $smarty->assign("nagios",false);
     }
     
-    if(search_config($this->config->data['MENU'], "phoneAccount", "CLASS")){
+    if($this->config->search("phoneAccount", "CLASS",array('menu'))){
       $smarty->assign("pickupGroup",true);
     }else{
       $smarty->assign("pickupGroup",false);
index 67cd7091cc908c6869ba3b45be75a8acfc4b974b..59d189c6aba564023afd36f1ff67606fa259e676 100644 (file)
@@ -561,7 +561,7 @@ class groupManagement extends plugin
     $attrs = array("cn", "description", "gidNumber", "objectClass");
  
     /* If subsearch is activated search for subobjects too */
-    $tmp = search_config($this->config->data,"faiManagement","CLASS");
+    $tmp = $this->config->search("faiManagement", "CLASS");
     if(!empty($tmp)){
       $attrs [] = "FAIrelease";
     }
index 66f1c01feecb1e8399928a11cf5daabfe564c776..379ae57fd18552f08c94130d720f4b37ae5909d5 100755 (executable)
@@ -26,7 +26,6 @@ class mimetabs extends tabs
 
     /* Check for new 'dn', in order to propagate the
        'dn' to all plugins */
-    $tmp = search_config($this->config->data,"faiManagement","CLASS");
     $tmp = $this->config->search("faiManagement", "CLASS");
 
     if((!empty($tmp)) && (isset($_SESSION['mimefilter']['release']))){