Commit 35b82fa5e2b81e76022ff2ce4fd01d67d47d312c

Authored by Rafael Ferreira
1 parent 3e4a6207
Exists in master

Corrigindo verificação de Parâmetros no método ListarDocumentos

Showing 1 changed file with 49 additions and 40 deletions   Show diff stats
1 <? 1 <?
2 /** 2 /**
3 -* CONTROLADORIA GERAL DA UNIÃO 3 +* CONTROLADORIA GERAL DA UNIÃO
4 * 4 *
5 * 25/06/2015 - criado por Rafael Leandro Ferreira 5 * 25/06/2015 - criado por Rafael Leandro Ferreira
6 * 6 *
@@ -31,23 +31,22 @@ class CguRN extends InfraRN { @@ -31,23 +31,22 @@ class CguRN extends InfraRN {
31 $objUnidadeDTO = $objWSEntradaListarDocumentoDTO->getObjUnidadeDTO(); 31 $objUnidadeDTO = $objWSEntradaListarDocumentoDTO->getObjUnidadeDTO();
32 32
33 if (!InfraUtil::isBolSinalizadorValido($objWSEntradaListarDocumentoDTO->getStrSinRetornarAndamentoGeracao())) { 33 if (!InfraUtil::isBolSinalizadorValido($objWSEntradaListarDocumentoDTO->getStrSinRetornarAndamentoGeracao())) {
34 - $objInfraException->adicionarValidacao('Sinalizador de retorno para andamento de geração inválido.'); 34 + $objInfraException->adicionarValidacao('Sinalizador de retorno para andamento de geração inválido.');
35 } 35 }
36 36
37 if (!InfraUtil::isBolSinalizadorValido($objWSEntradaListarDocumentoDTO->getStrSinRetornarAssinaturas())) { 37 if (!InfraUtil::isBolSinalizadorValido($objWSEntradaListarDocumentoDTO->getStrSinRetornarAssinaturas())) {
38 - $objInfraException->adicionarValidacao('Sinalizador de retorno para assinaturas inválido.'); 38 + $objInfraException->adicionarValidacao('Sinalizador de retorno para assinaturas inválido.');
39 } 39 }
40 40
41 if (!InfraUtil::isBolSinalizadorValido($objWSEntradaListarDocumentoDTO->getStrSinRetornarPublicacao())) { 41 if (!InfraUtil::isBolSinalizadorValido($objWSEntradaListarDocumentoDTO->getStrSinRetornarPublicacao())) {
42 - $objInfraException->adicionarValidacao('Sinalizador de retorno para publicação inválido.'); 42 + $objInfraException->adicionarValidacao('Sinalizador de retorno para publicação inválido.');
43 } 43 }
44 44
45 if (!InfraUtil::isBolSinalizadorValido($objWSEntradaListarDocumentoDTO->getStrSinRetornarDestinatarios())) { 45 if (!InfraUtil::isBolSinalizadorValido($objWSEntradaListarDocumentoDTO->getStrSinRetornarDestinatarios())) {
46 - $objInfraException->adicionarValidacao('Sinalizador de retorno para destinatários inválido.'); 46 + $objInfraException->adicionarValidacao('Sinalizador de retorno para destinatários inválido.');
47 } 47 }
48 48
49 -  
50 - $dto = new DocumentoDTO(); 49 + $dto = new DocumentoDTO();
51 $dto->retDblIdDocumento(); 50 $dto->retDblIdDocumento();
52 $dto->retDblIdProcedimento(); 51 $dto->retDblIdProcedimento();
53 $dto->retStrProtocoloDocumentoFormatado(); 52 $dto->retStrProtocoloDocumentoFormatado();
@@ -59,7 +58,8 @@ class CguRN extends InfraRN { @@ -59,7 +58,8 @@ class CguRN extends InfraRN {
59 $dto->retDtaGeracaoProtocolo(); 58 $dto->retDtaGeracaoProtocolo();
60 $dto->retStrStaProtocoloProtocolo(); 59 $dto->retStrStaProtocoloProtocolo();
61 $dto->retStrSinBloqueado(); 60 $dto->retStrSinBloqueado();
62 - 61 + $dto->retStrStaDocumento();
  62 +
63 $dto->retNumIdUnidadeGeradoraProtocolo(); 63 $dto->retNumIdUnidadeGeradoraProtocolo();
64 $dto->retStrSiglaUnidadeGeradoraProtocolo(); 64 $dto->retStrSiglaUnidadeGeradoraProtocolo();
65 $dto->retStrDescricaoUnidadeGeradoraProtocolo(); 65 $dto->retStrDescricaoUnidadeGeradoraProtocolo();
@@ -68,6 +68,15 @@ class CguRN extends InfraRN { @@ -68,6 +68,15 @@ class CguRN extends InfraRN {
68 68
69 if ($objDocumentoDTO!='') { 69 if ($objDocumentoDTO!='') {
70 70
  71 + if ($objDocumentoDTO->getStrProtocoloDocumentoFormatado()==''
  72 + && $objDocumentoDTO->getStrProtocoloProcedimentoFormatado() ==''
  73 + && $objDocumentoDTO->getStrNumero()==''
  74 + && $objDocumentoDTO->getNumIdSerie()=='') {
  75 +
  76 + $objInfraException->lancarValidacao('É necessário informar ao menos um dos parâmetros da pesquisa.');
  77 +
  78 + }
  79 +
71 if ($objDocumentoDTO->getStrProtocoloDocumentoFormatado()!='') { 80 if ($objDocumentoDTO->getStrProtocoloDocumentoFormatado()!='') {
72 $dto->setStrProtocoloDocumentoFormatadoPesquisa($objDocumentoDTO->getStrProtocoloDocumentoFormatado()); 81 $dto->setStrProtocoloDocumentoFormatadoPesquisa($objDocumentoDTO->getStrProtocoloDocumentoFormatado());
73 } 82 }
@@ -107,7 +116,7 @@ class CguRN extends InfraRN { @@ -107,7 +116,7 @@ class CguRN extends InfraRN {
107 $arrDto = $objDocumentoRN->listarRN0008($dto); 116 $arrDto = $objDocumentoRN->listarRN0008($dto);
108 117
109 if ($arrDto==null){ 118 if ($arrDto==null){
110 - $objInfraException->lancarValidacao('Nenhum documento encontrado com os parâmetros informados.'); 119 + $objInfraException->lancarValidacao('Nenhum documento encontrado com os parâmetros informados.');
111 } 120 }
112 121
113 $i = 0; 122 $i = 0;
@@ -128,7 +137,7 @@ class CguRN extends InfraRN { @@ -128,7 +137,7 @@ class CguRN extends InfraRN {
128 137
129 $objProtocoloRN = new ProtocoloRN(); 138 $objProtocoloRN = new ProtocoloRN();
130 if (count($objProtocoloRN->pesquisarRN0967($objPesquisaProtocoloDTO)) == 0) { 139 if (count($objProtocoloRN->pesquisarRN0967($objPesquisaProtocoloDTO)) == 0) {
131 - $objInfraException->lancarValidacao('Unidade [' . $objUnidadeDTO->getStrSigla() . '] não possui acesso ao documento [' . $objDocumentoDTO->getStrProtocoloDocumentoFormatado() . '].'); 140 + $objInfraException->lancarValidacao('Unidade [' . $objUnidadeDTO->getStrSigla() . '] não possui acesso ao documento [' . $objDocumentoDTO->getStrProtocoloDocumentoFormatado() . '].');
132 } 141 }
133 }*/ 142 }*/
134 143
@@ -153,16 +162,16 @@ class CguRN extends InfraRN { @@ -153,16 +162,16 @@ class CguRN extends InfraRN {
153 $objOperacaoServicoRN = new OperacaoServicoRN(); 162 $objOperacaoServicoRN = new OperacaoServicoRN();
154 if ($objOperacaoServicoRN->contar($objOperacaoServicoDTO) == 0) { 163 if ($objOperacaoServicoRN->contar($objOperacaoServicoDTO) == 0) {
155 if ($objUnidadeDTO == null) { 164 if ($objUnidadeDTO == null) {
156 - $objInfraException->lancarValidacao('Nenhum serviço configurado para consulta deste documento [' . $objDocumentoDTO->getStrProtocoloDocumentoFormatado() . '] pelo Serviço [' . $objServicoDTO->getStrIdentificacao() . '].'); 165 + $objInfraException->lancarValidacao('Nenhum serviço configurado para consulta deste documento [' . $objDocumentoDTO->getStrProtocoloDocumentoFormatado() . '] pelo Serviço [' . $objServicoDTO->getStrIdentificacao() . '].');
157 } else { 166 } else {
158 - $objInfraException->lancarValidacao('Nenhum serviço configurado para consulta deste documento [' . $objDocumentoDTO->getStrProtocoloDocumentoFormatado() . '] na unidade [' . $objUnidadeDTO->getStrSigla() . '] pelo Serviço [' . $objServicoDTO->getStrIdentificacao() . '].'); 167 + $objInfraException->lancarValidacao('Nenhum serviço configurado para consulta deste documento [' . $objDocumentoDTO->getStrProtocoloDocumentoFormatado() . '] na unidade [' . $objUnidadeDTO->getStrSigla() . '] pelo Serviço [' . $objServicoDTO->getStrIdentificacao() . '].');
159 } 168 }
160 169
161 } 170 }
162 171
163 $objInfraException->lancarValidacoes(); 172 $objInfraException->lancarValidacoes();
164 173
165 - //verifica se o usuário já tem acesso ao processo 174 + //verifica se o usuário já tem acesso ao processo
166 $objAcessoExternoDTO = new AcessoExternoDTO(); 175 $objAcessoExternoDTO = new AcessoExternoDTO();
167 $objAcessoExternoDTO->retNumIdAcessoExterno(); 176 $objAcessoExternoDTO->retNumIdAcessoExterno();
168 $objAcessoExternoDTO->setDblIdProtocoloAtividade($objDocumentoDTO->getDblIdProcedimento()); 177 $objAcessoExternoDTO->setDblIdProtocoloAtividade($objDocumentoDTO->getDblIdProcedimento());
@@ -293,7 +302,7 @@ class CguRN extends InfraRN { @@ -293,7 +302,7 @@ class CguRN extends InfraRN {
293 return $arrObjWSRetornoConsultarDocumentoDTO; 302 return $arrObjWSRetornoConsultarDocumentoDTO;
294 303
295 }catch(Exception $e){ 304 }catch(Exception $e){
296 - throw new InfraException('Erro no serviço de consulta de documento.',$e); 305 + throw new InfraException('Erro no serviço de consulta de documento.',$e);
297 } 306 }
298 } 307 }
299 308
@@ -392,7 +401,7 @@ class CguRN extends InfraRN { @@ -392,7 +401,7 @@ class CguRN extends InfraRN {
392 $arrDto = $objProcedimentoRN->listarRN0278($dto); 401 $arrDto = $objProcedimentoRN->listarRN0278($dto);
393 402
394 if ($arrDto==null){ 403 if ($arrDto==null){
395 - $objInfraException->lancarValidacao('Nenhum processo encontrado para os parâmetros informados.'); 404 + $objInfraException->lancarValidacao('Nenhum processo encontrado para os parâmetros informados.');
396 } 405 }
397 406
398 $i = 0; 407 $i = 0;
@@ -409,7 +418,7 @@ class CguRN extends InfraRN { @@ -409,7 +418,7 @@ class CguRN extends InfraRN {
409 418
410 $objProtocoloRN = new ProtocoloRN(); 419 $objProtocoloRN = new ProtocoloRN();
411 if (count($objProtocoloRN->pesquisarRN0967($objPesquisaProtocoloDTO)) == 0) { 420 if (count($objProtocoloRN->pesquisarRN0967($objPesquisaProtocoloDTO)) == 0) {
412 - $objInfraException->lancarValidacao('Unidade [' . $objUnidadeDTO->getStrSigla() . '] não possui acesso ao processo [' . $objProcedimentoDTO->getStrProtocoloProcedimentoFormatado() . '].'); 421 + $objInfraException->lancarValidacao('Unidade [' . $objUnidadeDTO->getStrSigla() . '] não possui acesso ao processo [' . $objProcedimentoDTO->getStrProtocoloProcedimentoFormatado() . '].');
413 } 422 }
414 } 423 }
415 424
@@ -429,15 +438,15 @@ class CguRN extends InfraRN { @@ -429,15 +438,15 @@ class CguRN extends InfraRN {
429 $objOperacaoServicoRN = new OperacaoServicoRN(); 438 $objOperacaoServicoRN = new OperacaoServicoRN();
430 if ($objOperacaoServicoRN->contar($objOperacaoServicoDTO) == 0) { 439 if ($objOperacaoServicoRN->contar($objOperacaoServicoDTO) == 0) {
431 if ($objUnidadeDTO == null) { 440 if ($objUnidadeDTO == null) {
432 - $objInfraException->lancarValidacao('Nenhum serviço configurado para consulta deste processo [' . $objProcedimentoDTO->getStrProtocoloProcedimentoFormatado() . '] pelo Serviço [' . $objServicoDTO->getStrIdentificacao() . '].'); 441 + $objInfraException->lancarValidacao('Nenhum serviço configurado para consulta deste processo [' . $objProcedimentoDTO->getStrProtocoloProcedimentoFormatado() . '] pelo Serviço [' . $objServicoDTO->getStrIdentificacao() . '].');
433 } else { 442 } else {
434 - $objInfraException->lancarValidacao('Nenhum serviço configurado para consulta deste processo [' . $objProcedimentoDTO->getStrProtocoloProcedimentoFormatado() . '] na unidade [' . $objUnidadeDTO->getStrSigla() . '] pelo Serviço [' . $objServicoDTO->getStrIdentificacao() . '].'); 443 + $objInfraException->lancarValidacao('Nenhum serviço configurado para consulta deste processo [' . $objProcedimentoDTO->getStrProtocoloProcedimentoFormatado() . '] na unidade [' . $objUnidadeDTO->getStrSigla() . '] pelo Serviço [' . $objServicoDTO->getStrIdentificacao() . '].');
435 } 444 }
436 } 445 }
437 446
438 $objInfraException->lancarValidacoes(); 447 $objInfraException->lancarValidacoes();
439 448
440 - //verifica se o usuário já tem acesso ao processo 449 + //verifica se o usuário já tem acesso ao processo
441 $objAcessoExternoDTO = new AcessoExternoDTO(); 450 $objAcessoExternoDTO = new AcessoExternoDTO();
442 $objAcessoExternoDTO->retNumIdAcessoExterno(); 451 $objAcessoExternoDTO->retNumIdAcessoExterno();
443 $objAcessoExternoDTO->setDblIdProtocoloAtividade($objProcedimentoDTO->getDblIdProcedimento()); 452 $objAcessoExternoDTO->setDblIdProtocoloAtividade($objProcedimentoDTO->getDblIdProcedimento());
@@ -481,7 +490,7 @@ class CguRN extends InfraRN { @@ -481,7 +490,7 @@ class CguRN extends InfraRN {
481 return $ArrObjWSRetornoConsultarProcedimentoDTO; 490 return $ArrObjWSRetornoConsultarProcedimentoDTO;
482 491
483 }catch(Exception $e){ 492 }catch(Exception $e){
484 - throw new InfraException('Erro no serviço de consulta de procedimento.',$e); 493 + throw new InfraException('Erro no serviço de consulta de procedimento.',$e);
485 } 494 }
486 } 495 }
487 496
@@ -511,7 +520,7 @@ class CguRN extends InfraRN { @@ -511,7 +520,7 @@ class CguRN extends InfraRN {
511 $dto = $objProcedimentoRN->consultarRN0201($dto); 520 $dto = $objProcedimentoRN->consultarRN0201($dto);
512 521
513 if ($dto==null){ 522 if ($dto==null){
514 - $objInfraException->lancarValidacao('Processo '.$objProcedimentoDTO->getStrProtocoloProcedimentoFormatado().' não encontrado.'); 523 + $objInfraException->lancarValidacao('Processo '.$objProcedimentoDTO->getStrProtocoloProcedimentoFormatado().' não encontrado.');
515 } 524 }
516 525
517 $objProcedimentoDTO = $dto; 526 $objProcedimentoDTO = $dto;
@@ -536,7 +545,7 @@ class CguRN extends InfraRN { @@ -536,7 +545,7 @@ class CguRN extends InfraRN {
536 return $objWSRetornoListarAndamentosDTO; 545 return $objWSRetornoListarAndamentosDTO;
537 546
538 }catch(Exception $e){ 547 }catch(Exception $e){
539 - throw new InfraException('Erro no serviço de consulta de andamentos.',$e); 548 + throw new InfraException('Erro no serviço de consulta de andamentos.',$e);
540 } 549 }
541 } 550 }
542 551
@@ -563,7 +572,7 @@ class CguRN extends InfraRN { @@ -563,7 +572,7 @@ class CguRN extends InfraRN {
563 $dto = $objProcedimentoRN->consultarRN0201($dto); 572 $dto = $objProcedimentoRN->consultarRN0201($dto);
564 573
565 if ($dto==null){ 574 if ($dto==null){
566 - $objInfraException->lancarValidacao('Processo '.$objProcedimentoDTO->getStrProtocoloProcedimentoFormatado().' não encontrado.'); 575 + $objInfraException->lancarValidacao('Processo '.$objProcedimentoDTO->getStrProtocoloProcedimentoFormatado().' não encontrado.');
567 } 576 }
568 577
569 $objProcedimentoDTO = $dto;*/ 578 $objProcedimentoDTO = $dto;*/
@@ -588,7 +597,7 @@ class CguRN extends InfraRN { @@ -588,7 +597,7 @@ class CguRN extends InfraRN {
588 return $objWSRetornoListarAndamentosDTO; 597 return $objWSRetornoListarAndamentosDTO;
589 598
590 }catch(Exception $e){ 599 }catch(Exception $e){
591 - throw new InfraException('Erro no serviço de consulta de andamentos.',$e); 600 + throw new InfraException('Erro no serviço de consulta de andamentos.',$e);
592 } 601 }
593 } 602 }
594 603
@@ -605,7 +614,7 @@ class CguRN extends InfraRN { @@ -605,7 +614,7 @@ class CguRN extends InfraRN {
605 //filtra somente processos 614 //filtra somente processos
606 $objParticipanteDTO->setStrStaProtocoloProtocolo(ProtocoloRN::$TP_PROCEDIMENTO); 615 $objParticipanteDTO->setStrStaProtocoloProtocolo(ProtocoloRN::$TP_PROCEDIMENTO);
607 616
608 - //como não tem paginação é bom limitar 617 + //como não tem paginação é bom limitar
609 $objParticipanteDTO->setNumMaxRegistrosRetorno(500); 618 $objParticipanteDTO->setNumMaxRegistrosRetorno(500);
610 619
611 $objParticipanteRN = new ParticipanteRN(); 620 $objParticipanteRN = new ParticipanteRN();
@@ -631,14 +640,14 @@ class CguRN extends InfraRN { @@ -631,14 +640,14 @@ class CguRN extends InfraRN {
631 $objRelProtocoloAssuntoDTO->retNumIdAssunto(); 640 $objRelProtocoloAssuntoDTO->retNumIdAssunto();
632 $objRelProtocoloAssuntoDTO->setStrCodigoEstruturadoAssunto($ClassificacaoAssunto); 641 $objRelProtocoloAssuntoDTO->setStrCodigoEstruturadoAssunto($ClassificacaoAssunto);
633 642
634 - //como não tem paginação é bom limitar 643 + //como não tem paginação é bom limitar
635 $objRelProtocoloAssuntoDTO->setNumMaxRegistrosRetorno(500); 644 $objRelProtocoloAssuntoDTO->setNumMaxRegistrosRetorno(500);
636 645
637 $objRelProtocoloAssuntoRN = new RelProtocoloAssuntoRN(); 646 $objRelProtocoloAssuntoRN = new RelProtocoloAssuntoRN();
638 $arrAssuntos = $objRelProtocoloAssuntoRN->listarRN0188($objRelProtocoloAssuntoDTO); 647 $arrAssuntos = $objRelProtocoloAssuntoRN->listarRN0188($objRelProtocoloAssuntoDTO);
639 648
640 if (count($arrAssuntos)==0){ 649 if (count($arrAssuntos)==0){
641 - throw new InfraException('Nenhuma Classificação de Assunto encontrado!'); } 650 + throw new InfraException('Nenhuma Classificação de Assunto encontrado!'); }
642 651
643 $ret = array(); 652 $ret = array();
644 foreach($arrAssuntos as $Assuntos){ 653 foreach($arrAssuntos as $Assuntos){
@@ -661,7 +670,7 @@ class CguRN extends InfraRN { @@ -661,7 +670,7 @@ class CguRN extends InfraRN {
661 $arrObjPendenciaDTO = $objAtividadeRN->listarPendenciasRN0754($objPesquisaPendenciaDTO); 670 $arrObjPendenciaDTO = $objAtividadeRN->listarPendenciasRN0754($objPesquisaPendenciaDTO);
662 671
663 if (count($arrObjPendenciaDTO)==0){ 672 if (count($arrObjPendenciaDTO)==0){
664 - throw new InfraException('Nenhum Procedimento com Pendência para a Unidade Informada!'); } 673 + throw new InfraException('Nenhum Procedimento com Pendência para a Unidade Informada!'); }
665 674
666 $ret = array(); 675 $ret = array();
667 676
@@ -726,28 +735,28 @@ class CguRN extends InfraRN { @@ -726,28 +735,28 @@ class CguRN extends InfraRN {
726 735
727 private function adicionarCriteriosProcessoDocumento(OperacaoServicoDTO $objOperacaoServicoDTO, ProcedimentoDTO $objProcedimentoDTO, DocumentoDTO $objDocumentoDTO){ 736 private function adicionarCriteriosProcessoDocumento(OperacaoServicoDTO $objOperacaoServicoDTO, ProcedimentoDTO $objProcedimentoDTO, DocumentoDTO $objDocumentoDTO){
728 737
729 - //qualquer série em qualquer tipo de procedimento 738 + //qualquer série em qualquer tipo de procedimento
730 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdTipoProcedimento'), 739 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdTipoProcedimento'),
731 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL), 740 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL),
732 array(null,null), 741 array(null,null),
733 array(InfraDTO::$OPER_LOGICO_AND), 742 array(InfraDTO::$OPER_LOGICO_AND),
734 'c1'); 743 'c1');
735 744
736 - //esta série em qualquer tipo de procedimento 745 + //esta série em qualquer tipo de procedimento
737 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdTipoProcedimento'), 746 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdTipoProcedimento'),
738 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL), 747 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL),
739 array($objDocumentoDTO->getNumIdSerie(),null), 748 array($objDocumentoDTO->getNumIdSerie(),null),
740 array(InfraDTO::$OPER_LOGICO_AND), 749 array(InfraDTO::$OPER_LOGICO_AND),
741 'c2'); 750 'c2');
742 751
743 - //qualquer série neste tipo de procedimento 752 + //qualquer série neste tipo de procedimento
744 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdTipoProcedimento'), 753 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdTipoProcedimento'),
745 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL), 754 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL),
746 array(null, $objProcedimentoDTO->getNumIdTipoProcedimento()), 755 array(null, $objProcedimentoDTO->getNumIdTipoProcedimento()),
747 array(InfraDTO::$OPER_LOGICO_AND), 756 array(InfraDTO::$OPER_LOGICO_AND),
748 'c3'); 757 'c3');
749 758
750 - //esta série neste tipo de procedimento 759 + //esta série neste tipo de procedimento
751 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdTipoProcedimento'), 760 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdTipoProcedimento'),
752 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL), 761 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL),
753 array($objDocumentoDTO->getNumIdSerie(), $objProcedimentoDTO->getNumIdTipoProcedimento()), 762 array($objDocumentoDTO->getNumIdSerie(), $objProcedimentoDTO->getNumIdTipoProcedimento()),
@@ -762,56 +771,56 @@ class CguRN extends InfraRN { @@ -762,56 +771,56 @@ class CguRN extends InfraRN {
762 771
763 private function adicionarCriteriosUnidadeProcessoDocumento(OperacaoServicoDTO $objOperacaoServicoDTO, UnidadeDTO $objUnidadeDTO, ProcedimentoDTO $objProcedimentoDTO, DocumentoDTO $objDocumentoDTO){ 772 private function adicionarCriteriosUnidadeProcessoDocumento(OperacaoServicoDTO $objOperacaoServicoDTO, UnidadeDTO $objUnidadeDTO, ProcedimentoDTO $objProcedimentoDTO, DocumentoDTO $objDocumentoDTO){
764 773
765 - //qualquer série em qualquer unidade em qualquer tipo de procedimento 774 + //qualquer série em qualquer unidade em qualquer tipo de procedimento
766 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdUnidade','IdTipoProcedimento'), 775 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdUnidade','IdTipoProcedimento'),
767 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL), 776 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL),
768 array(null,null,null), 777 array(null,null,null),
769 array(InfraDTO::$OPER_LOGICO_AND,InfraDTO::$OPER_LOGICO_AND), 778 array(InfraDTO::$OPER_LOGICO_AND,InfraDTO::$OPER_LOGICO_AND),
770 'c1'); 779 'c1');
771 780
772 - //esta série em qualquer unidade em qualquer tipo de procedimento 781 + //esta série em qualquer unidade em qualquer tipo de procedimento
773 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdUnidade','IdTipoProcedimento'), 782 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdUnidade','IdTipoProcedimento'),
774 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL), 783 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL),
775 array($objDocumentoDTO->getNumIdSerie(),null,null), 784 array($objDocumentoDTO->getNumIdSerie(),null,null),
776 array(InfraDTO::$OPER_LOGICO_AND,InfraDTO::$OPER_LOGICO_AND), 785 array(InfraDTO::$OPER_LOGICO_AND,InfraDTO::$OPER_LOGICO_AND),
777 'c2'); 786 'c2');
778 787
779 - //qualquer série nesta unidade em qualquer tipo de procedimento 788 + //qualquer série nesta unidade em qualquer tipo de procedimento
780 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdUnidade','IdTipoProcedimento'), 789 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdUnidade','IdTipoProcedimento'),
781 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL), 790 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL),
782 array(null, $objUnidadeDTO->getNumIdUnidade(),null), 791 array(null, $objUnidadeDTO->getNumIdUnidade(),null),
783 array(InfraDTO::$OPER_LOGICO_AND,InfraDTO::$OPER_LOGICO_AND), 792 array(InfraDTO::$OPER_LOGICO_AND,InfraDTO::$OPER_LOGICO_AND),
784 'c3'); 793 'c3');
785 794
786 - //qualquer série em qualquer unidade neste tipo de procedimento 795 + //qualquer série em qualquer unidade neste tipo de procedimento
787 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdUnidade','IdTipoProcedimento'), 796 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdUnidade','IdTipoProcedimento'),
788 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL), 797 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL),
789 array(null, null ,$objProcedimentoDTO->getNumIdTipoProcedimento()), 798 array(null, null ,$objProcedimentoDTO->getNumIdTipoProcedimento()),
790 array(InfraDTO::$OPER_LOGICO_AND,InfraDTO::$OPER_LOGICO_AND), 799 array(InfraDTO::$OPER_LOGICO_AND,InfraDTO::$OPER_LOGICO_AND),
791 'c4'); 800 'c4');
792 801
793 - //esta série nesta unidade em qualquer tipo de procedimento 802 + //esta série nesta unidade em qualquer tipo de procedimento
794 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdUnidade','IdTipoProcedimento'), 803 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdUnidade','IdTipoProcedimento'),
795 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL), 804 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL),
796 array($objDocumentoDTO->getNumIdSerie(), $objUnidadeDTO->getNumIdUnidade(),null), 805 array($objDocumentoDTO->getNumIdSerie(), $objUnidadeDTO->getNumIdUnidade(),null),
797 array(InfraDTO::$OPER_LOGICO_AND,InfraDTO::$OPER_LOGICO_AND), 806 array(InfraDTO::$OPER_LOGICO_AND,InfraDTO::$OPER_LOGICO_AND),
798 'c5'); 807 'c5');
799 808
800 - //esta série em qualquer unidade neste tipo de procedimento 809 + //esta série em qualquer unidade neste tipo de procedimento
801 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdUnidade','IdTipoProcedimento'), 810 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdUnidade','IdTipoProcedimento'),
802 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL), 811 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL),
803 array($objDocumentoDTO->getNumIdSerie(), null,$objProcedimentoDTO->getNumIdTipoProcedimento()), 812 array($objDocumentoDTO->getNumIdSerie(), null,$objProcedimentoDTO->getNumIdTipoProcedimento()),
804 array(InfraDTO::$OPER_LOGICO_AND,InfraDTO::$OPER_LOGICO_AND), 813 array(InfraDTO::$OPER_LOGICO_AND,InfraDTO::$OPER_LOGICO_AND),
805 'c6'); 814 'c6');
806 815
807 - //qualquer série nesta unidade neste tipo de procedimento 816 + //qualquer série nesta unidade neste tipo de procedimento
808 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdUnidade','IdTipoProcedimento'), 817 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdUnidade','IdTipoProcedimento'),
809 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL), 818 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL),
810 array(null, $objUnidadeDTO->getNumIdUnidade(),$objProcedimentoDTO->getNumIdTipoProcedimento()), 819 array(null, $objUnidadeDTO->getNumIdUnidade(),$objProcedimentoDTO->getNumIdTipoProcedimento()),
811 array(InfraDTO::$OPER_LOGICO_AND,InfraDTO::$OPER_LOGICO_AND), 820 array(InfraDTO::$OPER_LOGICO_AND,InfraDTO::$OPER_LOGICO_AND),
812 'c7'); 821 'c7');
813 822
814 - //esta série nesta unidade neste tipo de procedimento 823 + //esta série nesta unidade neste tipo de procedimento
815 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdUnidade','IdTipoProcedimento'), 824 $objOperacaoServicoDTO->adicionarCriterio(array('IdSerie','IdUnidade','IdTipoProcedimento'),
816 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL), 825 array(InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL,InfraDTO::$OPER_IGUAL),
817 array($objDocumentoDTO->getNumIdSerie(), $objUnidadeDTO->getNumIdUnidade(),$objProcedimentoDTO->getNumIdTipoProcedimento()), 826 array($objDocumentoDTO->getNumIdSerie(), $objUnidadeDTO->getNumIdUnidade(),$objProcedimentoDTO->getNumIdTipoProcedimento()),