<?

class Atendimento_Form_Prioridade extends Agro_Form {
	
	public function init() {
		
		$this->addElement('hidden', 'id', array('decorators' => $this->buttonDecorator));

		$this->addElement('text', 'ds_chave', array(
			'decorators' => $this->elementDecorator,
			'label' => 'Chave',
			'required' => true,
			'maxlength' => 50,
			'size' => 30
		));
		
		$this->addElement('text', 'ds_descricao', array(
			'decorators' => $this->elementDecorator,
			'label' => 'Descrição',
			'required' => true,
			'maxlength' => 200,
			'size' => 50
		));
		
		$this->save = $this->createElement('button', 'salvar', array('type'=>'submit'));
		$this->save->setDecorators($this->buttonDecorator);
		$this->save->setDecorators($this->buttonDecorator);
		$this->save->setLabel('Salvar');
		$this->addElement($this->save);
		
		$this->cancel = $this->createElement('button', 'cancelar', array('onclick'=>"location.href='/atendimento/prioridade'"));
		$this->cancel->setDecorators($this->buttonDecorator);
		$this->cancel->setLabel('Cancelar');
		$this->addElement($this->cancel);
	}
}