From: hickert Date: Tue, 12 Jan 2010 11:48:18 +0000 (+0000) Subject: Added missing check X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=42d5e7b590a0ef1678d062c0bf996fea54a9b76c;p=gosa.git Added missing check git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@15155 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-plugins/systems/admin/systems/class_filterSYSTEMS.inc b/gosa-plugins/systems/admin/systems/class_filterSYSTEMS.inc index 4489bdeba..1b536bff5 100644 --- a/gosa-plugins/systems/admin/systems/class_filterSYSTEMS.inc +++ b/gosa-plugins/systems/admin/systems/class_filterSYSTEMS.inc @@ -6,6 +6,9 @@ class filterSYSTEMS { { $ui = get_userinfo(); + // Check whether the arp handling active or not + $arp_handling_active = ($this->config->search("ArpNewDevice","CLASS",array('tabs')) != "") + $entries = filterLDAP::query($base, $scope, $filter, $attributes, $category, $objectStorage); foreach($entries as $key => $entry){ if(preg_match("/".preg_quote(get_ou('systemIncomingRDN'),'/')."/i", $entry['dn'])){ @@ -17,7 +20,9 @@ class filterSYSTEMS { }elseif(in_array('gotoTerminal', $entry['objectClass'])){ $entries[$key]['objectClass'][] = 'FAKE_OC_NewTerminal'; $entries[$key]['cn'][0].= " ("._("New terminal").")"; - }elseif(in_array('GOhard', $entry['objectClass']) && !isset($entry['gotoMode'][0])){ + }elseif($arp_handling_active && + in_array('GOhard', $entry['objectClass']) && + !isset($entry['gotoMode'][0])){ $entries[$key]['objectClass'][] = 'FAKE_OC_ArpNewDevice'; $entries[$key]['cn'][0].= " ("._("New unknown device").")"; }elseif(in_array('GOhard', $entry['objectClass'])){ diff --git a/gosa-plugins/systems/admin/systems/class_systemManagement.inc b/gosa-plugins/systems/admin/systems/class_systemManagement.inc index 97219fb73..1ba0f53aa 100644 --- a/gosa-plugins/systems/admin/systems/class_systemManagement.inc +++ b/gosa-plugins/systems/admin/systems/class_systemManagement.inc @@ -73,7 +73,6 @@ class systemManagement extends management protected $objectName = "system"; protected $objectInfo = array(); protected $opsi = NULL; - protected $arp_handling_active = FALSE; protected $activationQueue = array(); function __construct($config,$ui) @@ -139,11 +138,6 @@ class systemManagement extends management $this->snapHandler = new SnapshotHandler($this->config); } - // Check whether the arp handling active or not - if($this->config->search("ArpNewDevice","CLASS",array('tabs')) != ""){ - $this->arp_handling_active = TRUE; - } - // Check if we are able to communicate with the GOsa supprot daemon if(class_available("gosaSupportDaemon")){ $o = new gosaSupportDaemon();