<?php

class Sinistro_Form_AgendamentoRevistoria extends Agro_Form {
	
	public $turno_vistoria_final;
	public $dt_vistoria_final;
	public $btt_agendar;
	public $btt_fechar;
	
	public function init() {
		
		$options = array(''=>'','M'=>'Manhã','T'=>'Tarde','N'=>'Noite');
		$this->turno_revistoria = $this->createElement('select', 'turno_revistoria');
        $this->turno_revistoria->setDecorators($this->elementDecorator);
        $this->turno_revistoria->setRequired(true);
        $this->turno_revistoria->setAttrib('id', 'turno_revistoria');
        $this->turno_revistoria->setLabel('Turno');
        $this->turno_revistoria->setMultiOptions($options);
        $this->addElement($this->turno_revistoria);
        
        $this->dt_revistoria = $this->createElement('text', 'dt_revistoria');
		$this->dt_revistoria->setDecorators($this->elementDecorator);
		$this->dt_revistoria->setRequired(true);
		$this->dt_revistoria->setAttrib('size','11');
		$this->dt_revistoria->setAttrib('maxlength', '10');
		$this->dt_revistoria->setAttrib('id', 'dt_revistoria');
		$this->dt_revistoria->setAttrib('class', 'data');
		$this->dt_revistoria->setAttrib('readonly', 'readonly');
		$this->dt_revistoria->setLabel('Dt. Vistoria');
		$this->addElement($this->dt_revistoria);
		
		$this->btt_agendar = $this->createElement('button', 'saveAgRevistoria', array('type'=>'button'));
		$this->btt_agendar->setAttrib('id', 'saveAgRevistoria');
		$this->btt_agendar->setDecorators($this->buttonDecorator);
		$this->btt_agendar->setLabel('Agendar Revistoria');
		$this->addElement($this->btt_agendar);
		
		$this->btt_fechar = $this->createElement('button', 'closeWindowAgRevistoria', array('type'=>'button'));
		$this->btt_fechar->setAttrib('id', 'closeWindowAgRevistoria');
		$this->btt_fechar->setDecorators($this->buttonDecorator);
		$this->btt_fechar->setLabel('Fechar');
		$this->addElement($this->btt_fechar);
	}
}