Skip to content

Commit

Permalink
Put only example layers in the update scaffold
Browse files Browse the repository at this point in the history
  • Loading branch information
sbrunner committed Apr 13, 2016
1 parent 4b61bda commit 9698d3f
Show file tree
Hide file tree
Showing 3 changed files with 56 additions and 55 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,6 @@ MAP
END
END

INCLUDE "example.map"
INCLUDE "demo.map"

END
Original file line number Diff line number Diff line change
@@ -1,57 +1,4 @@
# restricted access layer
LAYER
NAME 'layer_name'
TYPE POLYGON
TEMPLATE fooOnlyForWMSGetFeatureInfo # For GetFeatureInfo
EXTENT 420000 30000 900000 350000
CONNECTIONTYPE postgis
PROCESSING "CLOSE_CONNECTION=DEFER" # For performance
CONNECTION "${mapserver_connection}"
# Example data for secured layer by restriction area
DATA "geometrie FROM (SELECT geo.* FROM geodata.table AS geo WHERE ST_Contains((${mapfile_data_subselect} 'layer_name'), ST_SetSRID(geo.geometrie, 21781))) as foo using unique id using srid=21781"
# Example data for secured layer by role (without any area)
#DATA "geometrie FROM (SELECT geo.geom as geom FROM geodata.table AS geo WHERE %role_id% IN (${mapfile_data_noarea_subselect} 'layer_name')) as foo USING UNIQUE gid USING srid=21781"
# Example data for public layer
#DATA "geometrie FROM (SELECT geo.geom as geom FROM geodata.table AS geo) AS foo USING UNIQUE gid USING srid=21781"
METADATA
"wms_title" "layer_name" # For WMS
"wms_srs" "EPSG:21781" # For WMS

"wfs_enable_request" "*" # Enable WFS for this layer
"gml_include_items" "all" # For GetFeatureInfo and WFS GetFeature (QueryBuilder)
"ows_geom_type" "polygon" # For returning geometries in GetFeatureInfo
"ows_geometries" "geom" # For returning geometries in GetFeatureInfo

"wms_metadataurl_href" "http://www.example.com/bar" # For metadata URL
"wms_metadataurl_format" "text/html" # For metadata URL
"wms_metadataurl_type" "TC211" # For metadata URL

${mapserver_layer_metadata} # For secured layers
END
VALIDATION
${mapserver_layer_validation} # For secured layers
END
STATUS ON
PROJECTION
"init=epsg:21781"
END
CLASS
NAME "countries"
OUTLINECOLOR 0 0 0
END
END

# raster layer (with a tile index)
LAYER
NAME 'topo'
GROUP 'plan'
TYPE RASTER
STATUS ON
PROCESSING "RESAMPLE=AVERAGE"
TILEINDEX "raster/topo"
TILEITEM "LOCATION"
MINSCALEDENOM 25000
END
# This file is used to render the examples layers, he can be deleted.

# Europe Layer
LAYER
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
# restricted access layer
LAYER
NAME 'layer_name'
TYPE POLYGON
TEMPLATE fooOnlyForWMSGetFeatureInfo # For GetFeatureInfo
EXTENT 420000 30000 900000 350000
CONNECTIONTYPE postgis
PROCESSING "CLOSE_CONNECTION=DEFER" # For performance
CONNECTION "${mapserver_connection}"
# Example data for secured layer by restriction area
DATA "geometrie FROM (SELECT geo.* FROM geodata.table AS geo WHERE ST_Contains((${mapfile_data_subselect} 'layer_name'), ST_SetSRID(geo.geometrie, {{srid}}))) as foo using unique id using srid={{srid}}"
# Example data for secured layer by role (without any area)
#DATA "geometrie FROM (SELECT geo.geom as geom FROM geodata.table AS geo WHERE %role_id% IN (${mapfile_data_noarea_subselect} 'layer_name')) as foo USING UNIQUE gid USING srid={{srid}}"
# Example data for public layer
#DATA "geometrie FROM (SELECT geo.geom as geom FROM geodata.table AS geo) AS foo USING UNIQUE gid USING srid={{srid}}"
METADATA
"wms_title" "layer_name" # For WMS
"wms_srs" "EPSG:{{srid}}" # For WMS

"wfs_enable_request" "*" # Enable WFS for this layer
"gml_include_items" "all" # For GetFeatureInfo and WFS GetFeature (QueryBuilder)
"ows_geom_type" "polygon" # For returning geometries in GetFeatureInfo
"ows_geometries" "geom" # For returning geometries in GetFeatureInfo

"wms_metadataurl_href" "http://www.example.com/bar" # For metadata URL
"wms_metadataurl_format" "text/html" # For metadata URL
"wms_metadataurl_type" "TC211" # For metadata URL

${mapserver_layer_metadata} # For secured layers
END
VALIDATION
${mapserver_layer_validation} # For secured layers
END
STATUS ON
PROJECTION
"init=epsg:{{srid}}"
END
CLASS
NAME "countries"
OUTLINECOLOR 0 0 0
END
END

# raster layer (with a tile index)
LAYER
NAME 'topo'
GROUP 'plan'
TYPE RASTER
STATUS ON
PROCESSING "RESAMPLE=AVERAGE"
TILEINDEX "raster/topo"
TILEITEM "LOCATION"
MINSCALEDENOM 25000
END

0 comments on commit 9698d3f

Please sign in to comment.