function Gerar() { if ($_POST) { foreach ($_POST as $campo => $val) { $this->{$campo} = $this->{$campo} ? $this->{$campo} : $val; } } if (is_numeric($this->colecao)) { $this->ref_cod_acervo_colecao = $this->colecao; } if (is_numeric($this->editora)) { $this->ref_cod_acervo_editora = $this->editora; } if (is_numeric($this->idioma)) { $this->ref_cod_acervo_idioma = $this->idioma; } if (is_numeric($this->autor)) { $this->ref_cod_acervo_autor = $this->autor; } // primary keys $this->campoOculto("cod_acervo", $this->cod_acervo); $this->campoOculto("colecao", ""); $this->campoOculto("editora", ""); $this->campoOculto("idioma", ""); $this->campoOculto("autor", ""); $this->inputsHelper()->dynamic(array('instituicao', 'escola', 'biblioteca', 'bibliotecaTipoExemplar')); // Obra referência $opcoes = array("NULL" => "Selecione"); if ($this->ref_cod_acervo && $this->ref_cod_acervo != "NULL") { $objTemp = new clsPmieducarAcervo($this->ref_cod_acervo); $detalhe = $objTemp->detalhe(); if ($detalhe) { $opcoes["{$detalhe['cod_acervo']}"] = "{$detalhe['titulo']}"; } } $this->campoLista("ref_cod_acervo", "Obra Referência", $opcoes, $this->ref_cod_acervo, "", false, "", "<img border=\"0\" onclick=\"pesquisa();\" id=\"ref_cod_acervo_lupa\" name=\"ref_cod_acervo_lupa\" src=\"imagens/lupa.png\"\\/>", false, false); // Coleção $opcoes = array("" => "Selecione"); if (class_exists("clsPmieducarAcervoColecao")) { $objTemp = new clsPmieducarAcervoColecao(); $lista = $objTemp->lista(); if (is_array($lista) && count($lista)) { foreach ($lista as $registro) { $opcoes["{$registro['cod_acervo_colecao']}"] = "{$registro['nm_colecao']}"; } } } else { echo "<!--\nErro\nClasse clsPmieducarAcervoColecao nao encontrada\n-->"; $opcoes = array("" => "Erro na geracao"); } $this->campoLista("ref_cod_acervo_colecao", "Coleção", $opcoes, $this->ref_cod_acervo_colecao, "", false, "", "<img id='img_colecao' src='imagens/banco_imagens/escreve.gif' style='cursor:hand; cursor:pointer;' border='0' onclick=\"showExpansivelImprimir(500, 200,'educar_acervo_colecao_cad_pop.php',[], 'Coleção')\" />", false, false); // Idioma $opcoes = array("" => "Selecione"); if (class_exists("clsPmieducarAcervoIdioma")) { $objTemp = new clsPmieducarAcervoIdioma(); $lista = $objTemp->lista(); if (is_array($lista) && count($lista)) { foreach ($lista as $registro) { $opcoes["{$registro['cod_acervo_idioma']}"] = "{$registro['nm_idioma']}"; } } } else { echo "<!--\nErro\nClasse clsPmieducarAcervoIdioma nao encontrada\n-->"; $opcoes = array("" => "Erro na geracao"); } $this->campoLista("ref_cod_acervo_idioma", "Idioma", $opcoes, $this->ref_cod_acervo_idioma, "", false, "", "<img id='img_idioma' src='imagens/banco_imagens/escreve.gif' style='cursor:hand; cursor:pointer;' border='0' onclick=\"showExpansivelImprimir(400, 150,'educar_acervo_idioma_cad_pop.php',[], 'Idioma')\" />"); $opcoes = array("" => "Selecione"); if (class_exists("clsPmieducarAcervoEditora")) { $objTemp = new clsPmieducarAcervoEditora(); $lista = $objTemp->lista(); if (is_array($lista) && count($lista)) { foreach ($lista as $registro) { $opcoes["{$registro['cod_acervo_editora']}"] = "{$registro['nm_editora']}"; } } } else { echo "<!--\nErro\nClasse clsPmieducarAcervoEditora nao encontrada\n-->"; $opcoes = array("" => "Erro na geracao"); } $this->campoLista("ref_cod_acervo_editora", "Editora", $opcoes, $this->ref_cod_acervo_editora, "", false, "", "<img id='img_editora' src='imagens/banco_imagens/escreve.gif' style='cursor:hand; cursor:pointer;' border='0' onclick=\"showExpansivelImprimir(400, 320,'educar_acervo_editora_cad_pop.php',[], 'Editora')\" />"); //-----------------------INCLUI AUTOR------------------------// $this->campoQuebra(); if ($_POST["acervo_autor"]) { $this->acervo_autor = unserialize(urldecode($_POST["acervo_autor"])); } if (is_numeric($this->cod_acervo) && !$_POST) { $obj = new clsPmieducarAcervoAcervoAutor(); $registros = $obj->lista(null, $this->cod_acervo); if ($registros) { foreach ($registros as $campo) { $aux["ref_cod_acervo_autor_"] = $campo["ref_cod_acervo_autor"]; $aux["principal_"] = $campo["principal"]; $this->acervo_autor[] = $aux; } // verifica se ja existe um autor principal if (is_array($this->acervo_autor)) { foreach ($this->acervo_autor as $autores) { if ($autores["principal_"] == 1) { $this->checked = 1; $this->campoOculto("checked", $this->checked); } } } } } unset($aux); if ($_POST["ref_cod_acervo_autor"]) { if ($_POST["principal"]) { $this->checked = 1; $this->campoOculto("checked", $this->checked); } $aux["ref_cod_acervo_autor_"] = $_POST["ref_cod_acervo_autor"]; $aux["principal_"] = $_POST["principal"]; $this->acervo_autor[] = $aux; // echo "<pre>";print_r($this->acervo_autor); // verifica se ja existe um autor principal if (is_array($this->acervo_autor)) { foreach ($this->acervo_autor as $autores) { if ($autores["principal_"] == 'on') { $this->checked = 1; $this->campoOculto("checked", $this->checked); } } } unset($this->ref_cod_acervo_autor); unset($this->principal); } $this->campoOculto("excluir_autor", ""); unset($aux); if ($this->acervo_autor) { foreach ($this->acervo_autor as $key => $autor) { if ($this->excluir_autor == $autor["ref_cod_acervo_autor_"]) { unset($this->acervo_autor[$key]); unset($this->excluir_autor); } else { $obj_acervo_autor = new clsPmieducarAcervoAutor($autor["ref_cod_acervo_autor_"]); $det_acervo_autor = $obj_acervo_autor->detalhe(); $nm_autor = $det_acervo_autor["nm_autor"]; $this->campoTextoInv("ref_cod_exemplar_tipo_{$autor["ref_cod_acervo_autor_"]}", "", $nm_autor, 30, 255, false, false, true); $this->campoCheck("principal_{$autor["ref_cod_acervo_autor_"]}", "", $autor['principal_'], "<a href='#' onclick=\"getElementById('excluir_autor').value = '{$autor["ref_cod_acervo_autor_"]}'; getElementById('tipoacao').value = ''; {$this->__nome}.submit();\"><img src='imagens/nvp_bola_xis.gif' title='Excluir' border=0></a>", false, false, false); $aux["ref_cod_acervo_autor_"] = $autor["ref_cod_acervo_autor_"]; $aux["principal_"] = $autor['principal_']; } } } $this->campoOculto("acervo_autor", serialize($this->acervo_autor)); if (class_exists("clsPmieducarAcervoAutor")) { $opcoes = array("" => "Selecione"); $objTemp = new clsPmieducarAcervoAutor(); $objTemp->setOrderby("nm_autor ASC"); $lista = $objTemp->lista(null, null, null, null, null, null, null, null, null, 1); if (is_array($lista) && count($lista)) { foreach ($lista as $registro) { $opcoes["{$registro['cod_acervo_autor']}"] = "{$registro['nm_autor']}"; } } } else { echo "<!--\nErro\nClasse clsPmieducarAcervoAutor não encontrada\n-->"; $opcoes = array("" => "Erro na geração"); } if (is_array($this->acervo_autor)) { $qtd_autor = count($this->acervo_autor); } // não existe um autor principal nem autor if ($this->checked != 1 && (!$qtd_autor || $qtd_autor == 0)) { // die("1"); $this->campoLista("ref_cod_acervo_autor", "Autor", $opcoes, $this->ref_cod_acervo_autor, null, true, "", "", false, true); $this->campoCheck("principal", " <img id='img_autor' src='imagens/banco_imagens/escreve.gif' style='cursor:hand; cursor:pointer;' border='0' onclick=\"showExpansivelImprimir(500, 250,'educar_acervo_autor_cad_pop.php',[], 'Autor')\" />", $this->principal, "<a href='#' onclick=\"getElementById('incluir_autor').value = 'S'; getElementById('tipoacao').value = ''; {$this->__nome}.submit();\"><img src='imagens/nvp_bot_adiciona.gif' title='Incluir' border=0></a>"); } else { if ($this->checked != 1 && $qtd_autor > 0) { $this->campoLista("ref_cod_acervo_autor", "Autor", $opcoes, $this->ref_cod_acervo_autor, null, true, null, null, null, false); $this->campoCheck("principal", " <img src='imagens/banco_imagens/escreve.gif' style='cursor:hand; cursor:pointer;' border='0' onclick=\"pesquisa_valores_popless( 'educar_acervo_autor_cad_pop.php' )\" />", $this->principal, "<a href='#' onclick=\"getElementById('incluir_autor').value = 'S'; getElementById('tipoacao').value = ''; {$this->__nome}.submit();\"><img src='imagens/nvp_bot_adiciona.gif' title='Incluir' border=0></a>"); } else { // die("3"); $this->campoLista("ref_cod_acervo_autor", "Autor", $opcoes, $this->ref_cod_acervo_autor, "", false, "", "<img src='imagens/banco_imagens/escreve.gif' style='cursor:hand; cursor:pointer;' border='0' onclick=\"pesquisa_valores_popless( 'educar_acervo_autor_cad_pop.php' )\" /> <a href='#' onclick=\"getElementById('incluir_autor').value = 'S'; getElementById('tipoacao').value = ''; {$this->__nome}.submit();\"><img src='imagens/nvp_bot_adiciona.gif' title='Incluir' border=0></a>", false, false); } } $this->campoOculto("incluir_autor", ""); $this->campoQuebra(); //-----------------------FIM AUTOR------------------------// // text $this->campoTexto("titulo", "Título", $this->titulo, 40, 255, true); $this->campoTexto("sub_titulo", "Subtítulo", $this->sub_titulo, 40, 255, false); $this->campoTexto("estante", "Estante", $this->estante, 20, 15, false); $helperOptions = array('objectName' => 'assuntos'); $options = array('label' => 'Assuntos', 'size' => 50, 'required' => false, 'options' => array('value' => null)); $this->inputsHelper()->multipleSearchAssuntos('', $options, $helperOptions); $this->campoTexto("cdd", "CDD", $this->cdd, 20, 15, false); $this->campoTexto("cdu", "CDU", $this->cdu, 20, 15, false); $this->campoTexto("cutter", "Cutter", $this->cutter, 20, 15, false); $this->campoNumero("volume", "Volume", $this->volume, 20, 255, true); $this->campoNumero("num_edicao", "Número Edicão", $this->num_edicao, 20, 255, true); $this->campoNumero("ano", "Ano", $this->ano, 5, 4, true); $this->campoNumero("num_paginas", "Número Páginas", $this->num_paginas, 5, 255, true); $this->campoNumero("isbn", "ISBN", $this->isbn, 20, 13, false); }
function Gerar() { @session_start(); $this->pessoa_logada = $_SESSION['id_pessoa']; session_write_close(); $this->titulo = "Exemplar - Listagem"; foreach ($_GET as $var => $val) { // passa todos os valores obtidos no GET para atributos do objeto $this->{$var} = $val === "" ? null : $val; } $lista_busca = array("Tombo", "Obra", "Tipo"); // Filtros de Foreign Keys $get_escola = true; $get_biblioteca = true; $get_cabecalho = "lista_busca"; include "include/pmieducar/educar_campo_lista.php"; $this->addCabecalhos($lista_busca); $opcoes = array("" => "Selecione"); /*if( class_exists( "clsPmieducarExemplarTipo" ) ) { $objTemp = new clsPmieducarExemplarTipo(); $lista = $objTemp->lista(null,null); if ( is_array( $lista ) && count( $lista ) ) { $tipos = "tipos = new Array();\n"; foreach ( $lista as $registro ) { $tipos .= "tipos[tipos.length] = new Array( {$registro["cod_exemplar_tipo"]}, '{$registro['nm_tipo']}', {$registro['ref_cod_biblioteca']});\n"; } echo "<script>{$tipos}</script>"; } } else { echo "<!--\nErro\nClasse clsPmieducarExemplarTipo nao encontrada\n-->"; }*/ $opcoes_colecao = array(); $opcoes_colecao[""] = "Selecione"; $opcoes_editora = array(); $opcoes_editora[""] = "Selecione"; $opcoes_fonte = array(); $opcoes_fonte[""] = "Selecione"; if ($this->ref_cod_biblioteca) { $objTemp = new clsPmieducarExemplarTipo(); $lista = $objTemp->lista(null, $this->ref_cod_biblioteca); if (is_array($lista) && count($lista)) { foreach ($lista as $registro) { $opcoes["{$registro['cod_exemplar_tipo']}"] = "{$registro['nm_tipo']}"; } } $obj_colecao = new clsPmieducarAcervoColecao(); $obj_colecao->setOrderby("nm_colecao ASC"); $obj_colecao->setCamposLista("cod_acervo_colecao, nm_colecao"); $lst_colecao = $obj_colecao->lista(null, null, null, null, null, null, null, null, null, 1, $this->ref_cod_biblioteca); if (is_array($lst_colecao)) { foreach ($lst_colecao as $colecao) { $opcoes_colecao[$colecao["cod_acervo_colecao"]] = $colecao["nm_colecao"]; } } $obj_editora = new clsPmieducarAcervoEditora(); $obj_editora->setCamposLista("cod_acervo_editora, nm_editora"); $obj_editora->setOrderby("nm_editora ASC"); $lst_editora = $obj_editora->lista(null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, 1, $this->ref_cod_biblioteca); if (is_array($lst_editora)) { foreach ($lst_editora as $editora) { $opcoes_editora[$editora["cod_acervo_editora"]] = $editora["nm_editora"]; } } $obj_fonte = new clsPmieducarFonte(); $obj_fonte->setOrderby("nm_fonte ASC"); $obj_fonte->setCamposLista("cod_fonte, nm_fonte"); $lst_fonte = $obj_fonte->lista(null, null, null, null, null, null, null, null, null, 1, $this->ref_cod_biblioteca); if (is_array($lst_fonte)) { foreach ($lst_fonte as $fonte) { $opcoes_fonte[$fonte["cod_fonte"]] = $fonte["nm_fonte"]; } } } $this->campoLista("ref_cod_exemplar_tipo", "Exemplar Tipo", $opcoes, $this->ref_cod_exemplar_tipo, null, null, null, null, null, false); $this->campoLista("ref_cod_acervo_colecao", "Acervo Coleção", $opcoes_colecao, $this->ref_cod_acervo_colecao, "", false, "", "", false, false); $this->campoLista("ref_cod_acervo_editora", "Editora", $opcoes_editora, $this->ref_cod_acervo_editora, "", false, "", "", false, false); $this->campoLista("ref_cod_fonte", "Fonte", $opcoes_fonte, $this->ref_cod_fonte, "", false, "", "", false, false); $this->campoTexto("titulo_livro", "Título da Obra", $this->titulo_livro, 25, 255, false); $this->campoNumero("cod_exemplar", "Tombo", $this->cod_exemplar, 10, 50, false); $opcoes = array("NULL" => "Selecione"); if ($this->ref_cod_acervo && $this->ref_cod_acervo != "NULL") { $objTemp = new clsPmieducarAcervo($this->ref_cod_acervo); $detalhe = $objTemp->detalhe(); if ($detalhe) { $opcoes["{$detalhe['cod_acervo']}"] = "{$detalhe['titulo']}"; } } // Paginador $this->limite = 20; $this->offset = $_GET["pagina_{$this->nome}"] ? $_GET["pagina_{$this->nome}"] * $this->limite - $this->limite : 0; $obj_exemplar = new clsPmieducarExemplar(); $obj_exemplar->setOrderby("tombo ASC"); $obj_exemplar->setLimite($this->limite, $this->offset); $lista = $obj_exemplar->lista_com_acervos(null, $this->ref_cod_fonte, null, null, null, null, null, null, null, null, null, 1, null, null, null, null, $this->ref_cod_exemplar_tipo, $this->titulo_livro, $this->ref_cod_biblioteca, $this->ref_cod_instituicao, $this->ref_cod_escola, $this->ref_cod_acervo_colecao, $this->ref_cod_acervo_editora, $this->cod_exemplar); $total = $obj_exemplar->_total; // monta a lista if (is_array($lista) && count($lista)) { foreach ($lista as $registro) { // muda os campos data $registro["data_aquisicao_time"] = strtotime(substr($registro["data_aquisicao"], 0, 16)); $registro["data_aquisicao_br"] = date("d/m/Y H:i", $registro["data_aquisicao_time"]); // pega detalhes de foreign_keys if (class_exists("clsPmieducarFonte")) { $obj_ref_cod_fonte = new clsPmieducarFonte($registro["ref_cod_fonte"]); $det_ref_cod_fonte = $obj_ref_cod_fonte->detalhe(); $registro["ref_cod_fonte"] = $det_ref_cod_fonte["nm_fonte"]; } else { $registro["ref_cod_fonte"] = "Erro na geracao"; echo "<!--\nErro\nClasse nao existente: clsPmieducarFonte\n-->"; } if (class_exists("clsPmieducarMotivoBaixa")) { $obj_ref_cod_motivo_baixa = new clsPmieducarMotivoBaixa($registro["ref_cod_motivo_baixa"]); $det_ref_cod_motivo_baixa = $obj_ref_cod_motivo_baixa->detalhe(); $registro["ref_cod_motivo_baixa"] = $det_ref_cod_motivo_baixa["nm_motivo_baixa"]; } else { $registro["ref_cod_motivo_baixa"] = "Erro na geracao"; echo "<!--\nErro\nClasse nao existente: clsPmieducarMotivoBaixa\n-->"; } if (class_exists("clsPmieducarAcervo")) { $obj_ref_cod_acervo = new clsPmieducarAcervo($registro["ref_cod_acervo"]); $det_ref_cod_acervo = $obj_ref_cod_acervo->detalhe(); $registro["ref_cod_acervo"] = $det_ref_cod_acervo["titulo"]; } else { $registro["ref_cod_acervo"] = "Erro na geracao"; echo "<!--\nErro\nClasse nao existente: clsPmieducarAcervo\n-->"; } if (class_exists("clsPmieducarExemplarTipo")) { $obj_ref_cod_tipo = new clsPmieducarExemplarTipo($det_ref_cod_acervo["ref_cod_exemplar_tipo"]); $det_ref_cod_tipo = $obj_ref_cod_tipo->detalhe(); $registro["ref_cod_tipo"] = $det_ref_cod_tipo["nm_tipo"]; } else { $registro["ref_cod_tipo"] = "Erro na geracao"; echo "<!--\nErro\nClasse nao existente: clsPmieducarAcervo\n-->"; } if (class_exists("clsPmieducarSituacao")) { $obj_ref_cod_situacao = new clsPmieducarSituacao($registro["ref_cod_situacao"]); $det_ref_cod_situacao = $obj_ref_cod_situacao->detalhe(); $registro["ref_cod_situacao"] = $det_ref_cod_situacao["nm_situacao"]; } else { $registro["ref_cod_situacao"] = "Erro na geracao"; echo "<!--\nErro\nClasse nao existente: clsPmieducarSituacao\n-->"; } // pega detalhes de foreign_keys if (class_exists("clsPmieducarBiblioteca")) { $obj_ref_cod_biblioteca = new clsPmieducarBiblioteca($registro["ref_cod_biblioteca"]); $det_ref_cod_biblioteca = $obj_ref_cod_biblioteca->detalhe(); $registro["ref_cod_biblioteca"] = $det_ref_cod_biblioteca["nm_biblioteca"]; $registro["ref_cod_instituicao"] = $det_ref_cod_biblioteca["ref_cod_instituicao"]; $registro["ref_cod_escola"] = $det_ref_cod_biblioteca["ref_cod_escola"]; if ($registro["ref_cod_instituicao"]) { $obj_ref_cod_instituicao = new clsPmieducarInstituicao($registro["ref_cod_instituicao"]); $det_ref_cod_instituicao = $obj_ref_cod_instituicao->detalhe(); $registro["ref_cod_instituicao"] = $det_ref_cod_instituicao["nm_instituicao"]; } if ($registro["ref_cod_escola"]) { $obj_ref_cod_escola = new clsPmieducarEscola(); $det_ref_cod_escola = array_shift($obj_ref_cod_escola->lista($registro["ref_cod_escola"])); $registro["ref_cod_escola"] = $det_ref_cod_escola["nome"]; } } else { $registro["ref_cod_biblioteca"] = "Erro na geracao"; echo "<!--\nErro\nClasse nao existente: clsPmieducarBiblioteca\n-->"; } $lista_busca = array("<a href=\"educar_exemplar_det.php?cod_exemplar={$registro["cod_exemplar"]}\">{$registro["tombo"]}</a>", "<a href=\"educar_exemplar_det.php?cod_exemplar={$registro["cod_exemplar"]}\">{$registro["ref_cod_acervo"]}</a>", "<a href=\"educar_exemplar_det.php?cod_exemplar={$registro["cod_exemplar"]}\">{$registro["ref_cod_tipo"]}</a>"); if ($qtd_bibliotecas > 1 && ($nivel_usuario == 4 || $nivel_usuario == 8)) { $lista_busca[] = "<a href=\"educar_exemplar_det.php?cod_exemplar={$registro["cod_exemplar"]}\">{$registro["ref_cod_biblioteca"]}</a>"; } else { if ($nivel_usuario == 1 || $nivel_usuario == 2 || $nivel_usuario == 4) { $lista_busca[] = "<a href=\"educar_exemplar_det.php?cod_exemplar={$registro["cod_exemplar"]}\">{$registro["ref_cod_biblioteca"]}</a>"; } } if ($nivel_usuario == 1 || $nivel_usuario == 2) { $lista_busca[] = "<a href=\"educar_exemplar_det.php?cod_exemplar={$registro["cod_exemplar"]}\">{$registro["ref_cod_escola"]}</a>"; } if ($nivel_usuario == 1) { $lista_busca[] = "<a href=\"educar_exemplar_det.php?cod_exemplar={$registro["cod_exemplar"]}\">{$registro["ref_cod_instituicao"]}</a>"; } $this->addLinhas($lista_busca); } } $this->addPaginador2("educar_exemplar_lst.php", $total, $_GET, $this->nome, $this->limite); $obj_permissoes = new clsPermissoes(); if ($obj_permissoes->permissao_cadastra(606, $this->pessoa_logada, 11)) { $this->acao = "go(\"educar_exemplar_cad.php\")"; $this->nome_acao = "Novo"; } $this->largura = "100%"; $localizacao = new LocalizacaoSistema(); $localizacao->entradaCaminhos(array($_SERVER['SERVER_NAME'] . "/intranet" => "Início", "educar_biblioteca_index.php" => "i-Educar - Biblioteca", "" => "Listagem de exemplares")); $this->enviaLocalizacao($localizacao->montar()); }
function Gerar() { @session_start(); $this->pessoa_logada = $_SESSION['id_pessoa']; session_write_close(); $this->titulo = "Editora - Listagem"; foreach ($_GET as $var => $val) { // passa todos os valores obtidos no GET para atributos do objeto $this->{$var} = $val === "" ? null : $val; } $this->addCabecalhos(array("Editora", "Estado", "Cidade", "Biblioteca")); $get_escola = true; $get_biblioteca = true; $get_cabecalho = "lista_busca"; include "include/pmieducar/educar_campo_lista.php"; $this->campoTexto("nm_editora", "Editora", $this->nm_editora, 30, 255, false); // Filtros de Foreign Keys $opcoes = array("" => "Selecione"); if (class_exists("clsUf")) { $objTemp = new clsUf(); $lista = $objTemp->lista(); if (is_array($lista) && count($lista)) { foreach ($lista as $registro) { $opcoes["{$registro['sigla_uf']}"] = "{$registro['nome']}"; } } } else { echo "<!--\nErro\nClasse clsUf não encontrada\n-->"; $opcoes = array("" => "Erro na geração"); } $this->campoLista("ref_sigla_uf", "Estado", $opcoes, $this->ref_sigla_uf, null, null, null, null, null, false); // outros Filtros $this->campoTexto("cidade", "Cidade", $this->cidade, 30, 60, false); // Paginador $this->limite = 20; $this->offset = $_GET["pagina_{$this->nome}"] ? $_GET["pagina_{$this->nome}"] * $this->limite - $this->limite : 0; if (!is_numeric($this->ref_cod_biblioteca)) { $obj_bib_user = new clsPmieducarBibliotecaUsuario(); $this->ref_cod_biblioteca = $obj_bib_user->listaBibliotecas($this->pessoa_logada); } $obj_acervo_editora = new clsPmieducarAcervoEditora(); $obj_acervo_editora->setOrderby("nm_editora ASC"); $obj_acervo_editora->setLimite($this->limite, $this->offset); $lista = $obj_acervo_editora->lista(null, null, null, null, $this->ref_sigla_uf, $this->nm_editora, null, $this->cidade, null, null, null, null, null, null, null, null, null, 1, $this->ref_cod_biblioteca); $total = $obj_acervo_editora->_total; // monta a lista if (is_array($lista) && count($lista)) { foreach ($lista as $registro) { if (class_exists("clsUf")) { $obj_ref_sigla_uf = new clsUf($registro["ref_sigla_uf"]); $det_ref_sigla_uf = $obj_ref_sigla_uf->detalhe(); $registro["ref_sigla_uf"] = $det_ref_sigla_uf["nome"]; } else { $registro["ref_sigla_uf"] = "Erro na geração"; echo "<!--\nErro\nClasse não existente: clsUf\n-->"; } $obj_biblioteca = new clsPmieducarBiblioteca($registro['ref_cod_biblioteca']); $det_biblioteca = $obj_biblioteca->detalhe(); $registro['ref_cod_biblioteca'] = $det_biblioteca['nm_biblioteca']; $this->addLinhas(array("<a href=\"educar_acervo_editora_det.php?cod_acervo_editora={$registro["cod_acervo_editora"]}\">{$registro["nm_editora"]}</a>", "<a href=\"educar_acervo_editora_det.php?cod_acervo_editora={$registro["cod_acervo_editora"]}\">{$registro["ref_sigla_uf"]}</a>", "<a href=\"educar_acervo_editora_det.php?cod_acervo_editora={$registro["cod_acervo_editora"]}\">{$registro["cidade"]}</a>", "<a href=\"educar_acervo_editora_det.php?cod_acervo_editora={$registro["cod_acervo_editora"]}\">{$registro["ref_cod_biblioteca"]}</a>")); } } $this->addPaginador2("educar_acervo_editora_lst.php", $total, $_GET, $this->nome, $this->limite); $obj_permissoes = new clsPermissoes(); if ($obj_permissoes->permissao_cadastra(595, $this->pessoa_logada, 11)) { $this->acao = "go(\"educar_acervo_editora_cad.php\")"; $this->nome_acao = "Novo"; } $this->largura = "100%"; $localizacao = new LocalizacaoSistema(); $localizacao->entradaCaminhos(array($_SERVER['SERVER_NAME'] . "/intranet" => "Início", "educar_biblioteca_index.php" => "i-Educar - Biblioteca", "" => "Listagem de editoras")); $this->enviaLocalizacao($localizacao->montar()); }
function Gerar() { if ($_POST) { foreach ($_POST as $campo => $val) { $this->{$campo} = $this->{$campo} ? $this->{$campo} : $val; } } if (is_numeric($this->colecao)) { $this->ref_cod_acervo_colecao = $this->colecao; } if (is_numeric($this->editora)) { $this->ref_cod_acervo_editora = $this->editora; } if (is_numeric($this->idioma)) { $this->ref_cod_acervo_idioma = $this->idioma; } if (is_numeric($this->autor)) { $this->ref_cod_acervo_autor = $this->autor; } // primary keys $this->campoOculto("cod_acervo", $this->cod_acervo); $this->campoOculto("colecao", ""); $this->campoOculto("editora", ""); $this->campoOculto("idioma", ""); $this->campoOculto("autor", ""); $get_escola = 1; $escola_obrigatorio = false; $get_biblioteca = 1; $instituicao_obrigatorio = true; $biblioteca_obrigatorio = true; include "include/pmieducar/educar_campo_lista.php"; // foreign keys /*$opcoes = array( "" => "Selecione" ); if( class_exists( "clsPmieducarExemplarTipo" ) ) { $objTemp = new clsPmieducarExemplarTipo(); $lista = $objTemp->lista(null,null); if ( is_array( $lista ) && count( $lista ) ) { $tipos = "tipos = new Array();\n"; foreach ( $lista as $registro ) { $tipos .= "tipos[tipos.length] = new Array( {$registro["cod_exemplar_tipo"]}, '{$registro['nm_tipo']}', {$registro['ref_cod_biblioteca']});\n"; } echo "<script>{$tipos}</script>"; } } else { echo "<!--\nErro\nClasse clsPmieducarExemplarTipo nao encontrada\n-->"; }*/ $opcoes = array("NULL" => "Selecione"); if ($this->ref_cod_biblioteca) { $objTemp = new clsPmieducarExemplarTipo(); $lista = $objTemp->lista(null, $this->ref_cod_biblioteca); if (is_array($lista) && count($lista)) { foreach ($lista as $registro) { $opcoes["{$registro['cod_exemplar_tipo']}"] = "{$registro['nm_tipo']}"; } } } $this->campoLista("ref_cod_exemplar_tipo", "Exemplar Tipo", $opcoes, $this->ref_cod_exemplar_tipo); $opcoes = array("NULL" => "Selecione"); if ($this->ref_cod_acervo && $this->ref_cod_acervo != "NULL") { $objTemp = new clsPmieducarAcervo($this->ref_cod_acervo); $detalhe = $objTemp->detalhe(); if ($detalhe) { $opcoes["{$detalhe['cod_acervo']}"] = "{$detalhe['titulo']}"; } } //campoListaPesq( $nome, $campo, $valor, $default, $caminho="", $acao = "" , $duplo=false, $descricao="", $descricao2="", $flag=null, $pag_cadastro = null, $disabled = "", $div = false, $serializedcampos = false, $obrigatorio = false ) // $this->campoListaPesq( "ref_cod_acervo", "Obra Referência", $opcoes, $this->ref_cod_acervo,"educar_pesquisa_acervo_lst.php?campo1=ref_cod_acervo","","","","","","","",true ); $this->campoLista("ref_cod_acervo", "Obra Referência", $opcoes, $this->ref_cod_acervo, "", false, "", "<img border=\"0\" onclick=\"pesquisa();\" id=\"ref_cod_acervo_lupa\" name=\"ref_cod_acervo_lupa\" src=\"imagens/lupa.png\"\\/>", false, false); $opcoes = array("" => "Selecione"); if (class_exists("clsPmieducarAcervoColecao")) { $objTemp = new clsPmieducarAcervoColecao(); $lista = $objTemp->lista(); if (is_array($lista) && count($lista)) { foreach ($lista as $registro) { $opcoes["{$registro['cod_acervo_colecao']}"] = "{$registro['nm_colecao']}"; } } } else { echo "<!--\nErro\nClasse clsPmieducarAcervoColecao nao encontrada\n-->"; $opcoes = array("" => "Erro na geracao"); } $this->campoLista("ref_cod_acervo_colecao", "Coleção", $opcoes, $this->ref_cod_acervo_colecao, "", false, "", "<img id='img_colecao' src='imagens/banco_imagens/escreve.gif' style='cursor:hand; cursor:pointer;' border='0' onclick=\"showExpansivelImprimir(500, 200,'educar_acervo_colecao_cad_pop.php',[], 'Coleção')\" />", false, false); //"<img id='imgLupa' src=\"imagens/lupa.png\" border=\"0\" onclick=\"pesquisa_valores_popless( 'pesquisa_funcionario_lst.php?campos=".$parametros->serializaCampos()."&importa_cpf=true&chave_campo='+/[0-9]+/.exec(this.previousSibling.previousSibling.id)[0], this.previousSibling.previousSibling.id ); \" /> $opcoes = array("" => "Selecione"); if (class_exists("clsPmieducarAcervoIdioma")) { $objTemp = new clsPmieducarAcervoIdioma(); $lista = $objTemp->lista(); if (is_array($lista) && count($lista)) { foreach ($lista as $registro) { $opcoes["{$registro['cod_acervo_idioma']}"] = "{$registro['nm_idioma']}"; } } } else { echo "<!--\nErro\nClasse clsPmieducarAcervoIdioma nao encontrada\n-->"; $opcoes = array("" => "Erro na geracao"); } $this->campoLista("ref_cod_acervo_idioma", "Idioma", $opcoes, $this->ref_cod_acervo_idioma, "", false, "", "<img id='img_idioma' src='imagens/banco_imagens/escreve.gif' style='cursor:hand; cursor:pointer;' border='0' onclick=\"showExpansivelImprimir(400, 150,'educar_acervo_idioma_cad_pop.php',[], 'Idioma')\" />"); $opcoes = array("" => "Selecione"); if (class_exists("clsPmieducarAcervoEditora")) { $objTemp = new clsPmieducarAcervoEditora(); $lista = $objTemp->lista(); if (is_array($lista) && count($lista)) { foreach ($lista as $registro) { $opcoes["{$registro['cod_acervo_editora']}"] = "{$registro['nm_editora']}"; } } } else { echo "<!--\nErro\nClasse clsPmieducarAcervoEditora nao encontrada\n-->"; $opcoes = array("" => "Erro na geracao"); } $this->campoLista("ref_cod_acervo_editora", "Editora", $opcoes, $this->ref_cod_acervo_editora, "", false, "", "<img id='img_editora' src='imagens/banco_imagens/escreve.gif' style='cursor:hand; cursor:pointer;' border='0' onclick=\"showExpansivelImprimir(400, 320,'educar_acervo_editora_cad_pop.php',[], 'Editora')\" />"); //-----------------------INCLUI AUTOR------------------------// $this->campoQuebra(); if ($_POST["acervo_autor"]) { $this->acervo_autor = unserialize(urldecode($_POST["acervo_autor"])); } if (is_numeric($this->cod_acervo) && !$_POST) { $obj = new clsPmieducarAcervoAcervoAutor(); $registros = $obj->lista(null, $this->cod_acervo); if ($registros) { foreach ($registros as $campo) { $aux["ref_cod_acervo_autor_"] = $campo["ref_cod_acervo_autor"]; $aux["principal_"] = $campo["principal"]; $this->acervo_autor[] = $aux; } // verifica se ja existe um autor principal if (is_array($this->acervo_autor)) { foreach ($this->acervo_autor as $autores) { if ($autores["principal_"] == 1) { $this->checked = 1; $this->campoOculto("checked", $this->checked); } } } } } unset($aux); if ($_POST["ref_cod_acervo_autor"]) { if ($_POST["principal"]) { $this->checked = 1; $this->campoOculto("checked", $this->checked); } $aux["ref_cod_acervo_autor_"] = $_POST["ref_cod_acervo_autor"]; $aux["principal_"] = $_POST["principal"]; $this->acervo_autor[] = $aux; // echo "<pre>";print_r($this->acervo_autor); // verifica se ja existe um autor principal if (is_array($this->acervo_autor)) { foreach ($this->acervo_autor as $autores) { if ($autores["principal_"] == 'on') { $this->checked = 1; $this->campoOculto("checked", $this->checked); } } } unset($this->ref_cod_acervo_autor); unset($this->principal); } $this->campoOculto("excluir_autor", ""); unset($aux); if ($this->acervo_autor) { foreach ($this->acervo_autor as $key => $autor) { if ($this->excluir_autor == $autor["ref_cod_acervo_autor_"]) { unset($this->acervo_autor[$key]); unset($this->excluir_autor); } else { $obj_acervo_autor = new clsPmieducarAcervoAutor($autor["ref_cod_acervo_autor_"]); $det_acervo_autor = $obj_acervo_autor->detalhe(); $nm_autor = $det_acervo_autor["nm_autor"]; $this->campoTextoInv("ref_cod_exemplar_tipo_{$autor["ref_cod_acervo_autor_"]}", "", $nm_autor, 30, 255, false, false, true); $this->campoCheck("principal_{$autor["ref_cod_acervo_autor_"]}", "", $autor['principal_'], "<a href='#' onclick=\"getElementById('excluir_autor').value = '{$autor["ref_cod_acervo_autor_"]}'; getElementById('tipoacao').value = ''; {$this->__nome}.submit();\"><img src='imagens/nvp_bola_xis.gif' title='Excluir' border=0></a>", false, false, true); $aux["ref_cod_acervo_autor_"] = $autor["ref_cod_acervo_autor_"]; $aux["principal_"] = $autor['principal_']; } } } $this->campoOculto("acervo_autor", serialize($this->acervo_autor)); if (class_exists("clsPmieducarAcervoAutor")) { $opcoes = array("" => "Selecione"); $objTemp = new clsPmieducarAcervoAutor(); $objTemp->setOrderby("nm_autor ASC"); $lista = $objTemp->lista(null, null, null, null, null, null, null, null, null, 1); if (is_array($lista) && count($lista)) { foreach ($lista as $registro) { $opcoes["{$registro['cod_acervo_autor']}"] = "{$registro['nm_autor']}"; } } } else { echo "<!--\nErro\nClasse clsPmieducarAcervoAutor não encontrada\n-->"; $opcoes = array("" => "Erro na geração"); } if (is_array($this->acervo_autor)) { $qtd_autor = count($this->acervo_autor); } // não existe um autor principal nem autor if ($this->checked != 1 && (!$qtd_autor || $qtd_autor == 0)) { // die("1"); $this->campoLista("ref_cod_acervo_autor", "Autor", $opcoes, $this->ref_cod_acervo_autor, null, true, "", "", false, true); $this->campoCheck("principal", " <img id='img_autor' src='imagens/banco_imagens/escreve.gif' style='cursor:hand; cursor:pointer;' border='0' onclick=\"showExpansivelImprimir(500, 250,'educar_acervo_autor_cad_pop.php',[], 'Autor')\" /> Principal", $this->principal, "<a href='#' onclick=\"getElementById('incluir_autor').value = 'S'; getElementById('tipoacao').value = ''; {$this->__nome}.submit();\"><img src='imagens/nvp_bot_adiciona.gif' title='Incluir' border=0></a>"); } else { if ($this->checked != 1 && $qtd_autor > 0) { // echo "principal ".$this->checked; // echo "is_array($this->acervo_autor)"; // print_r($this->acervo_autor); // // die("2"); $this->campoLista("ref_cod_acervo_autor", "Autor", $opcoes, $this->ref_cod_acervo_autor, null, true, null, null, null, false); $this->campoCheck("principal", " <img src='imagens/banco_imagens/escreve.gif' style='cursor:hand; cursor:pointer;' border='0' onclick=\"pesquisa_valores_popless( 'educar_acervo_autor_cad_pop.php' )\" /> Principal", $this->principal, "<a href='#' onclick=\"getElementById('incluir_autor').value = 'S'; getElementById('tipoacao').value = ''; {$this->__nome}.submit();\"><img src='imagens/nvp_bot_adiciona.gif' title='Incluir' border=0></a>"); } else { // die("3"); $this->campoLista("ref_cod_acervo_autor", "Autor", $opcoes, $this->ref_cod_acervo_autor, "", false, "", "<img src='imagens/banco_imagens/escreve.gif' style='cursor:hand; cursor:pointer;' border='0' onclick=\"pesquisa_valores_popless( 'educar_acervo_autor_cad_pop.php' )\" /> <a href='#' onclick=\"getElementById('incluir_autor').value = 'S'; getElementById('tipoacao').value = ''; {$this->__nome}.submit();\"><img src='imagens/nvp_bot_adiciona.gif' title='Incluir' border=0></a>", false, false); } } $this->campoOculto("incluir_autor", ""); // $this->campoRotulo( "bt_incluir_autor", "Autor", "<a href='#' onclick=\"getElementById('incluir_autor').value = 'S'; getElementById('tipoacao').value = ''; {$this->__nome}.submit();\"><img src='imagens/nvp_bot_incluir2.gif' title='Incluir' border=0></a>" ); $this->campoQuebra(); //-----------------------FIM AUTOR------------------------// // text $this->campoTexto("titulo", "Título", $this->titulo, 40, 255, true); $this->campoTexto("sub_titulo", "Subtítulo", $this->sub_titulo, 40, 255, false); $this->campoTexto("cdu", "Cdu", $this->cdu, 20, 15, false); $this->campoTexto("cutter", "Cutter", $this->cutter, 20, 15, false); $this->campoNumero("volume", "Volume", $this->volume, 20, 255, true); $this->campoNumero("num_edicao", "Número Edicão", $this->num_edicao, 20, 255, true); $this->campoNumero("ano", "Ano", $this->ano, 5, 4, true); $this->campoNumero("num_paginas", "Número Páginas", $this->num_paginas, 5, 255, true); $this->campoNumero("isbn", "ISBN", $this->isbn, 20, 255, true); }
function Gerar() { @session_start(); $this->pessoa_logada = $_SESSION['id_pessoa']; session_write_close(); $this->titulo = "Obras - Listagem"; foreach ($_GET as $var => $val) { // passa todos os valores obtidos no GET para atributos do objeto $this->{$var} = $val === "" ? null : $val; } $this->addBanner("imagens/nvp_top_intranet.jpg", "imagens/nvp_vert_intranet.jpg", "Intranet"); $lista_busca = array("Obra"); // Filtros de Foreign Keys $get_escola = true; $get_biblioteca = true; $get_cabecalho = "lista_busca"; include "include/pmieducar/educar_campo_lista.php"; $this->addCabecalhos($lista_busca); $opcoes_colecao = array(); $opcoes_colecao[""] = "Selecione"; $opcoes_exemplar = array(); $opcoes_exemplar[""] = "Selecione"; $opcoes_editora = array(); $opcoes_editora[""] = "Selecione"; if (is_numeric($this->ref_cod_biblioteca)) { $obj_colecao = new clsPmieducarAcervoColecao(); $obj_colecao->setOrderby("nm_colecao ASC"); $obj_colecao->setCamposLista("cod_acervo_colecao, nm_colecao"); $lst_colecao = $obj_colecao->lista(null, null, null, null, null, null, null, null, null, 1, $this->ref_cod_biblioteca); if (is_array($opcoes)) { foreach ($lst_colecao as $colecao) { $opcoes_colecao[$colecao["cod_acervo_colecao"]] = $colecao["nm_colecao"]; } } $obj_tp_exemplar = new clsPmieducarExemplarTipo(); $obj_tp_exemplar->setCamposLista("cod_exemplar_tipo, nm_tipo"); $obj_tp_exemplar->setOrderby("nm_tipo ASC"); $lst_tp_exemplar = $obj_tp_exemplar->lista(null, $this->ref_cod_biblioteca, null, null, null, null, null, null, null, null, 1); if (is_array($lst_tp_exemplar)) { foreach ($lst_tp_exemplar as $tp_exemplar) { $opcoes_exemplar[$tp_exemplar["cod_exemplar_tipo"]] = $tp_exemplar["nm_tipo"]; } } $obj_editora = new clsPmieducarAcervoEditora(); $obj_editora->setCamposLista("cod_acervo_editora, nm_editora"); $obj_editora->setOrderby("nm_editora ASC"); $lst_editora = $obj_editora->lista(null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, 1, $this->ref_cod_biblioteca); if (is_array($lst_editora)) { foreach ($lst_editora as $editora) { $opcoes_editora[$editora["cod_acervo_editora"]] = $editora["nm_editora"]; } } } $this->campoLista("ref_cod_acervo_colecao", "Acervo Coleção", $opcoes_colecao, $this->ref_cod_acervo_colecao, "", false, "", "", false, false); $this->campoLista("ref_cod_exemplar_tipo", "Tipo Exemplar", $opcoes_exemplar, $this->ref_cod_exemplar_tipo, "", false, "", "", false, false); $this->campoLista("ref_cod_acervo_editora", "Editora", $opcoes_editora, $this->ref_cod_acervo_editora, "", false, "", "", false, false); $objTemp = new clsPmieducarAcervoAssunto(); $lista = $objTemp->lista(); if (is_array($lista) && count($lista)) { foreach ($lista as $registro) { $opcoes[$registro['cod_acervo_assunto']] = $registro['nm_assunto']; } } $this->campoLista('ref_cod_assunto_acervo', 'Assunto', $opcoes, $this->ref_cod_assunto_acervo, '', FALSE, '', '', FALSE, FALSE); $this->campoTexto("titulo_livro", "Titulo", $this->titulo_livro, 30, 255, false); // Paginador $this->limite = 20; $this->offset = $_GET["pagina_{$this->nome}"] ? $_GET["pagina_{$this->nome}"] * $this->limite - $this->limite : 0; if (!is_numeric($this->ref_cod_biblioteca)) { $obj_bib_user = new clsPmieducarBibliotecaUsuario(); $this->ref_cod_biblioteca = $obj_bib_user->listaBibliotecas($this->pessoa_logada); } $obj_acervo = new clsPmieducarAcervo(); $obj_acervo->setOrderby("titulo ASC"); $obj_acervo->setLimite($this->limite, $this->offset); $obj_acervo->ref_cod_acervo_assunto = $this->ref_cod_assunto_acervo; $lista = $obj_acervo->listaAcervoBiblioteca($this->ref_cod_biblioteca, $this->titulo_livro, 1, $this->ref_cod_acervo_colecao, $this->ref_cod_exemplar_tipo, $this->ref_cod_acervo_editora); /*$lista = $obj_acervo->lista( null, null, null, null, null, null, null, null, $this->titulo_livro, null, null, null, null, null, null, null, null, null, null, null, null, 1, $this->ref_cod_biblioteca, $this->ref_cod_instituicao, $this->ref_cod_escola );*/ $total = $obj_acervo->_total; // monta a lista if (is_array($lista) && count($lista)) { foreach ($lista as $registro) { // pega detalhes de foreign_keys if (class_exists("clsPmieducarBiblioteca")) { $obj_ref_cod_biblioteca = new clsPmieducarBiblioteca($registro["ref_cod_biblioteca"]); $det_ref_cod_biblioteca = $obj_ref_cod_biblioteca->detalhe(); $registro["ref_cod_biblioteca"] = $det_ref_cod_biblioteca["nm_biblioteca"]; $registro["ref_cod_instituicao"] = $det_ref_cod_biblioteca["ref_cod_instituicao"]; $registro["ref_cod_escola"] = $det_ref_cod_biblioteca["ref_cod_escola"]; if ($registro["ref_cod_instituicao"]) { $obj_ref_cod_instituicao = new clsPmieducarInstituicao($registro["ref_cod_instituicao"]); $det_ref_cod_instituicao = $obj_ref_cod_instituicao->detalhe(); $registro["ref_cod_instituicao"] = $det_ref_cod_instituicao["nm_instituicao"]; } if ($registro["ref_cod_escola"]) { $obj_ref_cod_escola = new clsPmieducarEscola(); $det_ref_cod_escola = array_shift($obj_ref_cod_escola->lista($registro["ref_cod_escola"])); $registro["ref_cod_escola"] = $det_ref_cod_escola["nome"]; } } else { $registro["ref_cod_biblioteca"] = "Erro na geracao"; echo "<!--\nErro\nClasse nao existente: clsPmieducarBiblioteca\n-->"; } $lista_busca = array("<a href=\"educar_acervo_det.php?cod_acervo={$registro["cod_acervo"]}\">{$registro["titulo"]}</a>"); if ($qtd_bibliotecas > 1 && ($nivel_usuario == 4 || $nivel_usuario == 8)) { $lista_busca[] = "<a href=\"educar_acervo_det.php?cod_acervo={$registro["cod_acervo"]}\">{$registro["ref_cod_biblioteca"]}</a>"; } else { if ($nivel_usuario == 1 || $nivel_usuario == 2 || $nivel_usuario == 4) { $lista_busca[] = "<a href=\"educar_acervo_det.php?cod_acervo={$registro["cod_acervo"]}\">{$registro["ref_cod_biblioteca"]}</a>"; } } if ($nivel_usuario == 1 || $nivel_usuario == 2) { $lista_busca[] = "<a href=\"educar_acervo_det.php?cod_acervo={$registro["cod_acervo"]}\">{$registro["ref_cod_escola"]}</a>"; } if ($nivel_usuario == 1) { $lista_busca[] = "<a href=\"educar_acervo_det.php?cod_acervo={$registro["cod_acervo"]}\">{$registro["ref_cod_instituicao"]}</a>"; } $this->addLinhas($lista_busca); } } $this->addPaginador2("educar_acervo_lst.php", $total, $_GET, $this->nome, $this->limite); $obj_permissoes = new clsPermissoes(); if ($obj_permissoes->permissao_cadastra(598, $this->pessoa_logada, 11)) { $this->acao = "go(\"educar_acervo_cad.php\")"; $this->nome_acao = "Novo"; } $this->largura = "100%"; $localizacao = new LocalizacaoSistema(); $localizacao->entradaCaminhos(array($_SERVER['SERVER_NAME'] . "/intranet" => "i-Educar", "educar_biblioteca_index.php" => "Biblioteca", "" => "Lista de Obras")); $this->enviaLocalizacao($localizacao->montar()); }