From c6d672e82a59d91fb5301c274a8b430bc55c4d08 Mon Sep 17 00:00:00 2001 From: hickert Date: Mon, 4 Jun 2007 10:23:45 +0000 Subject: [PATCH] Applied patch from 2.5 Revision: 6518 git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@6530 594d385d-05f5-0310-b6e9-bd551577e9d8 --- plugins/personal/environment/class_environment.inc | 12 ++++++++---- plugins/personal/environment/environment.tpl | 4 ++-- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/plugins/personal/environment/class_environment.inc b/plugins/personal/environment/class_environment.inc index d0ffa9484..64aabc4df 100644 --- a/plugins/personal/environment/class_environment.inc +++ b/plugins/personal/environment/class_environment.inc @@ -715,9 +715,9 @@ class environment extends plugin } /* We have to delete the selected hotplug from the list*/ - if((isset($_POST['gotoHotplugDeviceDel']))&&(isset($_POST['gotoHotplugDevice'])) && $this->acl_is_writeable("gotoHotplugDevice")){ + if((isset($_POST['gotoHotplugDeviceDel']))&&(isset($_POST['gotoHotplugDevice_post'])) && $this->acl_is_writeable("gotoHotplugDevice")){ if($this->acl_is_writeable("gotoHotplugDevice")){ - foreach($_POST['gotoHotplugDevice'] as $name){ + foreach($_POST['gotoHotplugDevice_post'] as $name){ unset($this->gotoHotplugDevices[$name]); } } @@ -1143,8 +1143,12 @@ class environment extends plugin /* Prepare HotPlug devices */ $this->attrs['gotoHotplugDevice'] = array(); foreach($this->gotoHotplugDevices as $name => $device){ - $this->attrs['gotoHotplugDevice'][] = $device['name']."|".$device['description']."|".$device['id']. - "|".$device['produkt']."|".$device['vendor']; + + $tmp= $device['name']."|".$device['description']."|".$device['id']; + if (isset($device['produkt']) && isset($device['vendor'])){ + $tmp.= "|".$device['produkt']."|".$device['vendor']; + } + $this->attrs['gotoHotplugDevice'][]= $tmp; } /* Prepare LogonScripts */ diff --git a/plugins/personal/environment/environment.tpl b/plugins/personal/environment/environment.tpl index 2763b7e4f..47131474d 100644 --- a/plugins/personal/environment/environment.tpl +++ b/plugins/personal/environment/environment.tpl @@ -200,13 +200,13 @@

  - +

{render acl=$gotoHotplugDeviceACL} - {html_options values=$gotoHotplugDeviceKeys output=$gotoHotplugDevices} -- 2.30.2