Commit 3b7024f2f14d2691e97984654988b8d919f5c12e
1 parent
41c2cdff
Exists in
master
Corrigido bug para o afastamento de servidores professores sem aulas alocadas em…
… um quadro de horário
Showing
1 changed file
with
6 additions
and
4 deletions
Show diff stats
ieducar/intranet/educar_servidor_afastamento_cad.php
... | ... | @@ -213,6 +213,7 @@ class indice extends clsCadastro { |
213 | 213 | NULL, NULL, NULL, NULL, NULL, NULL, NULL, 1, NULL); |
214 | 214 | |
215 | 215 | if ($lista) { |
216 | + | |
216 | 217 | // Passa todos os valores obtidos no registro para atributos do objeto |
217 | 218 | foreach ($lista as $campo => $val) { |
218 | 219 | $temp = array(); |
... | ... | @@ -386,8 +387,9 @@ class indice extends clsCadastro { |
386 | 387 | return FALSE; |
387 | 388 | } |
388 | 389 | |
389 | - $this->mensagem = "Cadastro não realizado.<br>"; | |
390 | - return FALSE; | |
390 | + $this->mensagem .= "Cadastro efetuado com sucesso.<br>"; | |
391 | + header("Location: educar_servidor_det.php?cod_servidor={$this->ref_cod_servidor}&ref_cod_instituicao={$this->ref_cod_instituicao}"); | |
392 | + die(); | |
391 | 393 | } |
392 | 394 | |
393 | 395 | |
... | ... | @@ -416,8 +418,8 @@ class indice extends clsCadastro { |
416 | 418 | |
417 | 419 | $obj = new clsPmieducarServidorAfastamento($this->ref_cod_servidor, |
418 | 420 | $this->sequencial, $this->ref_cod_motivo_afastamento, $this->pessoa_logada, |
419 | - NULL, NULL, NULL, $this->data_retorno, unserialize($this->data_saida), 1, | |
420 | - $this->ref_cod_instituicao ); | |
421 | + NULL, NULL, NULL, $this->data_retorno, unserialize($this->data_saida), 0, | |
422 | + $this->ref_cod_instituicao); | |
421 | 423 | |
422 | 424 | $editou = $obj->edita(); |
423 | 425 | if ($editou) { | ... | ... |