From 3b7024f2f14d2691e97984654988b8d919f5c12e Mon Sep 17 00:00:00 2001 From: Eriksen Costa Paixão Date: Tue, 15 Jun 2010 15:05:57 +0000 Subject: [PATCH] Corrigido bug para o afastamento de servidores professores sem aulas alocadas em um quadro de horário --- ieducar/intranet/educar_servidor_afastamento_cad.php | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/ieducar/intranet/educar_servidor_afastamento_cad.php b/ieducar/intranet/educar_servidor_afastamento_cad.php index ce762f1..335f07a 100644 --- a/ieducar/intranet/educar_servidor_afastamento_cad.php +++ b/ieducar/intranet/educar_servidor_afastamento_cad.php @@ -213,6 +213,7 @@ class indice extends clsCadastro { NULL, NULL, NULL, NULL, NULL, NULL, NULL, 1, NULL); if ($lista) { + // Passa todos os valores obtidos no registro para atributos do objeto foreach ($lista as $campo => $val) { $temp = array(); @@ -386,8 +387,9 @@ class indice extends clsCadastro { return FALSE; } - $this->mensagem = "Cadastro não realizado.
"; - return FALSE; + $this->mensagem .= "Cadastro efetuado com sucesso.
"; + header("Location: educar_servidor_det.php?cod_servidor={$this->ref_cod_servidor}&ref_cod_instituicao={$this->ref_cod_instituicao}"); + die(); } @@ -416,8 +418,8 @@ class indice extends clsCadastro { $obj = new clsPmieducarServidorAfastamento($this->ref_cod_servidor, $this->sequencial, $this->ref_cod_motivo_afastamento, $this->pessoa_logada, - NULL, NULL, NULL, $this->data_retorno, unserialize($this->data_saida), 1, - $this->ref_cod_instituicao ); + NULL, NULL, NULL, $this->data_retorno, unserialize($this->data_saida), 0, + $this->ref_cod_instituicao); $editou = $obj->edita(); if ($editou) { -- libgit2 0.21.2