From c14275602b07f2d904a9ef7eb2752609bdfffd10 Mon Sep 17 00:00:00 2001 From: hickert Date: Fri, 15 Aug 2008 07:20:05 +0000 Subject: [PATCH] Fixed device checks. -Fixed devId checks to force the input of a valid serial git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@12217 594d385d-05f5-0310-b6e9-bd551577e9d8 --- gosa-plugins/goto/admin/devices/class_deviceGeneric.inc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/gosa-plugins/goto/admin/devices/class_deviceGeneric.inc b/gosa-plugins/goto/admin/devices/class_deviceGeneric.inc index 59295598a..8d7ce9394 100644 --- a/gosa-plugins/goto/admin/devices/class_deviceGeneric.inc +++ b/gosa-plugins/goto/admin/devices/class_deviceGeneric.inc @@ -96,6 +96,8 @@ class deviceGeneric extends plugin /* Skip serial check if vendor and product id are given */ if(preg_match("/^\s+$/i",$this->devID)){ $message[]= msgPool::invalid(_("iSerial"),"","01234"); + }elseif(empty($this->devID) && $this->devID!="0"){ + $message[]= msgPool::required(_("iSerial")); } if(empty($this->serial) || !$this->is_2byteHex($this->serial)){ $message[]= msgPool::invalid(_("Serial"),"","","0x1234"); -- 2.30.2