From a6c97bf6599a37a3ab1f3dae53c50d97f22bebfc Mon Sep 17 00:00:00 2001 From: Edmar Moretti Date: Tue, 14 May 2013 19:12:52 +0000 Subject: [PATCH] Inclusão de uma árvore como forma de escolha de temas no publicador de aplicações (metaestat) --- admin/js/core.js | 415 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ admin/js/estat_mapa.js | 137 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++---------------------------------------------------------- admin/php/metaestat.php | 65 +++++++++++++++++++++++++++++++++++++---------------------------- 3 files changed, 351 insertions(+), 266 deletions(-) diff --git a/admin/js/core.js b/admin/js/core.js index b42bfeb..00d7dc6 100644 --- a/admin/js/core.js +++ b/admin/js/core.js @@ -209,6 +209,61 @@ function cabecalhoGeral(id,excluir){ //temp.style.padding = "10px"; } /* +Function: core_arvore + +Cria uma arvore com base em um objeto contendo as propriedades. + +No objeto com as propriedades, se "url" for igual a "", sera incluido o texto original definido em "text". + +Parametros: + +titulo - {String} cabecalho da arvore + +onde - {String} nome do id doelemento que contera a arvore + +obj - {Object} objeto contendo os parametros, exemplo + + g_listaPropriedades = { + + "propriedades": [ + + { text: "p2", url: "javascript:tipoimagem()" } + + ]} + +*/ +function core_arvore(titulo,onde,obj){ + var arvore,root,tempNode,d,c,i,linha,conteudo,j,temaNode; + if(!$i(onde)){return;} + arvore = new YAHOO.widget.TreeView(onde); + root = arvore.getRoot(); + try{ + tempNode = new YAHOO.widget.TextNode('', root, false); + tempNode.isLeaf = false; + tempNode.enableHighlight = false; + } + catch(e){ + if(typeof(console) !== 'undefined'){console.error(e);} + } + titulo = "
"+titulo+"
"; + d = {html:titulo}; + tempNode = new YAHOO.widget.HTMLNode(d, root, true,true); + tempNode.enableHighlight = false; + c = obj.propriedades.length; + for (i=0, j=c; i"+linha.text+"";} + else + {conteudo = linha.text;} + d = {html:conteudo}; + temaNode = new YAHOO.widget.HTMLNode(d, tempNode, false,true); + temaNode.enableHighlight = false; + } + arvore.collapseAll(); + arvore.draw(); +} +/* Function: core_movimentaNo Movimenta um nó para cima ou para baixo na árvore. @@ -413,17 +468,17 @@ function core_dialogoContinua(handleYes,handleNo,mensagem,largura,cabecalho) YAHOO.namespace("continua.container"); YAHOO.continua.container.simpledialog1 = new YAHOO.widget.SimpleDialog("simpledialog1", - { width: largura+"px", - fixedcenter: true, - visible: false, - draggable: false, - close: true, - text: mensagem, - icon: YAHOO.widget.SimpleDialog.ICON_HELP, - modal: true, - constraintoviewport: true, - buttons: [ { text:"Sim", handler:handleYes, isDefault:true }, - { text:"Não", handler:handleNo } ] + { width: largura+"px", + fixedcenter: true, + visible: false, + draggable: false, + close: true, + text: mensagem, + icon: YAHOO.widget.SimpleDialog.ICON_HELP, + modal: true, + constraintoviewport: true, + buttons: [ { text:"Sim", handler:handleYes, isDefault:true }, + { text:"Não", handler:handleNo } ] } ); YAHOO.continua.container.simpledialog1.setHeader(cabecalho); YAHOO.continua.container.simpledialog1.render(document.body); @@ -450,17 +505,17 @@ function core_dialogoPergunta(handleYes,handleNo,mensagem,largura) YAHOO.namespace("continua.container"); YAHOO.continua.container.simpledialog1 = new YAHOO.widget.SimpleDialog("simpledialog1", - { width: largura+"px", - fixedcenter: true, - visible: false, - draggable: false, - close: true, - text: mensagem, - icon: "", - modal: true, - constraintoviewport: true, - buttons: [ { text:"Continua", handler:handleYes, isDefault:true }, - { text:"Cancela", handler:handleNo } ] + { width: largura+"px", + fixedcenter: true, + visible: false, + draggable: false, + close: true, + text: mensagem, + icon: "", + modal: true, + constraintoviewport: true, + buttons: [ { text:"Continua", handler:handleYes, isDefault:true }, + { text:"Cancela", handler:handleNo } ] } ); //YAHOO.continua.container.simpledialog1.setHeader("Tem certeza?"); YAHOO.continua.container.simpledialog1.render(document.body); @@ -526,21 +581,21 @@ function core_pegaPerfis(funcao) var sUrl = "../php/menutemas.php?funcao=pegaPerfis"; var callback = { - success:function(o) - { - try - { - $perfis = YAHOO.lang.JSON.parse(o.responseText); - $perfisArray = new Array(); - for (var i=0;i<$perfis.length;i++) - {$perfisArray.push($perfis[i].perfil);} - if(funcao != "") - eval(funcao); - } - catch(e){core_handleFailure(o,o.responseText);} - }, - failure:core_handleFailure, - argument: { foo:"foo", bar:"bar" } + success:function(o) + { + try + { + $perfis = YAHOO.lang.JSON.parse(o.responseText); + $perfisArray = new Array(); + for (var i=0;i<$perfis.length;i++) + {$perfisArray.push($perfis[i].perfil);} + if(funcao != "") + eval(funcao); + } + catch(e){core_handleFailure(o,o.responseText);} + }, + failure:core_handleFailure, + argument: { foo:"foo", bar:"bar" } }; core_makeRequest(sUrl,callback); } @@ -576,18 +631,18 @@ function core_pegaMapfiles(funcaoM,letra,filtro) var sUrl = "../php/menutemas.php?funcao=listaMapsTemas&letra="+letra+"&filtro="+filtro; var callbackM = { - success:function(o) - { - try - { - $mapfiles = YAHOO.lang.JSON.parse(o.responseText); - if(funcaoM != "") - eval(funcaoM); - } - catch(e){core_handleFailure(o,o.responseText);} - }, - failure:core_handleFailure, - argument: { foo:"foo", bar:"bar" } + success:function(o) + { + try + { + $mapfiles = YAHOO.lang.JSON.parse(o.responseText); + if(funcaoM != "") + eval(funcaoM); + } + catch(e){core_handleFailure(o,o.responseText);} + }, + failure:core_handleFailure, + argument: { foo:"foo", bar:"bar" } }; core_makeRequest(sUrl,callbackM); } @@ -683,11 +738,11 @@ function core_comboPranchas(onde,id,marcar,funcao,id_atlas) var sUrl = "../php/atlas.php?funcao=pegaPranchas&id_atlas="+id_atlas; var callback = { - success:function(o) - { - try - { - var valores = YAHOO.lang.JSON.parse(o.responseText); + success:function(o) + { + try + { + var valores = YAHOO.lang.JSON.parse(o.responseText); if(arguments.length == 3) {funcao = "";} if (funcao != "") @@ -696,11 +751,11 @@ function core_comboPranchas(onde,id,marcar,funcao,id_atlas) ins += core_comboObjeto(valores,"id_prancha","titulo_prancha",marcar); ins += "

"; $i(onde).innerHTML = ins; - } - catch(e){core_handleFailure(e,o.responseText);} - }, - failure:core_handleFailure, - argument: { foo:"foo", bar:"bar" } + } + catch(e){core_handleFailure(e,o.responseText);} + }, + failure:core_handleFailure, + argument: { foo:"foo", bar:"bar" } }; core_makeRequest(sUrl,callback); } @@ -726,11 +781,11 @@ function core_comboGrupos(onde,id,marcar,funcao) var sUrl = "../php/menutemas.php?funcao=pegaGrupos"; var callback = { - success:function(o) - { - try - { - var valores = YAHOO.lang.JSON.parse(o.responseText); + success:function(o) + { + try + { + var valores = YAHOO.lang.JSON.parse(o.responseText); if(arguments.length == 3) {funcao = "";} if (funcao != "") @@ -739,11 +794,11 @@ function core_comboGrupos(onde,id,marcar,funcao) ins += core_comboObjeto(valores,"id_grupo","nome_grupo",marcar); ins += "

"; $i(onde).innerHTML = ins; - } - catch(e){core_handleFailure(e,o.responseText);} - }, - failure:core_handleFailure, - argument: { foo:"foo", bar:"bar" } + } + catch(e){core_handleFailure(e,o.responseText);} + }, + failure:core_handleFailure, + argument: { foo:"foo", bar:"bar" } }; core_makeRequest(sUrl,callback); } @@ -769,11 +824,11 @@ function core_comboSubGrupos(onde,id,marcar,funcao) var sUrl = "../php/menutemas.php?funcao=pegaSubGrupos"; var callback = { - success:function(o) - { - try - { - var valores = YAHOO.lang.JSON.parse(o.responseText); + success:function(o) + { + try + { + var valores = YAHOO.lang.JSON.parse(o.responseText); if(arguments.length == 3) {funcao = "";} if (funcao != "") @@ -782,11 +837,11 @@ function core_comboSubGrupos(onde,id,marcar,funcao) ins += core_comboObjeto(valores,"id_subgrupo","nome_subgrupo",marcar); ins += "

"; $i(onde).innerHTML = ins; - } - catch(e){core_handleFailure(e,o.responseText);} - }, - failure:core_handleFailure, - argument: { foo:"foo", bar:"bar" } + } + catch(e){core_handleFailure(e,o.responseText);} + }, + failure:core_handleFailure, + argument: { foo:"foo", bar:"bar" } }; core_makeRequest(sUrl,callback); } @@ -812,11 +867,11 @@ function core_comboTemas(onde,id,marcar,funcao) var sUrl = "../php/menutemas.php?funcao=pegaTemas2"; var callback = { - success:function(o) - { - try - { - var valores = YAHOO.lang.JSON.parse(o.responseText); + success:function(o) + { + try + { + var valores = YAHOO.lang.JSON.parse(o.responseText); if(arguments.length == 3) {funcao = "";} if (funcao != "") @@ -825,11 +880,11 @@ function core_comboTemas(onde,id,marcar,funcao) ins += core_comboObjeto(valores,"id_tema","nome_tema",marcar,"codigo_tema"); ins += "

"; $i(onde).innerHTML = ins; - } - catch(e){core_handleFailure(e,o.responseText);} - }, - failure:core_handleFailure, - argument: { foo:"foo", bar:"bar" } + } + catch(e){core_handleFailure(e,o.responseText);} + }, + failure:core_handleFailure, + argument: { foo:"foo", bar:"bar" } }; core_makeRequest(sUrl,callback); } @@ -852,19 +907,19 @@ function core_pegaTags(funcao) var sUrl = "../php/menutemas.php?funcao=pegaTags"; var callback = { - success:function(o) - { - try - { - $tags = YAHOO.lang.JSON.parse(o.responseText); - if($tags == ""){$tags = " ";} - if(funcao != "") - eval(funcao); - } - catch(e){core_handleFailure(e,o.responseText);} - }, - failure:core_handleFailure, - argument: { foo:"foo", bar:"bar" } + success:function(o) + { + try + { + $tags = YAHOO.lang.JSON.parse(o.responseText); + if($tags == ""){$tags = " ";} + if(funcao != "") + eval(funcao); + } + catch(e){core_handleFailure(e,o.responseText);} + }, + failure:core_handleFailure, + argument: { foo:"foo", bar:"bar" } }; core_makeRequest(sUrl,callback); } @@ -1144,25 +1199,25 @@ function core_ativaBotaoAdicionaLinha(sUrl,idBotao,nomeFuncao) core_carregando(" adicionando um novo registro"); var callback = { - success:function(o) - { - var texto = ""; + success:function(o) + { + var texto = ""; try - { - core_carregando("desativa"); - if(nomeFuncao != "") - {eval(nomeFuncao+"()");} - else{ + { + core_carregando("desativa"); + if(nomeFuncao != "") + {eval(nomeFuncao+"()");} + else{ texto = YAHOO.lang.JSON.parse(o.responseText)[0]; if(texto === "") {texto = "Clique para editar";} myDataTable.addRow(texto,0); } - } - catch(e){core_handleFailure(e,o.responseText);} - }, - failure:core_handleFailure, - argument: { foo:"foo", bar:"bar" } + } + catch(e){core_handleFailure(e,o.responseText);} + }, + failure:core_handleFailure, + argument: { foo:"foo", bar:"bar" } }; core_makeRequest(sUrl,callback); }; @@ -1188,23 +1243,23 @@ function core_pegaDados(mensagem,sUrl,funcaoRetorno) core_carregando(mensagem); var callback = { - success:function(o) - { - try - { - if(funcaoRetorno != "") - {eval(funcaoRetorno+"(YAHOO.lang.JSON.parse(o.responseText))");} - core_carregando("desativa"); - } - catch(e) - { - if("mensagem" != "") - {core_carregando("desativa");} - core_handleFailure(o,o.responseText); - } - }, - failure:core_handleFailure, - argument: { foo:"foo", bar:"bar" } + success:function(o) + { + try + { + if(funcaoRetorno != "") + {eval(funcaoRetorno+"(YAHOO.lang.JSON.parse(o.responseText))");} + core_carregando("desativa"); + } + catch(e) + { + if("mensagem" != "") + {core_carregando("desativa");} + core_handleFailure(o,o.responseText); + } + }, + failure:core_handleFailure, + argument: { foo:"foo", bar:"bar" } }; core_makeRequest(sUrl,callback); } @@ -1233,8 +1288,8 @@ function core_gravaLinha(mensagem,row,sUrl,nomeFuncao) nomeFuncao = ""; var callback = { - success:function(o) - { + success:function(o) + { core_carregando("desativa"); var rec = myDataTable.getRecordSet().getRecord(row); var linha = myDataTable.getTrEl(rec); @@ -1248,12 +1303,12 @@ function core_gravaLinha(mensagem,row,sUrl,nomeFuncao) else { myDataTable.updateRow(rec,YAHOO.lang.JSON.parse(o.responseText)[0]); - } + } linha.style.color = ""; linha.style.textDecoration = "none"; - }, - failure:core_handleFailure, - argument: { foo:"foo", bar:"bar" } + }, + failure:core_handleFailure, + argument: { foo:"foo", bar:"bar" } }; core_makeRequest(sUrl,callback); } @@ -1286,30 +1341,30 @@ function core_excluiLinha(sUrl,row,mensagem,cabecalho,tabela) core_carregando(mensagem); var callback = { - success:function(o) - { - try - { - if(YAHOO.lang.JSON.parse(o.responseText) == "erro") - { - core_carregando("Não foi possível excluir. Verifique se não existem outras tabelas com registros vinculados a este"); - setTimeout("core_carregando('desativa')",3000); - } - else - { - if(tabela){ - tabela.deleteRow(row); - } - else{ - myDataTable.deleteRow(row); - } - core_carregando("desativa"); - } - } - catch(e){core_handleFailure(o,o.responseText);} - }, - failure:core_handleFailure, - argument: { foo:"foo", bar:"bar" } + success:function(o) + { + try + { + if(YAHOO.lang.JSON.parse(o.responseText) == "erro") + { + core_carregando("Não foi possível excluir. Verifique se não existem outras tabelas com registros vinculados a este"); + setTimeout("core_carregando('desativa')",3000); + } + else + { + if(tabela){ + tabela.deleteRow(row); + } + else{ + myDataTable.deleteRow(row); + } + core_carregando("desativa"); + } + } + catch(e){core_handleFailure(o,o.responseText);} + }, + failure:core_handleFailure, + argument: { foo:"foo", bar:"bar" } }; core_makeRequest(sUrl,callback); }; @@ -1349,28 +1404,28 @@ function core_excluiNoTree(sUrl,no,mensagem,cabecalho) core_carregando(mensagem); var callback = { - success:function(o) - { - try - { - if(YAHOO.lang.JSON.parse(o.responseText) == "erro") - { - core_carregando("Não foi possível excluir. Verifique se não existem outras tabelas com registros vinculados a este"); - setTimeout("core_carregando('desativa')",3000); - } - else - { + success:function(o) + { + try + { + if(YAHOO.lang.JSON.parse(o.responseText) == "erro") + { + core_carregando("Não foi possível excluir. Verifique se não existem outras tabelas com registros vinculados a este"); + setTimeout("core_carregando('desativa')",3000); + } + else + { if(no){ tree.removeNode(no); tree.draw(); - } + } core_carregando("desativa"); - } - } - catch(e){core_handleFailure(o,o.responseText);} - }, - failure:core_handleFailure, - argument: { foo:"foo", bar:"bar" } + } + } + catch(e){core_handleFailure(o,o.responseText);} + }, + failure:core_handleFailure, + argument: { foo:"foo", bar:"bar" } }; core_makeRequest(sUrl,callback); }; diff --git a/admin/js/estat_mapa.js b/admin/js/estat_mapa.js index c7e0415..d486717 100755 --- a/admin/js/estat_mapa.js +++ b/admin/js/estat_mapa.js @@ -46,19 +46,19 @@ function ativaBotaoAdiciona(sUrl,idBotao) core_carregando(" adicionando um novo registro"); var callback = { - success:function(o) - { - try - { - var j = YAHOO.lang.JSON.parse(o.responseText); + success:function(o) + { + try + { + var j = YAHOO.lang.JSON.parse(o.responseText); adicionaNosMapa([j],true); editar("mapa",j.id_mapa); - core_carregando("desativa"); - } - catch(e){core_handleFailure(e,o.responseText);} - }, - failure:core_handleFailure, - argument: { foo:"foo", bar:"bar" } + core_carregando("desativa"); + } + catch(e){core_handleFailure(e,o.responseText);} + }, + failure:core_handleFailure, + argument: { foo:"foo", bar:"bar" } }; core_makeRequest(sUrl,callback); }; @@ -125,8 +125,8 @@ function montaArvore(dados) } buildTree(); }(); - adicionaNosMapa(dados); - tree.draw(); + adicionaNosMapa(dados); + tree.draw(); } function testarMapfile(codigoMap) { @@ -290,14 +290,35 @@ function editar(tipo,id) if(sUrl) {core_makeRequest(sUrl,callback);} } -function montaDivTema(i) -{ - var sUrl = "../php/metaestat.php?funcao=relatorioCompleto&dadosGerenciais=nao&detalhes=nao", +function montaDivTema(i){ + var sUrl = "../php/metaestat.php?funcao=arvoreVar&dadosGerenciais=nao&detalhes=nao", ins = "", callback = { success:function(o){ - ins += "
"+YAHOO.lang.JSON.parse(o.responseText)+"
"; + var o = YAHOO.lang.JSON.parse(o.responseText), + n = o.length, + m,i,j,filhos,a,b; + //monta os divs onde entrarao as arvores + for(i=0;i"+o[i].titulo+""; + } $i("editor_bd").innerHTML = ins; + //monta as arvores + for(i=0;i"; + //$i("editor_bd").innerHTML = ins; }, failure: function(){return ins;}, argument: { foo:"foo", bar:"bar" } @@ -305,7 +326,7 @@ function montaDivTema(i) param = { "linhas":[ {titulo:"Título:",id:"Etitulo",size:"50",value:i.titulo,tipo:"text",div:""}, - {titulo:"ID da medida de uma variável (veja em ID no relatório abaixo):",id:"Eid_medida_variavel",size:"50",value:i.id_medida_variavel,tipo:"text",div:""} + {titulo:"ID da medida de uma variável (clique nos links abaixo para escolher):",id:"Eid_medida_variavel",size:"50",value:i.id_medida_variavel,tipo:"text",div:""} ] }; ins += core_geraLinhas(param); @@ -433,8 +454,8 @@ function adicionarTema(id) adicionaNosTemas(no,[dados],true); editar('tema',dados.id_mapa_tema); }, - failure:core_handleFailure, - argument: { foo:"foo", bar:"bar" } + failure:core_handleFailure, + argument: { foo:"foo", bar:"bar" } }; core_makeRequest(sUrl,callback); } @@ -450,8 +471,8 @@ function adicionarGrupo(id_mapa) adicionaNosGrupos(no,[dados],true); editar('grupo',dados.id_mapa_grupo); }, - failure:core_handleFailure, - argument: { foo:"foo", bar:"bar" } + failure:core_handleFailure, + argument: { foo:"foo", bar:"bar" } }; core_makeRequest(sUrl,callback); } @@ -494,47 +515,47 @@ function gravaDados(tipo,id) var callback = { - success:function(o) - { - try - { - if(YAHOO.lang.JSON.parse(o.responseText) == "erro") - { - core_carregando("Não foi possível excluir. Verifique se não existem menus vinculados a este tema"); - setTimeout("core_carregando('desativa')",3000); - } - else - { - if(tipo == "mapa") - { - var no = tree.getNodeByProperty("id_mapa",id); - no.getContentEl().getElementsByTagName("span")[0].innerHTML = document.getElementById("Etitulo").value; + success:function(o) + { + try + { + if(YAHOO.lang.JSON.parse(o.responseText) == "erro") + { + core_carregando("Não foi possível excluir. Verifique se não existem menus vinculados a este tema"); + setTimeout("core_carregando('desativa')",3000); + } + else + { + if(tipo == "mapa") + { + var no = tree.getNodeByProperty("id_mapa",id); + no.getContentEl().getElementsByTagName("span")[0].innerHTML = document.getElementById("Etitulo").value; no.getContentEl().getElementsByTagName("span")[0].style.color = ""; - no.html = no.getContentEl().innerHTML; - } - if(tipo == "grupo") - { - var no = tree.getNodeByProperty("id_mapa_grupo",id); - no.getContentEl().getElementsByTagName("span")[0].innerHTML = document.getElementById("Etitulo").value; + no.html = no.getContentEl().innerHTML; + } + if(tipo == "grupo") + { + var no = tree.getNodeByProperty("id_mapa_grupo",id); + no.getContentEl().getElementsByTagName("span")[0].innerHTML = document.getElementById("Etitulo").value; no.getContentEl().getElementsByTagName("span")[0].style.color = ""; - no.html = no.getContentEl().innerHTML; - } - if(tipo == "tema") - { - var no = tree.getNodeByProperty("id_mapa_tema",id); - no.getContentEl().getElementsByTagName("span")[0].innerHTML = document.getElementById("Etitulo").value; + no.html = no.getContentEl().innerHTML; + } + if(tipo == "tema") + { + var no = tree.getNodeByProperty("id_mapa_tema",id); + no.getContentEl().getElementsByTagName("span")[0].innerHTML = document.getElementById("Etitulo").value; no.getContentEl().getElementsByTagName("span")[0].style.color = ""; - no.html = no.getContentEl().innerHTML; - } - core_carregando("desativa"); - } + no.html = no.getContentEl().innerHTML; + } + core_carregando("desativa"); + } YAHOO.admin.container.panelEditor.destroy(); YAHOO.admin.container.panelEditor = null; - } - catch(e){core_handleFailure(e,o.responseText);} - }, - failure:core_handleFailure, - argument: { foo:"foo", bar:"bar" } + } + catch(e){core_handleFailure(e,o.responseText);} + }, + failure:core_handleFailure, + argument: { foo:"foo", bar:"bar" } }; if(prog && par){ core_carregando("ativa"); diff --git a/admin/php/metaestat.php b/admin/php/metaestat.php index 260ee30..2694c48 100644 --- a/admin/php/metaestat.php +++ b/admin/php/metaestat.php @@ -118,7 +118,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: LISTAVARIAVEL + Valor: LISTAVARIAVEL Lista de variaveis @@ -154,7 +154,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: LISTACLASSECLASSIFICACAO + Valor: LISTACLASSECLASSIFICACAO Lista as classes de uma classificacoes @@ -168,7 +168,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: LISTAMEDIDAVARIAVEL + Valor: LISTAMEDIDAVARIAVEL Lista das medidas de uma variavel @@ -182,7 +182,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: LISTAPARAMETRO + Valor: LISTAPARAMETRO Lista de parametros @@ -201,7 +201,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: LISTAUNIDADEMEDIDA + Valor: LISTAUNIDADEMEDIDA Lista de unidades de medida @@ -225,7 +225,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: LISTATIPOPERIODO + Valor: LISTATIPOPERIODO Lista de unidades de medida @@ -239,7 +239,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: LISTATIPOREGIAO + Valor: LISTATIPOREGIAO Lista de tipos de regiao @@ -340,7 +340,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: ALTERAMEDIDAVARIAVEL + Valor: ALTERAMEDIDAVARIAVEL Altera os dados de uma medida de uma variavel @@ -401,7 +401,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: ALTERAPARAMETROMEDIDA + Valor: ALTERAPARAMETROMEDIDA Altera os dados de uma parametro de uma medida @@ -422,7 +422,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: ALTERACLASSIFICACAOMEDIDA + Valor: ALTERACLASSIFICACAOMEDIDA Altera os dados de uma classificacao de uma medida @@ -540,7 +540,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: ALTERACLASSECLASSIFICACAO + Valor: ALTERACLASSECLASSIFICACAO Altera os dados de uma classe de uma classificacao @@ -592,7 +592,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: ALTERARUNIDADEMEDIDA + Valor: ALTERARUNIDADEMEDIDA Altera a tabela de unidades de medida @@ -612,7 +612,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: ALTERARCONEXAO + Valor: ALTERARCONEXAO Altera a tabela de conexoes @@ -632,7 +632,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: ALTERARTIPOREGIAO + Valor: ALTERARTIPOREGIAO Altera a tabela de regioes @@ -664,7 +664,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: ALTERARTIPOPERIODO + Valor: ALTERARTIPOPERIODO Altera a tabela de tipos de periodo @@ -687,7 +687,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: ALTERAMAPA + Valor: ALTERAMAPA Altera a tabela de mapas para publicacao @@ -707,7 +707,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: ALTERAMAPAGRUPO + Valor: ALTERAMAPAGRUPO Altera a tabela de grupos para publicacao @@ -738,7 +738,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: EXCLUIRMAPA + Valor: EXCLUIRMAPA Exclui um mapa do publicador @@ -800,7 +800,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: EXCLUIRTIPOPERIODO + Valor: EXCLUIRTIPOPERIODO Exclui uma variavel @@ -832,7 +832,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: EXCLUIRUNIDADEMEDIDA + Valor: EXCLUIRUNIDADEMEDIDA Exclui uma unidade de medida"Dados inseridos" @@ -900,7 +900,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: EXCLUIRTIPOREGIAO + Valor: EXCLUIRTIPOREGIAO Exclui uma regiao @@ -928,7 +928,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: EXCLUIRMEDIDAVARIAVEL + Valor: EXCLUIRMEDIDAVARIAVEL Exclui uma medida da variavel @@ -971,7 +971,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: EXCLUIRCLASSIFICACAOMEDIDA + Valor: EXCLUIRCLASSIFICACAOMEDIDA Exclui uma classificacao de uma medida da variavel @@ -996,7 +996,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: EXCLUIRCLASSECLASSIFICACAO + Valor: EXCLUIRCLASSECLASSIFICACAO Exclui uma classe de uma classificacao @@ -1090,7 +1090,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: MAPFILEMEDIDAVARIAVEL + Valor: MAPFILEMEDIDAVARIAVEL Cria o mapfile de uma media de uma variavel @@ -1139,7 +1139,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: KMLMEDIDAVARIAVEL + Valor: KMLMEDIDAVARIAVEL Gera um arquivo kml que pode ser aberto no googleearth @@ -1290,7 +1290,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: COLUNASTABELA + Valor: COLUNASTABELA Lista as colunas de uma tabela @@ -1349,7 +1349,7 @@ switch (strtoupper($funcao)) exit; break; /* - Valor: DESCREVECOLUNASTABELA + Valor: DESCREVECOLUNASTABELA Lista as colunas de uma tabela @@ -1374,6 +1374,15 @@ switch (strtoupper($funcao)) } exit; break; + case "ARVOREVAR": + $m = new Metaestat(); + if(empty($codigo_variavel)){ + $codigo_variavel = ""; + } + $dados = $m->relatorioCompleto($codigo_variavel,$dadosGerenciais); + retornaJSON($dados); + exit; + break; case "RELATORIOCOMPLETO": $m = new Metaestat(); if(empty($codigo_variavel)){ -- libgit2 0.21.2