Commit f3960f71aa34887b427f03704be6fac5c1f18a46
1 parent
1e515cc7
Exists in
master
and in
7 other branches
Adaptações em classe_menutemas para geração da arvore hiperbolica
Showing
2 changed files
with
12 additions
and
4 deletions
Show diff stats
classesphp/classe_menutemas.php
... | ... | @@ -58,7 +58,7 @@ $editores - (opcional) array com os editores cadastrados no ms_configura.php |
58 | 58 | */ |
59 | 59 | function __construct($map_file="",$perfil="",$locsistemas="",$locaplic="",$menutemas="",$urli3geo="",$editores="") |
60 | 60 | { |
61 | - error_reporting(0); | |
61 | + error_reporting(E_ALL); | |
62 | 62 | $perfil = str_replace(" ",",",$perfil); |
63 | 63 | $this->perfil = explode(",",$perfil); |
64 | 64 | $this->locsistemas = $locsistemas; |
... | ... | @@ -104,6 +104,8 @@ array |
104 | 104 | function pegaListaDeMenus() |
105 | 105 | { |
106 | 106 | $resultado = array(); |
107 | + //necessário por conta da inclusao do conexao.php | |
108 | + $locaplic = $this->locaplic; | |
107 | 109 | // |
108 | 110 | //se $menutemas estiver "", o i3geo |
109 | 111 | //irá utilizar o sistema de administração para pegar os menus |
... | ... | @@ -112,7 +114,7 @@ array |
112 | 114 | { |
113 | 115 | if(!isset($this->locaplic)) |
114 | 116 | {return "locaplic nao foi definido";} |
115 | - include_once($this->locaplic."/admin/php/conexao.php"); | |
117 | + include($this->locaplic."/admin/php/conexao.php"); | |
116 | 118 | $sql = 'SELECT * from i3geoadmin_menus order by nome_menu'; |
117 | 119 | $q = $dbh->query($sql,PDO::FETCH_ASSOC); |
118 | 120 | $regs = $q->fetchAll(); |
... | ... | @@ -160,6 +162,8 @@ array |
160 | 162 | */ |
161 | 163 | function pegaListaDeMapas($locmapas) |
162 | 164 | { |
165 | + //necessário por conta da inclusao do conexao.php | |
166 | + $locaplic = $this->locaplic; | |
163 | 167 | $perfilgeral = implode(" ",$this->perfil); |
164 | 168 | if($locmapas != "") |
165 | 169 | {$this->xml = simplexml_load_file($locmapas);} |
... | ... | @@ -219,13 +223,16 @@ array |
219 | 223 | //lê os arquivos xml |
220 | 224 | //"&tipo=gruposeraiz" pega apenas os nomes dos grupos e temas na raiz |
221 | 225 | // |
226 | + //necessário por conta da inclusao do conexao.php | |
227 | + $locaplic = $this->locaplic; | |
222 | 228 | include_once($this->locaplic."/admin/php/xml.php"); |
223 | 229 | if($listasgrupos == "sim") |
224 | 230 | {$tipo = "";} |
225 | 231 | else |
226 | 232 | {$tipo = "gruposeraiz";} |
227 | 233 | $this->xml = ""; |
228 | - foreach($this->pegaListaDeMenus() as $menu) | |
234 | + $tempm = $this->pegaListaDeMenus(); | |
235 | + foreach($tempm as $menu) | |
229 | 236 | { |
230 | 237 | if($menu["idmenu"] == $idmenu || $idmenu == "") |
231 | 238 | { |
... | ... | @@ -403,6 +410,7 @@ array |
403 | 410 | */ |
404 | 411 | function pegaListaDeSubGrupos($codgrupo,$idmenu="") |
405 | 412 | { |
413 | + $locaplic=$this->locaplic; | |
406 | 414 | include_once($this->locaplic."/admin/php/xml.php"); |
407 | 415 | $tipo = "subgrupos"; |
408 | 416 | $this->xml = ""; | ... | ... |
classesphp/mapa_controle.php
... | ... | @@ -117,7 +117,7 @@ if ($funcao != "criaMapa") |
117 | 117 | //verifica se deve ativar o debug |
118 | 118 | // |
119 | 119 | if (isset($debug) && $debug == "sim") |
120 | -{error_reporting(E_ALL);} | |
120 | +{error_reporting(0);} | |
121 | 121 | // |
122 | 122 | //ativa o php mapscript e as extensões necessárias |
123 | 123 | //se as extensões já estiverem carregadas no PHP, vc pode comentar essa linha para que o processamento fique mais rápido | ... | ... |