/**
  * Método construtor, renderiza os campos do formulário
  *
  * @return $this|void
  */
 public function init()
 {
     parent::init();
     // Tradução
     self::$oTranslate = Zend_Registry::get('Zend_Translate');
     // Url base do sistema
     self::$oBaseUrlHelper = new Zend_View_Helper_BaseUrl();
     // Configurações pado do formulário
     $this->setName('form_consulta');
     $this->setMethod(Zend_form::METHOD_POST);
     $oElm = $this->createElement('text', 'competencia_inicial', array('divspan' => '4'));
     $oElm->setLabel('Competência Inicial:');
     $oElm->setAttrib('class', 'span2 mask-competencia');
     $oElm->setAttrib('placeholder', 'Mês/Ano');
     $oElm->removeDecorator('errors');
     $this->addElement($oElm);
     $oElm = $this->createElement('text', 'competencia_final', array('divspan' => '4'));
     $oElm->setLabel('Competência Final:');
     $oElm->setAttrib('class', 'span2 mask-competencia');
     $oElm->setAttrib('placeholder', 'Mês/Ano');
     $oElm->removeDecorator('errors');
     $this->addElement($oElm);
     $oElm = $this->createElement('button', 'btn_consultar', array('label' => 'Consultar', 'class' => 'span2', 'msg-loading' => 'Aguarde...', 'buttonType' => Twitter_Bootstrap_Form_Element_Button::BUTTON_PRIMARY));
     $this->addElement($oElm);
     // Lista de elementos do formulário
     $aElementos = array('competencia_inicial', 'competencia_final', 'btn_consultar');
     // Seta o grupo de elementos
     $this->addDisplayGroup($aElementos, "consultar");
     return $this;
 }
 /**
  * Método construtor, renderiza os campos do formulário
  *
  * @return $this|void
  */
 public function init()
 {
     parent::init();
     // Tradução
     self::$oTranslate = Zend_Registry::get('Zend_Translate');
     // Url base do sistema
     self::$oBaseUrlHelper = new Zend_View_Helper_BaseUrl();
     // Configurações pado do formulário
     $this->setName('formRelatorio');
     $this->setMethod(Zend_form::METHOD_POST);
     $this->setAction('/fiscal/relatorio-nfse-periodo/consultar');
     $oElm = $this->createElement('text', 'data_nota_inicial', array('divspan' => '4'));
     $oElm->setLabel('Competência Inicial:');
     $oElm->setAttrib('class', 'span2');
     $oElm->setAttrib('placeholder', 'Dia/Mês/Ano');
     $oElm->addValidator(new Zend_Validate_StringLength(array('min' => 10, 'max' => 10)));
     $oElm->addValidator(new Zend_Validate_Date(array('format' => 'dd/MM/yyyy')));
     $oElm->setRequired(TRUE);
     $oElm->removeDecorator('errors');
     $this->addElement($oElm);
     $oElm = $this->createElement('text', 'data_nota_final', array('divspan' => '4'));
     $oElm->setLabel('Competência Final:');
     $oElm->setAttrib('class', 'span2');
     $oElm->setAttrib('placeholder', 'Dia/Mês/Ano');
     $oElm->addValidator(new Zend_Validate_StringLength(array('min' => 10, 'max' => 10)));
     $oElm->addValidator(new Zend_Validate_Date(array('format' => 'dd/MM/yyyy')));
     $oElm->setRequired(TRUE);
     $oElm->removeDecorator('errors');
     $this->addElement($oElm);
     $oElm = $this->createElement('select', 'natureza_operacao', array('divspan' => '4', 'multioptions' => array('' => 'Todos', 1 => 'Tributação no Município', 2 => 'Tributação Fora do Município')));
     $oElm->setLabel('Natureza da Operação:');
     $oElm->setAttrib('class', 'span2');
     $oElm->setRequired(FALSE);
     $oElm->removeDecorator('errors');
     $this->addElement($oElm);
     $oElm = $this->createElement('select', 's_dados_iss_retido', array('divspan' => '4', 'multioptions' => array('' => 'Todos', 1 => 'Sim', 2 => 'Não')));
     $oElm->setLabel('Subst. Tributário (Retido):');
     $oElm->setAttrib('class', 'span2');
     $oElm->setRequired(FALSE);
     $oElm->removeDecorator('errors');
     $this->addElement($oElm);
     $oElm = $this->createElement('submit', 'btn_gerar', array('divspan' => 10, 'label' => 'Gerar Relatório', 'class' => 'span2', 'msg-loading' => 'Aguarde...', 'buttonType' => Twitter_Bootstrap_Form_Element_Button::BUTTON_PRIMARY));
     $this->addElement($oElm);
     // Lista de elementos do formulário
     $aElementos = array('data_nota_inicial', 'data_nota_final', 'natureza_operacao', 's_dados_iss_retido', 'btn_gerar');
     // Seta o grupo de elementos
     $this->addDisplayGroup($aElementos, "relatorio-nfse-periodo");
     return $this;
 }
 /**
  * Método construtor, renderiza os campos do formulário
  *
  * @return $this|void
  */
 public function init()
 {
     parent::init();
     // Tradução
     self::$oTranslate = Zend_Registry::get('Zend_Translate');
     // Url base do sistema
     self::$oBaseUrlHelper = new Zend_View_Helper_BaseUrl();
     // Configurações pado do formulário
     $this->setName('formRelatorio');
     $this->setMethod(Zend_form::METHOD_POST);
     $this->setAction('/fiscal/relatorio-webservice/consulta');
     $oElm = $this->createElement('select', 'ambiente', array('divspan' => '5', 'multioptions' => array(52 => 'Produção', 51 => 'Homologação')));
     $oElm->setLabel('Ambiente:');
     $this->addElement($oElm);
     $oElm = $this->createElement('button', 'btn_gerar', array('divspan' => 5, 'label' => 'Gerar Relatório', 'class' => 'span2', 'msg-loading' => 'Aguarde...', 'buttonType' => Twitter_Bootstrap_Form_Element_Button::BUTTON_PRIMARY));
     $this->addElement($oElm);
     // Lista de elementos do formulário
     $aElementos = array('ambiente', 'btn_gerar');
     // Seta o grupo de elementos
     $this->addDisplayGroup($aElementos, "relatorio-webservice", array('fieldset' => 'Gerar Relatório'));
     return $this;
 }