Commit a9bfeed7341a58953316eba86493ccd97d85dd2f
1 parent
4e066090
Exists in
master
and in
7 other branches
--no commit message
Showing
3 changed files
with
8 additions
and
5 deletions
Show diff stats
admin/admin.db
No preview for this file type
classesphp/classe_atributos.php
@@ -488,6 +488,7 @@ class Atributos | @@ -488,6 +488,7 @@ class Atributos | ||
488 | $shp_atual[$i] = $shapes[$i];; | 488 | $shp_atual[$i] = $shapes[$i];; |
489 | } | 489 | } |
490 | $chk = ""; | 490 | $chk = ""; |
491 | + | ||
491 | if (@$this->layer->queryByrect($this->mapa->extent) == MS_SUCCESS){ | 492 | if (@$this->layer->queryByrect($this->mapa->extent) == MS_SUCCESS){ |
492 | $res_count = $this->layer->getNumresults(); | 493 | $res_count = $this->layer->getNumresults(); |
493 | $totalGeral = $res_count; | 494 | $totalGeral = $res_count; |
classesphp/funcoes_gerais.php
@@ -1479,7 +1479,7 @@ function criaSHP($tema,$map_file,$locaplic,$dir_tmp,$nomeRand=TRUE) | @@ -1479,7 +1479,7 @@ function criaSHP($tema,$map_file,$locaplic,$dir_tmp,$nomeRand=TRUE) | ||
1479 | $dbname = $nomeshp.".dbf"; | 1479 | $dbname = $nomeshp.".dbf"; |
1480 | $reg = array(); | 1480 | $reg = array(); |
1481 | $novoshpf = ms_newShapefileObj($nomeshp.".shp", -2); | 1481 | $novoshpf = ms_newShapefileObj($nomeshp.".shp", -2); |
1482 | - | 1482 | + |
1483 | $res_count = count($shapesSel); | 1483 | $res_count = count($shapesSel); |
1484 | if ($res_count > 0){ | 1484 | if ($res_count > 0){ |
1485 | for ($i = 0; $i < $res_count; ++$i){ | 1485 | for ($i = 0; $i < $res_count; ++$i){ |
@@ -2468,10 +2468,10 @@ function retornaShapesMapext($objLayer,$objMapa){ | @@ -2468,10 +2468,10 @@ function retornaShapesMapext($objLayer,$objMapa){ | ||
2468 | function retornaShapesSelecionados($objLayer,$map_file,$objMapa){ | 2468 | function retornaShapesSelecionados($objLayer,$map_file,$objMapa){ |
2469 | $shapes = array(); | 2469 | $shapes = array(); |
2470 | $qyfile = dirname($map_file)."/".$objLayer->name.".php"; | 2470 | $qyfile = dirname($map_file)."/".$objLayer->name.".php"; |
2471 | - | 2471 | + |
2472 | if(!file_exists($qyfile)) | 2472 | if(!file_exists($qyfile)) |
2473 | {return $shapes;} | 2473 | {return $shapes;} |
2474 | - | 2474 | + |
2475 | $handle = fopen ($qyfile, "r"); | 2475 | $handle = fopen ($qyfile, "r"); |
2476 | $conteudo = fread ($handle, filesize ($qyfile)); | 2476 | $conteudo = fread ($handle, filesize ($qyfile)); |
2477 | fclose ($handle); | 2477 | fclose ($handle); |
@@ -2479,12 +2479,14 @@ function retornaShapesSelecionados($objLayer,$map_file,$objMapa){ | @@ -2479,12 +2479,14 @@ function retornaShapesSelecionados($objLayer,$map_file,$objMapa){ | ||
2479 | //echo count($listaDeIndices);exit; | 2479 | //echo count($listaDeIndices);exit; |
2480 | if(count($listaDeIndices) == 0) | 2480 | if(count($listaDeIndices) == 0) |
2481 | {return $shapes;} | 2481 | {return $shapes;} |
2482 | - | 2482 | + |
2483 | $versao = versao(); | 2483 | $versao = versao(); |
2484 | $versao = $versao["principal"]; | 2484 | $versao = $versao["principal"]; |
2485 | + | ||
2485 | if ($objLayer->connectiontype != MS_POSTGIS){ | 2486 | if ($objLayer->connectiontype != MS_POSTGIS){ |
2486 | //pega os shapes selecionados | 2487 | //pega os shapes selecionados |
2487 | carregaquery2($map_file,$objLayer,$objMapa); | 2488 | carregaquery2($map_file,$objLayer,$objMapa); |
2489 | + | ||
2488 | $sopen = $objLayer->open(); | 2490 | $sopen = $objLayer->open(); |
2489 | if($sopen == MS_FAILURE){return "erro";} | 2491 | if($sopen == MS_FAILURE){return "erro";} |
2490 | $objLayer->open(); | 2492 | $objLayer->open(); |
@@ -2492,7 +2494,7 @@ function retornaShapesSelecionados($objLayer,$map_file,$objMapa){ | @@ -2492,7 +2494,7 @@ function retornaShapesSelecionados($objLayer,$map_file,$objMapa){ | ||
2492 | $centroides = array(); | 2494 | $centroides = array(); |
2493 | $shapes = array(); | 2495 | $shapes = array(); |
2494 | //pega um shape especifico | 2496 | //pega um shape especifico |
2495 | - | 2497 | + |
2496 | for ($i = 0; $i < $res_count; ++$i) | 2498 | for ($i = 0; $i < $res_count; ++$i) |
2497 | { | 2499 | { |
2498 | if($versao == 6) | 2500 | if($versao == 6) |