Commit 667ae6d54961e337ea3e730c724e29c040958d1a
1 parent
dd7bef92
Exists in
master
and in
7 other branches
--no commit message
Showing
2 changed files
with
12 additions
and
4 deletions
Show diff stats
ferramentas/heatmap/openlayers_js.php
@@ -24,8 +24,6 @@ include_once($dir."/funcoes.php"); | @@ -24,8 +24,6 @@ include_once($dir."/funcoes.php"); | ||
24 | //o plugin pode ser chamado sem um mapfile criado | 24 | //o plugin pode ser chamado sem um mapfile criado |
25 | //usando apenas o mapfile existente em i3geo/temas | 25 | //usando apenas o mapfile existente em i3geo/temas |
26 | //nesse caso e necessario cirar um mapfile temporario | 26 | //nesse caso e necessario cirar um mapfile temporario |
27 | - | ||
28 | -//no caso do SAIKU, o nome do mapfile pode estar na sessao | ||
29 | if($g_sid != ""){ | 27 | if($g_sid != ""){ |
30 | session_name("i3GeoPHP"); | 28 | session_name("i3GeoPHP"); |
31 | session_id($g_sid); | 29 | session_id($g_sid); |
@@ -38,7 +36,17 @@ if($g_sid != ""){ | @@ -38,7 +36,17 @@ if($g_sid != ""){ | ||
38 | } | 36 | } |
39 | } | 37 | } |
40 | $map_file = heatmapMapfile(); | 38 | $map_file = heatmapMapfile(); |
41 | - | 39 | +//no caso do SAIKU, o nome do mapfile pode estar na sessao |
40 | +if($map_file == ""){ | ||
41 | + session_name("i3GeoPHP"); | ||
42 | + session_start(); | ||
43 | + if(!empty($_SESSION["map_file"])){ | ||
44 | + $mapateste = ms_newMapObj($_SESSION["map_file"]); | ||
45 | + if($mapateste->getlayerbyname($layer) != ""){ | ||
46 | + $map_file = $_SESSION["map_file"]; | ||
47 | + } | ||
48 | + } | ||
49 | +} | ||
42 | $resultado = heatmapDados($map_file); | 50 | $resultado = heatmapDados($map_file); |
43 | $gradiente = heatmapGradiente($map_file,$layer,$tipoGradiente); | 51 | $gradiente = heatmapGradiente($map_file,$layer,$tipoGradiente); |
44 | 52 |
ferramentas/saiku/cartograma.php
@@ -196,7 +196,7 @@ if($opcoes["tipo"] == "coresChapadas"){ | @@ -196,7 +196,7 @@ if($opcoes["tipo"] == "coresChapadas"){ | ||
196 | $m->salva(); | 196 | $m->salva(); |
197 | } | 197 | } |
198 | if($opcoes["tipo"] == "calor"){ | 198 | if($opcoes["tipo"] == "calor"){ |
199 | - $parametros = '{"plugin":"heatmap","parametros":{"opacity":".8","coluna":"","radius":"'.$opcoes["raio"].'","max":"'.$opcoes["max"].'"}}'; | 199 | + $parametros = '{"plugin":"heatmap","parametros":{"tipoGradiente":"default","opacity":".8","coluna":"","radius":"'.$opcoes["raio"].'","max":"'.$opcoes["max"].'"}}'; |
200 | $layer->setmetadata("PLUGINI3GEO",$parametros); | 200 | $layer->setmetadata("PLUGINI3GEO",$parametros); |
201 | $mapa->save($map_file); | 201 | $mapa->save($map_file); |
202 | } | 202 | } |