From aed012ae09ec5c404acdc20240fe7cbd8fe5a04c Mon Sep 17 00:00:00 2001 From: Simon Date: Mon, 21 Mar 2011 15:11:22 +0100 Subject: fbgui: serialnumber von bootmedium wird berücksichtigt zur Gruppenfindung --- application/modules/fbgui/controllers/IndexController.php | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) (limited to 'application') diff --git a/application/modules/fbgui/controllers/IndexController.php b/application/modules/fbgui/controllers/IndexController.php index 12514c5..6c4a542 100644 --- a/application/modules/fbgui/controllers/IndexController.php +++ b/application/modules/fbgui/controllers/IndexController.php @@ -28,8 +28,17 @@ class Fbgui_IndexController extends Zend_Controller_Action $bootisomapper = new Application_Model_BootIsoMapper(); $bootiso = new Application_Model_BootIso(); - $bootisomapper->find($_POST['bootisoID'],$bootiso); - $groupID = $bootiso->getGroupID(); + if(isset($_POST['bootisoID'])){ + $bootisomapper->find($_POST['bootisoID'],$bootiso); + $groupID = $bootiso->getGroupID(); + } + elseif(isset($_POST['serialnumber'])){ + $results = $bootisomapper->findBy('serialnumber',$_POST['serialnumber']); + $bootiso->setOptions($results[0]); + $bootiso->setID($result[0]['bootisoID']); + $groupID = $bootiso->getGroupID(); + + } $client = new Application_Model_Client(); $client->setMacadress($_POST['mac']); -- cgit v1.2.3-55-g7522