'Returns the HTML to display a map
Normally called in the controller as: map = gis.show_map()
In the view, put: {{=XML(map)}}
@param id: ID to uniquely identify this map if there are several on a page
@param height: Height of viewport (if not provided then the default deployment setting is used)
@param width: Width of viewport (if not provided then the default deployment setting is used)
@param bbox: default Bounding Box of viewport (if not provided then the Lat/Lon/Zoom are used) (Dict):
{"lon_min" : float,
"lat_min" : float,
"lon_max" : float,
"lat_max" : float,
@param lat: default Latitude of viewport (if not provided then the default setting from the Map Service Catalogue is used)
@param lon: default Longitude of viewport (if not provided then the default setting from the Map Service Catalogue is used)
@param zoom: default Zoom level of viewport (if not provided then the default setting from the Map Service Catalogue is used)
@param projection: EPSG code for the Projection to use (if not provided then the default setting from the Map Service Catalogue is used)
@param add_feature: Whether to include a DrawFeature control to allow adding a marker to the map
@param add_feature_active: Whether the DrawFeature control should be active by default
@param add_polygon: Whether to include a DrawFeature control to allow drawing a polygon over the map
@param add_polygon_active: Whether the DrawFeature control should be active by default
@param add_circle: Whether to include a DrawFeature control to allow drawing a circle over the map
@param add_circle_active: Whether the DrawFeature control should be active by default
@param features: Simple Features to overlay on Map (no control over appearance & not interactive)
[wkt]
@param feature_queries: Feature Queries to overlay onto the map & their options (List of Dicts):
[{"name"   : T("MyLabel"), # A string: the label for the layer
"query"  : query,        # A gluon.sql.Rows of gis_locations, which can be from a simple query or a Join.
# Extra fields can be added for \'popup_url\', \'popup_label\' & either
# \'marker\' (url/height/width) or \'shape\' (with optional \'colour\' & \'size\')
"active" : True,         # Is the feed displayed upon load or needs ticking to load afterwards?
"marker" : None,         # Optional: A per-Layer marker query or marker_id for the icon used to display the feature
"opacity" : 1,           # Optional
"cluster_attribute",     # Optional
"cluster_distance",      # Optional
"cluster_threshold"      # Optional
@param feature_resources: REST URLs for (filtered) resources to overlay onto the map & their options (List of Dicts):
[{"name"      : T("MyLabel"), # A string: the label for the layer
"id"        : "search",     # A string: the id for the layer (for manipulation by JavaScript)
"active"    : True,         # Is the feed displayed upon load or needs ticking to load afterwards?
EITHER:
"layer_id"  : 1,            # An integer: the layer_id to load (optional alternative to specifying URL/tablename/marker)
"filter"    : "filter",     # A string: an optional URL filter which *replaces* any in the layer
OR:
"tablename" : "module_resource", # A string: the tablename (used to determine whether to locate via location_id or site_id)
"url"       : "/eden/module/resource.geojson?filter", # A URL to load the resource
"marker"    : None,         # Optional: A per-Layer marker dict for the icon used to display the feature (overrides layer_id if-set)
"opacity"   : 1,            # Optional (overrides layer_id if-set)
"cluster_attribute",        # Optional (overrides layer_id if-set)
"cluster_distance",         # Optional (overrides layer_id if-set)
"cluster_threshold",        # Optional (overrides layer_id if-set)
"dir",                      # Optional (overrides layer_id if-set)
"style",                    # Optional (overrides layer_id if-set)
@param wms_browser: WMS Server\'s GetCapabilities & options (dict)
{"name": T("MyLabel"),     # Name for the Folder in LayerTree
"url": string             # URL of GetCapabilities
@param catalogue_layers: Show all the enabled Layers from the GIS Catalogue
Defaults to False: Just show the default Base layer
@param legend: True: Show the GeoExt Legend panel, False: No Panel, "float": New floating Legend Panel
@param toolbar: Show the Icon Toolbar of Controls
@param area: Show the Area tool on the Toolbar
@param color_picker: Show the Color Picker tool on the Toolbar (used for S3LocationSelector...pick up in postprocess)
If a style is provided then this is used as the default style
@param nav: Show the Navigation controls on the Toolbar
@param save: Show the Save tool on the Toolbar
@param search: Show the Geonames search box (requires a username to be configured)
@param mouse_position: Show the current coordinates in the bottom-right of the map. 3 Options: \'normal\', \'mgrs\', False (defaults to checking deployment_settings, which defaults to \'normal\')
@param overview: Show the Overview Map (defaults to checking deployment_settings, which defaults to True)
@param permalink: Show the Permalink control (defaults to checking deployment_settings, which defaults to True)
@param scaleline: Show the ScaleLine control (defaults to checking deployment_settings, which defaults to True)
@param zoomcontrol: Show the Zoom control (defaults to checking deployment_settings, which defaults to True)
@param mgrs: Use the MGRS Control to select PDFs
{"name": string,           # Name for the Control
"url": string             # URL of PDF server
@ToDo: Also add MGRS Search support: http://gxp.opengeo.org/master/examples/mgrs.html
@param window: Have viewport pop out of page into a resizable window
@param window_hide: Have the window hidden by default, ready to appear (e.g. on clicking a button)
@param closable: In Window mode, whether the window is closable or not
@param collapsed: Start the Tools panel (West region) collapsed
@param callback: Code to run once the Map JavaScript has loaded
@param plugins: an iterable of objects which support the following methods:
.extend_gis_map(map)
Client-side portion suppoprts the following methods:
.addToMapWindow(items)
.setup(map)'

def show_map(self, id='default_map', height=None, width=None, bbox={}, lat=None, lon=None, zoom=None, projection=None, add_feature=False, add_feature_active=False, add_line=False, add_line_active=False, add_polygon=False, add_polygon_active=False, add_circle=False, add_circle_active=False, features=None, feature_queries=None, feature_resources=None, wms_browser={}, catalogue_layers=False, legend=False, toolbar=False, area=False, color_picker=False, clear_layers=None, nav=None, print_control=None, print_mode=False, save=False, search=False, mouse_position=None, overview=None, permalink=None, scaleline=None, zoomcontrol=None, zoomWheelEnabled=True, mgrs={}, window=False, window_hide=False, closable=True, maximizable=True, collapsed=False, callback='DEFAULT', plugins=None):

    return MAP(id=id, height=height, width=width, bbox=bbox, lat=lat, lon=lon, zoom=zoom, projection=projection, add_feature=add_feature, add_feature_active=add_feature_active, add_line=add_line, add_line_active=add_line_active, add_polygon=add_polygon, add_polygon_active=add_polygon_active, add_circle=add_circle, add_circle_active=add_circle_active, features=features, feature_queries=feature_queries, feature_resources=feature_resources, wms_browser=wms_browser, catalogue_layers=catalogue_layers, legend=legend, toolbar=toolbar, area=area, color_picker=color_picker, clear_layers=clear_layers, nav=nav, print_control=print_control, print_mode=print_mode, save=save, search=search, mouse_position=mouse_position, overview=overview, permalink=permalink, scaleline=scaleline, zoomcontrol=zoomcontrol, zoomWheelEnabled=zoomWheelEnabled, mgrs=mgrs, window=window, window_hide=window_hide, closable=closable, maximizable=maximizable, collapsed=collapsed, callback=callback, plugins=plugins)
