From: hickert Date: Thu, 9 Aug 2007 07:30:10 +0000 (+0000) Subject: Object groups: X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=f82667447da01866055c0540b739564fb9dc6c07;p=gosa.git Object groups: Added "Startup" and "FAI Summary" tab if there is a server bundled with this group git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@7012 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/plugins/admin/ogroups/tabs_ogroups.inc b/plugins/admin/ogroups/tabs_ogroups.inc index 8fa60234b..a58d4f594 100644 --- a/plugins/admin/ogroups/tabs_ogroups.inc +++ b/plugins/admin/ogroups/tabs_ogroups.inc @@ -39,10 +39,12 @@ class ogrouptabs extends tabs } /* Remove ws tabs, if theres no ws left in the object list */ - if((!preg_match("/W/",$objects))&&(isset($this->by_object['workstartup']))){ + if((!preg_match("/W/",$objects))&&(isset($this->by_object['workservice']))){ $this->by_object['workservice']->remove_from_parent(); unset($this->by_object['workservice']); unset($this->by_name['workservice']); + } + if((!preg_match("/S/",$objects) && !preg_match("/W/",$objects))&&(isset($this->by_object['workstartup']))){ $this->by_object['workstartup']->remove_from_parent(); unset($this->by_object['workstartup']); unset($this->by_name['workstartup']); @@ -93,24 +95,21 @@ class ogrouptabs extends tabs $this->by_object['termgroup']->parent= &$this; } } - + /* Add Workstation tabs */ - if((preg_match("/W/",$objects))&&(!isset($this->by_object['workstartup']))){ - if(!isset($this->by_object['workstartup'])){ - $this->by_name['workstartup']= _("Startup"); - $this->by_object['workstartup']= new workstartup($this->config, $this->dn); - $this->by_object['workstartup']->acl = "#all#"; - $this->by_object['workstartup']->parent= &$this; - $this->by_name['workservice']= _("Devices"); - $this->by_object['workservice']= new workservice($this->config, $this->dn); - $this->by_object['workservice']->acl = "#all#"; - $this->by_object['workservice']->inheritTimeServer = false; - $this->by_object['workservice']->parent= &$this; - $this->by_name['faiSummary']= _("Summary"); - $this->by_object['faiSummary']= new faiSummaryTab($this->config, $this->dn); - $this->by_object['faiSummary']->acl = "#all#"; - $this->by_object['faiSummary']->parent= &$this; - } + if((preg_match("/W/",$objects))&&(!isset($this->by_object['workservice']))){ + $this->by_name['workservice']= _("Devices"); + $this->by_object['workservice']= new workservice($this->config, $this->dn); + $this->by_object['workservice']->inheritTimeServer = false; + $this->by_object['workservice']->parent= &$this; + } + if((preg_match("/S/",$objects) || preg_match("/W/",$objects))&&(!isset($this->by_object['workstartup']))){ + $this->by_name['workstartup']= _("Startup"); + $this->by_object['workstartup']= new workstartup($this->config, $this->dn); + $this->by_object['workstartup']->parent= &$this; + $this->by_name['faiSummary']= _("Summary"); + $this->by_object['faiSummary']= new faiSummaryTab($this->config, $this->dn); + $this->by_object['faiSummary']->parent= &$this; } /* Add application tab if user or group is member in this object group*/