Commit 42d64c8f1c927b4bf967dad3385f7383c4677580

Authored by eduardo.praxedes
1 parent d4b9df24

Correção na Assinatura DIgital

rn/ExpedirProcedimentoRN.php
... ... @@ -1557,6 +1557,7 @@ class ExpedirProcedimentoRN extends InfraRN {
1557 1557 $objDocumentoDTO->setDblIdProcedimento($objProcedimentoDTO->getDblIdProcedimento());
1558 1558 // $objDocumentoDTO->setStrStaEditor(array(EditorRN::$TE_EDOC, EditorRN::$TE_INTERNO), InfraDTO::$OPER_IN);
1559 1559 $objDocumentoDTO->retDblIdDocumento();
  1560 + $objDocumentoDTO->retStrStaDocumento();
1560 1561 $objDocumentoDTO->retStrStaEstadoProtocolo();
1561 1562  
1562 1563 $objDocumentoRN = new DocumentoRN();
... ... @@ -1576,9 +1577,9 @@ class ExpedirProcedimentoRN extends InfraRN {
1576 1577  
1577 1578 // Se o documento não tem assinatura e não foi cancelado então
1578 1579 // cai na regra de validação
1579   - if($objAssinaturaRN->contarRN1324($objAssinaturaDTO) == 0 && $objDocumentoDTO->getStrStaEstadoProtocolo() != ProtocoloRN::$TE_DOCUMENTO_CANCELADO){
  1580 + if($objAssinaturaRN->contarRN1324($objAssinaturaDTO) == 0 && $objDocumentoDTO->getStrStaEstadoProtocolo() != ProtocoloRN::$TE_DOCUMENTO_CANCELADO && ($objDocumentoDTO->getStrStaDocumento() != DocumentoRN::$TD_EDITOR_EDOC || $objDocumentoDTO->getStrStaDocumento() != DocumentoRN::$TD_EDITOR_INTERNO) ){
1580 1581  
1581   - //$bolAssinaturaCorretas = false;
  1582 + $bolAssinaturaCorretas = false;
1582 1583 }
1583 1584 }
1584 1585 }
... ...
rn/ProcedimentoAndamentoRN.php
... ... @@ -83,7 +83,7 @@ class ProcedimentoAndamentoRN extends InfraRN {
83 83  
84 84  
85 85 // achou um registro, então atualiza o log
86   - if(!empty($objProcedimentoAndamentoDTO)) {
  86 + /* if(!empty($objProcedimentoAndamentoDTO)) {
87 87  
88 88 $objProcedimentoAndamentoDTO->setStrSituacao($strSituacao);
89 89 $objProcedimentoAndamentoDTO->setDthData(date('d/m/Y H:i:s'));
... ... @@ -91,7 +91,7 @@ class ProcedimentoAndamentoRN extends InfraRN {
91 91 $objProcedimentoAndamentoBD->alterar($objProcedimentoAndamentoDTO);
92 92 }
93 93 // Senão cadastra um novo log
94   - else {
  94 + else { */
95 95  
96 96 $objProcedimentoAndamentoDTO = new ProcedimentoAndamentoDTO();
97 97 $objProcedimentoAndamentoDTO->setStrSituacao($strSituacao);
... ... @@ -104,7 +104,7 @@ class ProcedimentoAndamentoRN extends InfraRN {
104 104 $objProcedimentoAndamentoDTO->setNumTarefa($this->numTarefa);
105 105  
106 106 $objProcedimentoAndamentoBD->cadastrar($objProcedimentoAndamentoDTO);
107   - }
  107 + // }
108 108  
109 109 $objInfraIBanco->confirmarTransacao();
110 110 }
... ...