summaryrefslogblamecommitdiffstats
path: root/application/forms/PoolClient.php
blob: 7bacae088167db051403b3535de0f05f96cdf53f (plain) (tree)






























                                                                                                              
<?php

class Application_Form_PoolClient extends Zend_Form
{
	private $clients;

    public function init()
    {
        $this->setName("addClientToPool");
		$this->setMethod('post');
		
		$clientfield = $this->createElement('select','clientID');
        $clientfield ->setLabel('Client:');
		foreach($this->clients as $c){
			$clientfield->addMultiOption($c['clientID'],$c['macadress']." - ".$c['hardwarehash']);
		}            	
		$this->addElement($clientfield);
 		
		$this->addElement('submit', 'add', array(
            'required' => false,
            'ignore'   => true,
            'label'    => 'Save',
        ));  
    }
	public function setClients($clients){
		$this->clients = $clients;
		return $this;
	}
	
}