Commit 9ee4488271c406bc838e7bacb8c1a6d52f76be35
1 parent
dd781c7f
Exists in
MarceloOracle
Modificando md_pen_tramite para md_pen_tram
Showing
6 changed files
with
31 additions
and
31 deletions
Show diff stats
dto/ComponenteDigitalDTO.php
| ... | ... | @@ -26,7 +26,7 @@ class ComponenteDigitalDTO extends InfraDTO { |
| 26 | 26 | $this->adicionarAtributoTabela(InfraDTO::$PREFIXO_NUM, 'Ordem', 'ordem'); |
| 27 | 27 | $this->adicionarAtributoTabela(InfraDTO::$PREFIXO_STR, 'SinEnviar', 'sin_enviar'); |
| 28 | 28 | |
| 29 | - $this->adicionarAtributoTabelaRelacionada(InfraDTO::$PREFIXO_NUM, 'TicketEnvioComponentes', 'ticket_envio_componentes', 'md_pen_tramite'); | |
| 29 | + $this->adicionarAtributoTabelaRelacionada(InfraDTO::$PREFIXO_NUM, 'TicketEnvioComponentes', 'ticket_envio_componentes', 'md_pen_tram'); | |
| 30 | 30 | $this->adicionarAtributoTabelaRelacionada(InfraDTO::$PREFIXO_STR, 'ConteudoAssinaturaDocumento', 'conteudo_assinatura', 'documento_conteudo'); |
| 31 | 31 | $this->adicionarAtributoTabelaRelacionada(InfraDTO::$PREFIXO_STR, 'ProtocoloDocumentoFormatado', 'protocolo_formatado', 'protocolo'); |
| 32 | 32 | $this->adicionarAtributoTabelaRelacionada(InfraDTO::$PREFIXO_STR, 'StaEstadoProtocolo', 'sta_estado', 'protocolo'); |
| ... | ... | @@ -34,8 +34,8 @@ class ComponenteDigitalDTO extends InfraDTO { |
| 34 | 34 | $this->configurarPK('NumeroRegistro', InfraDTO::$TIPO_PK_INFORMADO); |
| 35 | 35 | $this->configurarPK('IdDocumento', InfraDTO::$TIPO_PK_INFORMADO); |
| 36 | 36 | |
| 37 | - $this->configurarFK('NumeroRegistro', 'md_pen_tramite', 'numero_registro', InfraDTO::$TIPO_FK_OBRIGATORIA); | |
| 38 | - $this->configurarFK('IdTramite', 'md_pen_tramite', 'id_tramite', InfraDTO::$TIPO_FK_OBRIGATORIA); | |
| 37 | + $this->configurarFK('NumeroRegistro', 'md_pen_tram', 'numero_registro', InfraDTO::$TIPO_FK_OBRIGATORIA); | |
| 38 | + $this->configurarFK('IdTramite', 'md_pen_tram', 'id_tramite', InfraDTO::$TIPO_FK_OBRIGATORIA); | |
| 39 | 39 | $this->configurarFK('IdDocumento', 'documento', 'id_documento', InfraDTO::$TIPO_FK_OBRIGATORIA); |
| 40 | 40 | $this->configurarFK('IdDocumento', 'protocolo', 'id_protocolo', InfraDTO::$TIPO_FK_OBRIGATORIA); |
| 41 | 41 | $this->configurarFK('IdDocumento', 'documento_conteudo', 'id_documento', InfraDTO::$TIPO_FK_OBRIGATORIA); | ... | ... |
dto/PenTramiteProcessadoDTO.php
| ... | ... | @@ -9,7 +9,7 @@ require_once dirname(__FILE__) . '/../../../SEI.php'; |
| 9 | 9 | class PenTramiteProcessadoDTO extends InfraDTO { |
| 10 | 10 | |
| 11 | 11 | public function getStrNomeTabela() { |
| 12 | - return 'md_pen_tramite_processado'; | |
| 12 | + return 'md_pen_tram_processado'; | |
| 13 | 13 | } |
| 14 | 14 | |
| 15 | 15 | public function montar() { | ... | ... |
dto/TramiteDTO.php
| ... | ... | @@ -3,7 +3,7 @@ |
| 3 | 3 | class TramiteDTO extends InfraDTO { |
| 4 | 4 | |
| 5 | 5 | public function getStrNomeTabela() { |
| 6 | - return 'md_pen_tramite'; | |
| 6 | + return 'md_pen_tram'; | |
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | public function montar() { |
| ... | ... | @@ -23,7 +23,7 @@ class TramiteDTO extends InfraDTO { |
| 23 | 23 | $this->configurarPK('NumeroRegistro', InfraDTO::$TIPO_PK_INFORMADO); |
| 24 | 24 | $this->configurarPK('IdTramite', InfraDTO::$TIPO_PK_INFORMADO); |
| 25 | 25 | |
| 26 | - $this->configurarFK('NumeroRegistro', 'md_pen_tramite', 'numero_registro', InfraDTO::$TIPO_FK_OBRIGATORIA); | |
| 26 | + $this->configurarFK('NumeroRegistro', 'md_pen_tram', 'numero_registro', InfraDTO::$TIPO_FK_OBRIGATORIA); | |
| 27 | 27 | $this->configurarFK('NumeroRegistro', 'md_pen_pr_elet pe', 'pe.numero_registro'); |
| 28 | 28 | $this->configurarFK('IdUsuario', 'usuario u', 'u.id_usuario'); |
| 29 | 29 | $this->configurarFK('IdUnidade', 'unidade u', 'u.id_unidade'); |
| ... | ... | @@ -32,8 +32,8 @@ class TramiteDTO extends InfraDTO { |
| 32 | 32 | } |
| 33 | 33 | |
| 34 | 34 | /* |
| 35 | -drop table md_pen_tramite; | |
| 36 | -CREATE TABLE md_pen_tramite ( | |
| 35 | +drop table md_pen_tram; | |
| 36 | +CREATE TABLE md_pen_tram ( | |
| 37 | 37 | id_tramite BIGINT(20) NOT NULL, |
| 38 | 38 | numero_registro VARCHAR(16) NOT NULL, |
| 39 | 39 | ticket_envio_componentes BIGINT(20), | ... | ... |
dto/TramitePendenteDTO.php
rn/PenAtualizarSeiRN.php
| ... | ... | @@ -109,7 +109,7 @@ class PenAtualizarSeiRN extends PenAtualizadorRN { |
| 109 | 109 | )); |
| 110 | 110 | |
| 111 | 111 | $objMetaBD->criarTabela(array( |
| 112 | - 'tabela' => 'md_pen_tramite', | |
| 112 | + 'tabela' => 'md_pen_tram', | |
| 113 | 113 | 'cols' => array( |
| 114 | 114 | 'numero_registro' => array($objMetaBD->tipoTextoFixo(16), PenMetaBD::NNULLO), |
| 115 | 115 | 'id_tramite' => array($objMetaBD->tipoNumeroGrande(), PenMetaBD::NNULLO), |
| ... | ... | @@ -139,7 +139,7 @@ class PenAtualizarSeiRN extends PenAtualizadorRN { |
| 139 | 139 | )); |
| 140 | 140 | |
| 141 | 141 | $objMetaBD->criarTabela(array( |
| 142 | - 'tabela' => 'md_pen_tramite_pendente', | |
| 142 | + 'tabela' => 'md_pen_tram_pendente', | |
| 143 | 143 | 'cols' => array( |
| 144 | 144 | 'id' => array($objMetaBD->tipoNumero(), PenMetaBD::NNULLO), |
| 145 | 145 | 'numero_tramite' => array($objMetaBD->tipoTextoVariavel(255)), |
| ... | ... | @@ -149,7 +149,7 @@ class PenAtualizarSeiRN extends PenAtualizadorRN { |
| 149 | 149 | )); |
| 150 | 150 | |
| 151 | 151 | $objMetaBD->criarTabela(array( |
| 152 | - 'tabela' => 'md_pen_tramite_recibo_envio', | |
| 152 | + 'tabela' => 'md_pen_tram_recibo_envio', | |
| 153 | 153 | 'cols' => array( |
| 154 | 154 | 'numero_registro' => array($objMetaBD->tipoTextoFixo(16), PenMetaBD::NNULLO), |
| 155 | 155 | 'id_tramite' => array($objMetaBD->tipoNumeroGrande(), PenMetaBD::NNULLO), |
| ... | ... | @@ -188,7 +188,7 @@ class PenAtualizarSeiRN extends PenAtualizadorRN { |
| 188 | 188 | )); |
| 189 | 189 | |
| 190 | 190 | /* $objMetaBD->criarTabela(array( |
| 191 | - 'tabela' => 'md_pen_tramite_recusado', | |
| 191 | + 'tabela' => 'md_pen_tram_recusado', | |
| 192 | 192 | 'cols' => array( |
| 193 | 193 | 'numero_registro'=> array($objMetaBD->tipoTextoFixo(16), PenMetaBD::NNULLO), |
| 194 | 194 | 'id_tramite' => array($objMetaBD->tipoNumeroGrande(), PenMetaBD::NNULLO) |
| ... | ... | @@ -207,7 +207,7 @@ class PenAtualizarSeiRN extends PenAtualizadorRN { |
| 207 | 207 | ), |
| 208 | 208 | 'pk' => array('numero_registro', 'id_tramite'), |
| 209 | 209 | 'fks' => array( |
| 210 | - 'md_pen_tramite' => array(array('numero_registro', 'id_tramite'), array('numero_registro', 'id_tramite')) | |
| 210 | + 'md_pen_tram' => array(array('numero_registro', 'id_tramite'), array('numero_registro', 'id_tramite')) | |
| 211 | 211 | ) |
| 212 | 212 | )); |
| 213 | 213 | |
| ... | ... | @@ -222,7 +222,7 @@ class PenAtualizarSeiRN extends PenAtualizadorRN { |
| 222 | 222 | ), |
| 223 | 223 | 'pk' => array('numero_registro', 'id_tramite'), |
| 224 | 224 | 'fks' => array( |
| 225 | - 'md_pen_tramite' => array(array('numero_registro', 'id_tramite'), array('numero_registro', 'id_tramite')) | |
| 225 | + 'md_pen_tram' => array(array('numero_registro', 'id_tramite'), array('numero_registro', 'id_tramite')) | |
| 226 | 226 | ) |
| 227 | 227 | )); |
| 228 | 228 | |
| ... | ... | @@ -236,7 +236,7 @@ class PenAtualizarSeiRN extends PenAtualizadorRN { |
| 236 | 236 | ), |
| 237 | 237 | 'pk' => array('numero_registro', 'id_tramite', 'hash_assinatura'), |
| 238 | 238 | 'fks' => array( |
| 239 | - 'md_pen_tramite' => array(array('numero_registro', 'id_tramite'), array('numero_registro', 'id_tramite')) | |
| 239 | + 'md_pen_tram' => array(array('numero_registro', 'id_tramite'), array('numero_registro', 'id_tramite')) | |
| 240 | 240 | ) |
| 241 | 241 | )); |
| 242 | 242 | |
| ... | ... | @@ -317,7 +317,7 @@ class PenAtualizarSeiRN extends PenAtualizadorRN { |
| 317 | 317 | 'documento' => array('id_documento', 'id_documento'), |
| 318 | 318 | 'procedimento' => array('id_procedimento', 'id_procedimento'), |
| 319 | 319 | 'md_pen_pr_elet' => array('numero_registro', 'numero_registro'), |
| 320 | - 'md_pen_tramite' => array(array('numero_registro', 'id_tramite'), array('numero_registro', 'id_tramite')) | |
| 320 | + 'md_pen_tram' => array(array('numero_registro', 'id_tramite'), array('numero_registro', 'id_tramite')) | |
| 321 | 321 | ) |
| 322 | 322 | )); |
| 323 | 323 | |
| ... | ... | @@ -343,9 +343,9 @@ class PenAtualizarSeiRN extends PenAtualizadorRN { |
| 343 | 343 | $objInfraSequencia->criarSequencia('md_pen_procedimento_andamento', '1', '1', '9999999999'); |
| 344 | 344 | } |
| 345 | 345 | |
| 346 | - if (!$objInfraSequencia->verificarSequencia('md_pen_tramite_pendente')) { | |
| 346 | + if (!$objInfraSequencia->verificarSequencia('md_pen_tram_pendente')) { | |
| 347 | 347 | |
| 348 | - $objInfraSequencia->criarSequencia('md_pen_tramite_pendente', '1', '1', '9999999999'); | |
| 348 | + $objInfraSequencia->criarSequencia('md_pen_tram_pendente', '1', '1', '9999999999'); | |
| 349 | 349 | } |
| 350 | 350 | //---------------------------------------------------------------------- |
| 351 | 351 | // Parâmetros |
| ... | ... | @@ -657,7 +657,7 @@ class PenAtualizarSeiRN extends PenAtualizadorRN { |
| 657 | 657 | /* ---------- antigo método (instalarV002R003S000US024) ---------- */ |
| 658 | 658 | |
| 659 | 659 | $objMetaBD->criarTabela(array( |
| 660 | - 'tabela' => 'md_pen_tramite_processado', | |
| 660 | + 'tabela' => 'md_pen_tram_processado', | |
| 661 | 661 | 'cols' => array( |
| 662 | 662 | 'id_tramite' => array($objMetaBD->tipoNumeroGrande(), PenMetaBD::NNULLO), |
| 663 | 663 | 'dth_ultimo_processamento' => array($objMetaBD->tipoDataHora(), PenMetaBD::NNULLO), |
| ... | ... | @@ -702,15 +702,15 @@ class PenAtualizarSeiRN extends PenAtualizadorRN { |
| 702 | 702 | /* ---------- antigo método (instalarV002R003S001US035) ---------- */ |
| 703 | 703 | $objMetaBanco = $this->inicializarObjMetaBanco(); |
| 704 | 704 | |
| 705 | - if (!$objMetaBanco->isColuna('md_pen_tramite_processado', 'tipo_tramite_processo')) { | |
| 706 | - $objMetaBanco->adicionarColuna('md_pen_tramite_processado', 'tipo_tramite_processo', 'CHAR(2)', PenMetaBD::NNULLO); | |
| 707 | - $objMetaBanco->adicionarValorPadraoParaColuna('md_pen_tramite_processado', 'tipo_tramite_processo', 'RP'); | |
| 705 | + if (!$objMetaBanco->isColuna('md_pen_tram_processado', 'tipo_tramite_processo')) { | |
| 706 | + $objMetaBanco->adicionarColuna('md_pen_tram_processado', 'tipo_tramite_processo', 'CHAR(2)', PenMetaBD::NNULLO); | |
| 707 | + $objMetaBanco->adicionarValorPadraoParaColuna('md_pen_tram_processado', 'tipo_tramite_processo', 'RP'); | |
| 708 | 708 | } |
| 709 | 709 | |
| 710 | - if ($objMetaBanco->isChaveExiste('md_pen_tramite_processado', 'pk_md_pen_tramite_processado')) { | |
| 710 | + if ($objMetaBanco->isChaveExiste('md_pen_tram_processado', 'pk_md_pen_tram_processado')) { | |
| 711 | 711 | |
| 712 | - $objMetaBanco->removerChavePrimaria('md_pen_tramite_processado', 'pk_md_pen_tramite_processado'); | |
| 713 | - $objMetaBanco->adicionarChavePrimaria('md_pen_tramite_processado', 'pk_md_pen_tramite_processado', array('id_tramite', 'tipo_tramite_processo')); | |
| 712 | + $objMetaBanco->removerChavePrimaria('md_pen_tram_processado', 'pk_md_pen_tram_processado'); | |
| 713 | + $objMetaBanco->adicionarChavePrimaria('md_pen_tram_processado', 'pk_md_pen_tram_processado', array('id_tramite', 'tipo_tramite_processo')); | |
| 714 | 714 | } |
| 715 | 715 | |
| 716 | 716 | /* ---------- antigo método (instalarV003R003S003IW001) ---------- */ |
| ... | ... | @@ -901,7 +901,7 @@ class PenAtualizarSeiRN extends PenAtualizadorRN { |
| 901 | 901 | ), |
| 902 | 902 | 'pk' => array('id_tramite_hash'), |
| 903 | 903 | 'fks' => array( |
| 904 | - 'md_pen_tramite' => array(array('numero_registro', 'id_tramite'), array('numero_registro', 'id_tramite')) | |
| 904 | + 'md_pen_tram' => array(array('numero_registro', 'id_tramite'), array('numero_registro', 'id_tramite')) | |
| 905 | 905 | ) |
| 906 | 906 | )); |
| 907 | 907 | ... | ... |
rn/ProcessoExpedidoRN.php
| ... | ... | @@ -31,14 +31,14 @@ class ProcessoExpedidoRN extends InfraRN { |
| 31 | 31 | INNER JOIN atividade a ON a.id_protocolo = p.id_protocolo |
| 32 | 32 | INNER JOIN atributo_andamento atd ON a.id_atividade = atd.id_atividade AND atd.nome = 'UNIDADE_DESTINO' |
| 33 | 33 | INNER JOIN md_pen_pr_elet pe ON pe.id_procedimento = p.id_protocolo |
| 34 | - INNER JOIN md_pen_tramite ptra ON ptra.numero_registro = pe.numero_registro | |
| 34 | + INNER JOIN md_pen_tram ptra ON ptra.numero_registro = pe.numero_registro | |
| 35 | 35 | INNER JOIN usuario us ON ptra.id_usuario = us.id_usuario |
| 36 | 36 | WHERE |
| 37 | 37 | p.sta_estado = " . $objProtocoloDTO->getStrStaEstado() . " |
| 38 | 38 | AND |
| 39 | 39 | a.id_tarefa = ". ProcessoEletronicoRN::obterIdTarefaModulo(ProcessoEletronicoRN::$TI_PROCESSO_ELETRONICO_PROCESSO_TRAMITE_EXTERNO) ." |
| 40 | 40 | AND |
| 41 | - ptra.dth_registro = (SELECT MAX(pt.dth_registro) dth_registro FROM md_pen_tramite pt WHERE pt.numero_registro = pe.numero_registro) | |
| 41 | + ptra.dth_registro = (SELECT MAX(pt.dth_registro) dth_registro FROM md_pen_tram pt WHERE pt.numero_registro = pe.numero_registro) | |
| 42 | 42 | AND |
| 43 | 43 | NOT EXISTS ( |
| 44 | 44 | SELECT at2.* FROM atividade as at2 |
| ... | ... | @@ -54,14 +54,14 @@ class ProcessoExpedidoRN extends InfraRN { |
| 54 | 54 | INNER JOIN atividade a ON a.id_protocolo = p.id_protocolo |
| 55 | 55 | INNER JOIN atributo_andamento atd ON a.id_atividade = atd.id_atividade AND atd.nome = 'UNIDADE_DESTINO' |
| 56 | 56 | INNER JOIN md_pen_pr_elet pe ON pe.id_procedimento = p.id_protocolo |
| 57 | - INNER JOIN md_pen_tramite ptra ON ptra.numero_registro = pe.numero_registro | |
| 57 | + INNER JOIN md_pen_tram ptra ON ptra.numero_registro = pe.numero_registro | |
| 58 | 58 | INNER JOIN usuario us ON ptra.id_usuario = us.id_usuario |
| 59 | 59 | WHERE |
| 60 | 60 | p.sta_estado = " . $objProtocoloDTO->getStrStaEstado() . " |
| 61 | 61 | AND |
| 62 | 62 | a.id_tarefa = ". ProcessoEletronicoRN::obterIdTarefaModulo(ProcessoEletronicoRN::$TI_PROCESSO_ELETRONICO_PROCESSO_TRAMITE_EXTERNO) ." |
| 63 | 63 | AND |
| 64 | - ptra.dth_registro = (SELECT MAX(pt.dth_registro) dth_registro FROM md_pen_tramite pt WHERE pt.numero_registro = pe.numero_registro) | |
| 64 | + ptra.dth_registro = (SELECT MAX(pt.dth_registro) dth_registro FROM md_pen_tram pt WHERE pt.numero_registro = pe.numero_registro) | |
| 65 | 65 | AND |
| 66 | 66 | NOT EXISTS ( |
| 67 | 67 | SELECT at2.* FROM atividade as at2 | ... | ... |