From: hickert Date: Mon, 11 Sep 2006 07:37:49 +0000 (+0000) Subject: Added some new *must* fields for hotplugs X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=621ceac3208438274df5037820f1a9b0ec3e707d;p=gosa.git Added some new *must* fields for hotplugs git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@4637 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/plugins/personal/environment/class_hotplugDialog.inc b/plugins/personal/environment/class_hotplugDialog.inc index 61989f959..8bf8ae298 100644 --- a/plugins/personal/environment/class_hotplugDialog.inc +++ b/plugins/personal/environment/class_hotplugDialog.inc @@ -130,13 +130,13 @@ class hotplugDialog extends plugin $message[]=_("Invalid character in description. Please specify a valid description."); } - if(preg_match("/[\|\*]/i",$this->HOT_id)){ + if(empty($this->HOT_id) || preg_match("/[\|\*]/i",$this->HOT_id)){ $message[]=_("Please specify a valid id."); } - if(!$this->is_2byteHex($this->HOT_vendor)){ + if(empty($this->HOT_vendor) || !$this->is_2byteHex($this->HOT_vendor)){ $message[]=_("Please specify a valid vendor id. (2 byte hex like '0xFFFF')"); } - if(!$this->is_2byteHex($this->HOT_produkt)){ + if(empty($this->HOT_produkt) || !$this->is_2byteHex($this->HOT_produkt)){ $message[]=_("Please specify a valid product id. (2 byte hex like '0xFFFF')"); } $ldap = $this->config->get_ldap_link(); diff --git a/plugins/personal/environment/hotplugDialogNew.tpl b/plugins/personal/environment/hotplugDialogNew.tpl index bd5d25531..312067824 100644 --- a/plugins/personal/environment/hotplugDialogNew.tpl +++ b/plugins/personal/environment/hotplugDialogNew.tpl @@ -25,7 +25,7 @@ - - -
+ {$must} @@ -33,14 +33,14 @@  
+ {$must}
+ {$must}