public function validarServicoAction()
 {
     $id = $this->_getParam('id', 0);
     $servico = new Application_Model_DbTable_Servico();
     $this->view->validarServico = 0;
     $this->view->ID_SERVICO = 0;
     if ($this->getRequest()->isPost()) {
         $del = $this->getRequest()->getPost('del');
         if ($del == 'Sim') {
             //Zend_Registry::get('logger')->log("teste2222", Zend_Log::INFO);
             try {
                 $id = $this->getRequest()->getPost('ID_SERVICO');
                 $novoServico = $servico->getServicoAutomatico($id);
                 // Zend_Registry::get('logger')->log($novoServico["DS_SERVICO"], Zend_Log::INFO);
                 //Zend_Registry::get('logger')->log($novoServico, Zend_Log::INFO);
                 $this->view->ID_SERVICO = $servico->addServico($novoServico["DS_SERVICO"], $novoServico["FK_OPERADOR"], $novoServico["NR_CARGA_HORARIA"], $novoServico["FK_TIPO_SERVICO"], $novoServico["DT_SERVICO"], $novoServico["FK_PROJETO"], 0);
                 $servico->updateValidarServico($id, $this->view->ID_SERVICO);
                 $this->view->mensagem = "Serviço criado com sucesso";
                 $this->view->erro = 0;
                 $this->view->validarServico = 1;
             } catch (Exception $e) {
                 $this->view->mensagem = $e->getCode() . "Erro ao criar serviço";
                 $this->view->erro = 1;
                 $this->view->mensagemExcecao = $e->getMessage();
             }
         } else {
             $this->_redirect($this->session->urlAnterior, array('prependBase' => false));
             exit;
         }
     }
     $this->view->servico = $servico->getServico($id);
 }