Commit 3a7f42e99d414b6f7cd6ab850cbea7d547cfe5d3
1 parent
82af21ac
Exists in
master
and in
7 other branches
--no commit message
Showing
2 changed files
with
15 additions
and
4 deletions
Show diff stats
ferramentas/saiku/esquemaxml.php
... | ... | @@ -121,6 +121,7 @@ $regiao = ""; |
121 | 121 | $item = ""; |
122 | 122 | $registros = ""; |
123 | 123 | //echo "<pre>";var_dump($regioes);exit; |
124 | + | |
124 | 125 | $xml = "<Schema name='i3Geo Metaestat'>"; |
125 | 126 | //cria as dimensoes de tipo temporal |
126 | 127 | if(empty($saikuConfigDataSource['tabelaDimensaoTempo'])){ |
... | ... | @@ -410,8 +411,9 @@ header("Location:".$saikuUrl."/?nomeConexao=".$nomeConexao."&locaplic=".$_GET["l |
410 | 411 | function converte($texto){ |
411 | 412 | $texto = str_replace("&","&",htmlentities($texto)); |
412 | 413 | //$texto = htmlentities($texto); |
413 | - //$texto = mb_convert_encoding($texto, 'UTF-8', mb_detect_encoding($texto)); | |
414 | + //$texto = mb_convert_encoding($texto, 'ISO-8859-1', "auto"); | |
414 | 415 | //$texto = utf8_encode($texto); |
416 | + //$textox = mb_convert_encoding($texto, "UTF-8", mb_detect_encoding($texto, "UTF-8, ISO-8859-1, ISO-8859-15", true)); | |
415 | 417 | return $texto; |
416 | 418 | } |
417 | 419 | ?> | ... | ... |
ferramentas/saiku/saiku-server/tomcat/webapps/ROOT/js/saiku/plugins/CCC_Chart/plugin.js
... | ... | @@ -626,7 +626,7 @@ $(this.el).prepend(" | chart process"); |
626 | 626 | this.data.metadata.push({ |
627 | 627 | colIndex: 0, |
628 | 628 | colType: "String", |
629 | - colName: firstHeader.join('/') | |
629 | + colName: converteHtmlEntities(firstHeader.join('/')) | |
630 | 630 | }); |
631 | 631 | lowest_level = field - 1; |
632 | 632 | } |
... | ... | @@ -640,7 +640,7 @@ $(this.el).prepend(" | chart process"); |
640 | 640 | this.data.metadata.push({ |
641 | 641 | colIndex: field - lowest_level + 1, |
642 | 642 | colType: "Numeric", |
643 | - colName: colheader.join('/') | |
643 | + colName: converteHtmlEntities(colheader.join('/')) | |
644 | 644 | }); |
645 | 645 | |
646 | 646 | data_start = row+1; |
... | ... | @@ -702,4 +702,13 @@ $(this.el).prepend(" | chart process"); |
702 | 702 | } |
703 | 703 | }); |
704 | 704 | |
705 | - | |
705 | +function converteHtmlEntities(texto){ | |
706 | + var s = ["á","ã","à","é","í","ó","õ","ú","ç","Á","Ã","À","É","Í","Ó","Õ","Ú","Ç"], | |
707 | + e = ["á","ã","à","é","í","ó","õ","ú","ç","Á","Ã","À","É","Í","Ó","Õ","Ú","Ç"], | |
708 | + n = e.length, | |
709 | + i; | |
710 | + for(i=0;i<n;i++){ | |
711 | + texto = texto.replace(e[i],s[i]); | |
712 | + } | |
713 | + return texto; | |
714 | +} | ... | ... |