Commit 4eeac9a6bf4b3b46e04860632e1c4e75ed551dc9
1 parent
cd370171
Exists in
master
and in
7 other branches
Correção na obtenção do boundingbox em layers POSTGIS.
Showing
1 changed file
with
14 additions
and
3 deletions
Show diff stats
ogc.php
| @@ -174,11 +174,22 @@ if ($tipo == "" || $tipo == "metadados") | @@ -174,11 +174,22 @@ if ($tipo == "" || $tipo == "metadados") | ||
| 174 | if ($c->name == "") | 174 | if ($c->name == "") |
| 175 | {$c->name = " ";} | 175 | {$c->name = " ";} |
| 176 | } | 176 | } |
| 177 | - if (isset($postgis_mapa)) | 177 | + if ($l->connectiontype == MS_POSTGIS) |
| 178 | { | 178 | { |
| 179 | - if ($postgis_mapa != "") | 179 | + //inclui extensao geografica |
| 180 | + $extensao = $l->getmetadata("EXTENSAO"); | ||
| 181 | + if($extensao == "") | ||
| 180 | { | 182 | { |
| 181 | - if ($layer->connectiontype == MS_POSTGIS) | 183 | + $e = $oMap->extent; |
| 184 | + $extensao = ($e->minx)." ".($e->miny)." ".($e->maxx)." ".($e->maxy); | ||
| 185 | + } | ||
| 186 | + $l->setmetadata("wms_extent",$extensao); | ||
| 187 | + } | ||
| 188 | + if (isset($postgis_mapa)) | ||
| 189 | + { | ||
| 190 | + if ($postgis_mapa != "") | ||
| 191 | + { | ||
| 192 | + if ($l->connectiontype == MS_POSTGIS) | ||
| 182 | { | 193 | { |
| 183 | $lcon = $l->connection; | 194 | $lcon = $l->connection; |
| 184 | if (($lcon == " ") || ($lcon == "") || (in_array($lcon,array_keys($postgis_mapa)))) | 195 | if (($lcon == " ") || ($lcon == "") || (in_array($lcon,array_keys($postgis_mapa)))) |