diff --git a/konova/forms/geometry_form.py b/konova/forms/geometry_form.py
index 75b6e97c..3f885fae 100644
--- a/konova/forms/geometry_form.py
+++ b/konova/forms/geometry_form.py
@@ -27,7 +27,7 @@ class SimpleGeomForm(BaseForm):
"""
read_only = True
geometry_simplified = False
- geom = JSONField(
+ output = JSONField(
label=_("Geometry"),
help_text=_(""),
label_suffix="",
@@ -48,29 +48,30 @@ class SimpleGeomForm(BaseForm):
raise AttributeError
geojson = self.instance.geometry.as_feature_collection(srid=DEFAULT_SRID_RLP)
+ geojson = self._set_properties(geojson, self.instance.identifier)
geom = json.dumps(geojson)
except AttributeError:
# If no geometry exists for this form, we simply set the value to None and zoom to the maximum level
geom = ""
self.empty = True
- self.initialize_form_field("geom", geom)
+ self.initialize_form_field("output", geom)
def is_valid(self):
super().is_valid()
is_valid = True
# Get geojson from form
- geom = self.data["geom"]
+ geom = self.data["output"]
if geom is None or len(geom) == 0:
# empty geometry is a valid geometry
- self.cleaned_data["geom"] = MultiPolygon(srid=DEFAULT_SRID_RLP).ewkt
+ self.cleaned_data["output"] = MultiPolygon(srid=DEFAULT_SRID_RLP).ewkt
return is_valid
geom = json.loads(geom)
# Write submitted data back into form field to make sure invalid geometry
# will be rendered again on failed submit
- self.initialize_form_field("geom", self.data["geom"])
+ self.initialize_form_field("output", self.data["output"])
# Read geojson into gdal geometry
# HINT: This can be simplified if the geojson format holds data in epsg:4326 (GDAL provides direct creation for
@@ -97,7 +98,7 @@ class SimpleGeomForm(BaseForm):
g = self.__flatten_geom_to_2D(g)
if g.geom_type not in accepted_ogr_types:
- self.add_error("geom", _("Only surfaces allowed. Points or lines must be buffered."))
+ self.add_error("output", _("Only surfaces allowed. Points or lines must be buffered."))
is_valid &= False
return is_valid
@@ -106,7 +107,7 @@ class SimpleGeomForm(BaseForm):
polygon = Polygon.from_ewkt(g.ewkt)
is_valid &= polygon.valid
if not polygon.valid:
- self.add_error("geom", polygon.valid_reason)
+ self.add_error("output", polygon.valid_reason)
return is_valid
features.append(polygon)
@@ -123,7 +124,7 @@ class SimpleGeomForm(BaseForm):
# Write unioned Multipolygon into cleaned data
if self.cleaned_data is None:
self.cleaned_data = {}
- self.cleaned_data["geom"] = form_geom.ewkt
+ self.cleaned_data["output"] = form_geom.ewkt
return is_valid
@@ -133,7 +134,7 @@ class SimpleGeomForm(BaseForm):
Returns:
"""
- geom = self.cleaned_data.get("geom")
+ geom = self.cleaned_data.get("output")
g = gdal.OGRGeometry(geom, srs=DEFAULT_SRID_RLP)
num_vertices = g.num_coords
@@ -149,7 +150,7 @@ class SimpleGeomForm(BaseForm):
if not is_area_valid:
self.add_error(
- "geom",
+ "output",
_("Geometry must be greater than 1m². Currently is {}m²").format(
float(geom.area)
)
@@ -192,14 +193,14 @@ class SimpleGeomForm(BaseForm):
if self.instance is None or self.instance.geometry is None:
raise LookupError
geometry = self.instance.geometry
- geometry.geom = self.cleaned_data.get("geom", MultiPolygon(srid=DEFAULT_SRID_RLP))
+ geometry.geom = self.cleaned_data.get("output", MultiPolygon(srid=DEFAULT_SRID_RLP))
geometry.modified = action
geometry.save()
except LookupError:
# No geometry or linked instance holding a geometry exist --> create a new one!
geometry = Geometry.objects.create(
- geom=self.cleaned_data.get("geom", MultiPolygon(srid=DEFAULT_SRID_RLP)),
+ geom=self.cleaned_data.get("output", MultiPolygon(srid=DEFAULT_SRID_RLP)),
created=action,
)
@@ -223,3 +224,19 @@ class SimpleGeomForm(BaseForm):
g_wkt = wkt_w.write(geom.geos).decode("utf-8")
geom = gdal.OGRGeometry(g_wkt)
return geom
+
+ def _set_properties(self, geojson: dict, title: str):
+ """ Toggles the editable property of the geojson for proper handling in map client
+
+ Args:
+ geojson (dict): The GeoJson
+
+ Returns:
+ geojson (dict): The altered GeoJson
+ """
+ features = geojson.get("features", [])
+ for feature in features:
+ feature["properties"]["editable"] = not self.read_only
+ if title:
+ feature["properties"]["title"] = title
+ return geojson
diff --git a/konova/models/geometry.py b/konova/models/geometry.py
index ffe93aa9..2db60e4d 100644
--- a/konova/models/geometry.py
+++ b/konova/models/geometry.py
@@ -342,6 +342,7 @@ class Geometry(BaseResource):
{
"type": "Feature",
"geometry": json.loads(p.json),
+ "properties": {},
}
for p in polygons
]
diff --git a/konova/sub_settings/django_settings.py b/konova/sub_settings/django_settings.py
index 3cd9dc98..fa87e11a 100644
--- a/konova/sub_settings/django_settings.py
+++ b/konova/sub_settings/django_settings.py
@@ -189,7 +189,6 @@ STATIC_ROOT = os.path.join(BASE_DIR, "static")
STATICFILES_DIRS = [
os.path.join(BASE_DIR, 'konova/static'),
os.path.join(BASE_DIR, 'templates/map/client'), # NETGIS map client files
- os.path.join(BASE_DIR, 'templates/map/client/libs'), # NETGIS map client files
]
# EMAIL (see https://docs.djangoproject.com/en/dev/topics/email/)
diff --git a/konova/views/map_proxy.py b/konova/views/map_proxy.py
index 790ab8dc..4834ad58 100644
--- a/konova/views/map_proxy.py
+++ b/konova/views/map_proxy.py
@@ -10,11 +10,10 @@ from json import JSONDecodeError
import requests
from django.contrib.auth.decorators import login_required
-from django.http import JsonResponse, HttpRequest
+from django.http import JsonResponse, HttpRequest, HttpResponse
from django.utils.decorators import method_decorator
from django.utils.http import urlencode
from django.views import View
-from django.utils.translation import gettext_lazy as _
from requests.auth import HTTPDigestAuth
@@ -51,7 +50,10 @@ class BaseClientProxyView(View):
)
content = response.content
if isinstance(content, bytes):
- content = content.decode("utf-8")
+ try:
+ content = content.decode("utf-8")
+ except UnicodeDecodeError:
+ content = f"Can not decode content of {url}"
return content, response.status_code
@@ -60,24 +62,7 @@ class ClientProxyParcelSearch(BaseClientProxyView):
def get(self, request: HttpRequest):
url = request.META.get("QUERY_STRING")
content, response_code = self.perform_url_call(url)
- try:
- body = json.loads(content)
- except JSONDecodeError as e:
- body = {
- "totalResultsCount": -1,
- "geonames": [
- {
- "title": _("The external service is currently unavailable.
Please try again in a few moments...")
- }
- ]
- }
-
- if response_code != 200:
- return JsonResponse({
- "status_code": response_code,
- "content": body,
- })
- return JsonResponse(body)
+ return HttpResponse(content)
class ClientProxyParcelWFS(BaseClientProxyView):
diff --git a/templates/map/client/config.json b/templates/map/client/config.json
index 918ba3a4..26c0d16b 100644
--- a/templates/map/client/config.json
+++ b/templates/map/client/config.json
@@ -1,107 +1,143 @@
{
- "layers":
- [
- { "folder": 5, "type": "WMS", "title": "KOM Flächen", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=kom_f&", "name": "kom_f" },
- { "folder": 5, "type": "WMS", "title": "KOM Linien", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=kom_l&", "name": "kom_l" },
- { "folder": 5, "type": "WMS", "title": "KOM Punkte", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=komon&", "name": "kom_p" },
-
- { "folder": 6, "type": "WMS", "title": "EIV Flächen", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=eiv_f&", "name": "eiv_f" },
- { "folder": 6, "type": "WMS", "title": "EIV Linien", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=eiv_l&", "name": "eiv_l" },
- { "folder": 6, "type": "WMS", "title": "EIV Punkte", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=eiv_p&", "name": "eiv_p" },
-
- { "folder": 7, "type": "WMS", "title": "OEK Flächen", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=oek_f&", "name": "oek_f" },
-
- { "folder": 8, "type": "WMS", "title": "EMA Flächen", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=ema_f&", "name": "ema_f" },
-
- { "folder": 9, "type": "WMS", "title": "MAE Flächen", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=mae&", "name": "mae" },
-
- { "folder": 10, "type": "WMS", "title": "Naturschutzgebiete", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=naturschutzgebiet&", "name": "naturschutzgebiet" },
- { "folder": 10, "type": "WMS", "title": "Naturparkzonen", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=naturparkzonen&", "name": "naturparkzonen" },
- { "folder": 10, "type": "WMS", "title": "Landschaftsschutzgebiete", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=landschaftsschutzgebiet&", "name": "landschaftsschutzgebiet" },
- { "folder": 10, "type": "WMS", "title": "Vogelschutzgebiete", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=vogelschutzgebiet&", "name": "vogelschutzgebiet" },
- { "folder": 10, "type": "WMS", "title": "FFH Gebiete", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=ffh&", "name": "ffh" },
-
- { "folder": 11, "type": "WMS", "title": "Nationalpark Zonen", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=nationalpark_zonen&", "name": "nationalpark_zonen" },
- { "folder": 11, "type": "WMS", "title": "Nationalpark Grenzen", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=nationalpark_grenze&", "name": "nationalpark_grenze" },
-
- { "folder": 12, "type": "WMS", "title": "Naturräume Grenzen", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=natraum_lkompvo_grenzen&", "name": "natraum_lkompvo_grenzen" },
- { "folder": 12, "type": "WMS", "title": "Naturräume Flächen", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=natraum_lkompvo&", "name": "natraum_lkompvo" },
-
- { "folder": 1, "type": "WMS", "title": "Lagebezeichnungen", "url": "https://geo5.service24.rlp.de/wms/liegenschaften_rp.fcgi?", "name": "Lagebezeichnungen" },
- { "folder": 1, "type": "WMS", "title": "Flurstücke (WMS)", "url": "https://geo5.service24.rlp.de/wms/liegenschaften_rp.fcgi?", "name": "Flurstueck", "active": true},
- { "folder": 1, "type": "WFS", "title": "Flurstücke (WFS; ab hoher Zoomstufe)", "url": "/client/proxy/wfs?", "name": "ave:Flurstueck", "minZoom": 17},
- { "folder": 1, "type": "WMS", "title": "Gebäude / Bauwerke", "url": "https://geo5.service24.rlp.de/wms/liegenschaften_rp.fcgi?", "name": "GebaeudeBauwerke" },
- { "folder": 1, "type": "WMS", "title": "Nutzung", "url": "https://geo5.service24.rlp.de/wms/liegenschaften_rp.fcgi?", "name": "Nutzung" },
-
- { "folder": 2, "type": "WMS", "title": "Landkreise", "url": "http://geo5.service24.rlp.de/wms/verwaltungsgrenzen_rp.fcgi?", "name": "Landkreise" },
- { "folder": 2, "type": "WMS", "title": "Verbandsgemeinden", "url": "http://geo5.service24.rlp.de/wms/verwaltungsgrenzen_rp.fcgi?", "name": "Verbandsgemeinden" },
- { "folder": 2, "type": "WMS", "title": "Gemeinden", "url": "http://geo5.service24.rlp.de/wms/verwaltungsgrenzen_rp.fcgi?", "name": "Gemeinden" },
-
- { "folder": 15, "type": "WMS", "order": -1, "title": "farbig", "attribution": "LVermGeo", "url": "https://maps.service24.rlp.de/gisserver/services/RP/RP_WebAtlasRP/MapServer/WmsServer?", "name": "RP_WebAtlasRP", "active": true},
- { "folder": 15, "type": "WMS", "title": "grau", "attribution": "LVermGeo", "url": "https://maps.service24.rlp.de/gisserver/services/RP/RP_ETRS_Gt/MapServer/WmsServer?", "name": "0", "active": false },
- { "folder": 0, "type": "WMS", "title": "Luftbilder", "attribution": "LVermGeo", "url": "http://geo4.service24.rlp.de/wms/dop_basis.fcgi?", "name": "rp_dop", "active": false },
- { "folder": 14, "type": "WMS", "title": "farbig", "attribution": "BKG", "url": "https://sgx.geodatenzentrum.de/wms_basemapde?", "name": "de_basemapde_web_raster_farbe", "active": false },
- { "folder": 14, "type": "WMS", "title": "grau", "attribution": "BKG", "url": "https://sgx.geodatenzentrum.de/wms_basemapde?", "name": "de_basemapde_web_raster_grau", "active": false },
- { "folder": 13, "type": "WMS", "title": "farbig", "attribution": "LVermGeo", "url": "https://geo4.service24.rlp.de/wms/dtk5_rp.fcgi?", "name": "rp_dtk5", "active": false },
- { "folder": 13, "type": "WMS", "title": "grau", "attribution": "LVermGeo", "url": "https://geo4.service24.rlp.de/wms/dtk5_rp.fcgi?", "name": "rp_dtk5_grau", "active": false }
- ],
- "folders":
- [
- { "title": "Hintergrund", "parent": -1 },
- { "title": "ALKIS Liegenschaften", "parent": -1 },
- { "title": "Verwaltungsgrenzen", "parent": -1 },
- { "title": "Geofachdaten", "parent": -1 },
- { "title": "Kompensationsverzeichnis", "parent": 3 },
- { "title": "Kompensationen", "parent": 4 },
- { "title": "Eingriffe", "parent": 4 },
- { "title": "Ökokonten", "parent": 4 },
- { "title": "EMA", "parent": 4 },
- { "title": "MAE", "parent": 4 },
- { "title": "Schutzgebiete", "parent": 3 },
- { "title": "Nationalparke", "parent": 10 },
- { "title": "Naturräume", "parent": 10 },
- { "title": "Topographisch (DTK5)", "parent": 0 },
- { "title": "BaseMap", "parent": 0 },
- { "title": "Webatlas", "parent": 0 }
- ],
+ "modules":
+ {
+ "menu": true,
+ "layertree": true,
+ "map": true,
+ "controls": true,
+ "attribution": true,
+ "info": true,
+ "searchplace": true,
+ "searchparcel": true,
+ "toolbox": true,
+ "import": true,
+ "export": true
+ },
+ "menu":
+ {
+ "header": "",
+ "items":
+ [
+ { "id": "searchplace", "title": "Suche" },
+ { "id": "searchparcel", "title": "Flurstücke" },
+ { "id": "toolbox", "title": "Werkzeuge" },
+ { "id": "layertree", "title": "Inhalte" }
+ ]
+ },
"projections":
[
[ "EPSG:25832", "+proj=utm +zone=32 +ellps=GRS80 +units=m +no_defs" ]
],
-
"map":
{
"projection": "EPSG:25832",
- "center": [ 385000, 5543000 ],
- "minZoom": 5,
- "maxZoom": 22,
- "zoom": 9,
- "attribution": "LANIS RLP",
- "scalebar": true
- },
-
- "output":
- {
- "id": "netgis-storage"
- },
-
- "search":
- {
- "url": "/client/proxy?https://www.geoportal.rlp.de/mapbender/geoportal/gaz_geom_mobile.php?outputFormat=json&resultTarget=web&searchEPSG={epsg}&maxResults=5&maxRows=5&featureClass=P&style=full&searchText={q}&name_startsWith={q}"
+ "center_lonlat": [ 7.0, 50.0 ],
+ "zoom": 12,
+ "min_zoom": 5,
+ "max_zoom": 24,
+ "scalebar": true,
+ "move_tolerance": 5
},
+ "folders":
+ [
+ { "id": "bg", "title": "Hintergrund", "parent": null , "radio": true},
+ { "id": "alkis", "parent": null, "title": "ALKIS Liegenschaften" },
+ { "id": "verwaltung", "parent": null, "title": "Verwaltungsgrenzen" },
+ { "id": "fachdaten", "parent": null, "title": "Geofachdaten" },
+ { "id": "ksp", "parent": "fachdaten", "title": "Kompensationsverzeichnis"},
+ { "id": "schutzgebiet", "parent": "fachdaten", "title": "Schutzgebiete"},
+ { "id": "nationalpark", "parent": "schutzgebiet", "title": "Nationalparke"},
+ { "id": "naturraum", "parent": "schutzgebiet", "title": "Naturräume" },
+ { "id": "kom", "parent": "ksp", "title": "Kompensationen" },
+ { "id": "eiv", "parent": "ksp", "title": "Eingriffe" },
+ { "id": "oek", "parent": "ksp", "title": "Ökokonten" },
+ { "id": "ema", "parent": "ksp", "title": "EMA" },
+ { "id": "mae", "parent": "ksp", "title": "MAE" }
+ ],
+ "layers":
+ [
+ { "id": "kom_f", "folder": "kom", "type": "WMS", "title": "KOM Flächen", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=kom_f&", "name": "kom_f" },
+ { "id": "kom_l", "folder": "kom", "type": "WMS", "title": "KOM Linien", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=kom_l&", "name": "kom_l" },
+ { "id": "kom_p", "folder": "kom", "type": "WMS", "title": "KOM Punkte", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=komon&", "name": "kom_p" },
- "searchParcel":
+ { "id": "eiv_f", "folder": "eiv", "type": "WMS", "title": "EIV Flächen", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=eiv_f&", "name": "eiv_f" },
+ { "id": "eiv_l", "folder": "eiv", "type": "WMS", "title": "EIV Linien", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=eiv_l&", "name": "eiv_l" },
+ { "id": "eiv_p", "folder": "eiv", "type": "WMS", "title": "EIV Punkte", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=eiv_p&", "name": "eiv_p" },
+
+ { "id": "oek_f", "folder": "oek", "type": "WMS", "title": "OEK Flächen", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=oek_f&", "name": "oek_f" },
+
+ { "id": "ema_f", "folder": "ema", "type": "WMS", "title": "EMA Flächen", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=ema_f&", "name": "ema_f" },
+
+ { "id": "mae_f", "folder": "mae", "type": "WMS", "title": "MAE Flächen", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=mae&", "name": "mae" },
+
+ { "id": "nnsg", "folder": "schutzgebiet", "type": "WMS", "title": "Naturschutzgebiete", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=naturschutzgebiet&", "name": "naturschutzgebiet" },
+ { "id": "npz", "folder": "schutzgebiet", "type": "WMS", "title": "Naturparkzonen", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=naturparkzonen&", "name": "naturparkzonen" },
+ { "id": "lsg", "folder": "schutzgebiet", "type": "WMS", "title": "Landschaftsschutzgebiete", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=landschaftsschutzgebiet&", "name": "landschaftsschutzgebiet" },
+ { "id": "vsg", "folder": "schutzgebiet", "type": "WMS", "title": "Vogelschutzgebiete", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=vogelschutzgebiet&", "name": "vogelschutzgebiet" },
+ { "id": "ffh", "folder": "schutzgebiet", "type": "WMS", "title": "FFH Gebiete", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=ffh&", "name": "ffh" },
+
+ { "id": "ntpz", "folder": "nationalpark", "type": "WMS", "title": "Nationalpark Zonen", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=nationalpark_zonen&", "name": "nationalpark_zonen" },
+ { "id": "ntpg", "folder": "nationalpark", "type": "WMS", "title": "Nationalpark Grenzen", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=nationalpark_grenze&", "name": "nationalpark_grenze" },
+
+ { "id": "natraum_g", "folder": "naturraum", "type": "WMS", "title": "Naturräume Grenzen", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=natraum_lkompvo_grenzen&", "name": "natraum_lkompvo_grenzen" },
+ { "id": "natraum_f", "folder": "naturraum", "type": "WMS", "title": "Naturräume Flächen", "url": "https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_ogc/wms_getmap.php?mapfile=natraum_lkompvo&", "name": "natraum_lkompvo" },
+
+ { "id": "lagebezeichnung", "folder": "alkis", "type": "WMS", "title": "Lagebezeichnungen", "url": "https://geo5.service24.rlp.de/wms/liegenschaften_rp.fcgi?", "name": "Lagebezeichnungen" },
+ { "id": "flurstueck_wms", "folder": "alkis", "type": "WMS", "title": "Flurstücke (WMS)", "url": "https://geo5.service24.rlp.de/wms/liegenschaften_rp.fcgi?", "name": "Flurstueck", "active": true},
+ { "id": "flurstueck_wfs", "folder": "alkis", "type": "WFS", "title": "Flurstücke (WFS; ab hoher Zoomstufe)", "url": "/client/proxy/wfs?", "name": "ave:Flurstueck", "minZoom": 17},
+ { "id": "gebaeude", "folder": "alkis", "type": "WMS", "title": "Gebäude / Bauwerke", "url": "https://geo5.service24.rlp.de/wms/liegenschaften_rp.fcgi?", "name": "GebaeudeBauwerke" },
+ { "id": "nutzung", "folder": "alkis", "type": "WMS", "title": "Nutzung", "url": "https://geo5.service24.rlp.de/wms/liegenschaften_rp.fcgi?", "name": "Nutzung" },
+
+ { "id": "lk", "folder": "verwaltung", "type": "WMS", "title": "Landkreise", "url": "http://geo5.service24.rlp.de/wms/verwaltungsgrenzen_rp.fcgi?", "name": "Landkreise" },
+ { "id": "vg", "folder": "verwaltung", "type": "WMS", "title": "Verbandsgemeinden", "url": "http://geo5.service24.rlp.de/wms/verwaltungsgrenzen_rp.fcgi?", "name": "Verbandsgemeinden" },
+ { "id": "gmd", "folder": "verwaltung", "type": "WMS", "title": "Gemeinden", "url": "http://geo5.service24.rlp.de/wms/verwaltungsgrenzen_rp.fcgi?", "name": "Gemeinden" },
+
+ { "id": "webatlas_farbe", "folder": "bg", "type": "WMS", "order": -1, "title": "WebatlasRP farbig", "attribution": "LVermGeo", "url": "https://maps.service24.rlp.de/gisserver/services/RP/RP_WebAtlasRP/MapServer/WmsServer?", "name": "RP_WebAtlasRP", "active": true},
+ { "id": "webatlas_grau", "folder": "bg", "type": "WMS", "order": -1, "title": "WebatlasRP grau", "attribution": "LVermGeo", "url": "https://maps.service24.rlp.de/gisserver/services/RP/RP_ETRS_Gt/MapServer/WmsServer?", "name": "0", "active": false },
+ { "id": "luftbilder", "folder": "bg", "type": "WMS", "order": -1, "title": "Luftbilder", "attribution": "LVermGeo", "url": "http://geo4.service24.rlp.de/wms/dop_basis.fcgi?", "name": "rp_dop", "active": false },
+ { "id": "basemap_farbe", "folder": "bg", "type": "WMS", "order": -1, "title": "BasemapDE farbig", "attribution": "BKG", "url": "https://sgx.geodatenzentrum.de/wms_basemapde?", "name": "de_basemapde_web_raster_farbe", "active": false },
+ { "id": "basemap_grau", "folder": "bg", "type": "WMS", "order": -1, "title": "BasemapDE grau", "attribution": "BKG", "url": "https://sgx.geodatenzentrum.de/wms_basemapde?", "name": "de_basemapde_web_raster_grau", "active": false },
+ { "id": "dtk_farbe", "folder": "bg", "type": "WMS", "order": -1, "title": "DTK5 farbig", "attribution": "LVermGeo", "url": "https://geo4.service24.rlp.de/wms/dtk5_rp.fcgi?", "name": "rp_dtk5", "active": false },
+ { "id": "dtk_grau", "folder": "bg", "type": "WMS", "order": -1, "title": "DTK5 grau", "attribution": "LVermGeo", "url": "https://geo4.service24.rlp.de/wms/dtk5_rp.fcgi?", "name": "rp_dtk5_grau", "active": false }
+ ],
+ "layertree":
{
- "nameURL": "/client/proxy?https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_alkis/gem_search.php?placename={q}",
- "parcelURL": "/client/proxy?https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_alkis/flur_search.php?gmk_gmn={district}&fln={field}&fsn_zae={parcelA}&fsn_nen={parcelB}&export=json",
+ "open": false,
+ "title": "Inhalte",
+ "buttons":
+ [
+ { "id": "import_layer", "title": "Hinzufügen..." }
+ ]
+ },
+ "controls":
+ {
+ "buttons":
+ [
+ { "id": "zoom_in", "icon": "", "title": "Zoom +" },
+ { "id": "zoom_out", "icon": "", "title": "Zoom -" },
+ { "id": "zoom_home", "icon": "", "title": "Anfangsausdehung" }
+ ]
+ },
+ "searchplace":
+ {
+ "title": "Adresse...",
+ "url": "/client/proxy?https://www.geoportal.rlp.de/mapbender/geoportal/gaz_geom_mobile.php?outputFormat=json&resultTarget=web&searchEPSG={epsg}&maxResults=5&maxRows=5&featureClass=P&style=full&searchText={query}&name_startsWith={query}",
+ "zoom": 17,
+ "marker_color": "darkgray",
+ "marker_title": "Such-Ergebnis"
+ },
+ "searchparcel":
+ {
+ "open": false,
+ "name_url": "/client/proxy?https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_alkis/gem_search.php?placename={q}",
+ "parcel_url": "/client/proxy?https://geodaten.naturschutz.rlp.de/kartendienste_naturschutz/mod_alkis/flur_search.php?gmk_gmn={district}&fln={field}&fsn_zae={parcelA}&fsn_nen={parcelB}&export=json",
"districts_service":
{
"type": "WFS",
"url": "http://geo5.service24.rlp.de/wfs/verwaltungsgrenzen_rp.fcgi?",
"name": "vermkv:gemarkungen_rlp",
- "order": 10,
- "minZoom": 11,
- "maxZoom": 17
+ "format": "application/json; subtype=geojson",
+ "min_zoom": 12
},
"fields_service":
{
@@ -110,61 +146,157 @@
"filter_property": "gmkgnr"
}
},
+ "toolbox":
+ {
+ "open": false,
+ "items":
+ [
+ { "id": "view", "title": "Betrachten" },
+ { "id": "zoom_box", "title": "Zoom-Rechteck" },
+ { "id": "view_prev", "title": "Vorherige Ansicht" },
+ { "id": "view_next", "title": "Nächste Ansicht" },
+ { "id": "measure_line", "title": "Strecke messen" },
+ { "id": "measure_area", "title": "Fläche messen" },
+ { "id": "measure_clear", "title": "Messung löschen" },
+ { "id": "draw_points", "title": "Punkte zeichnen" },
+ { "id": "draw_lines", "title": "Linien zeichnen" },
+ { "id": "draw_polygons", "title": "Polygone zeichnen" },
+ { "id": "modify_features", "title": "Verschieben" },
+ { "id": "delete_features", "title": "Löschen" },
+ { "id": "buffer_features", "title": "Puffern" },
+ { "id": "cut_features", "title": "Ausschneiden" },
+ { "id": "import_layer", "title": "Importieren" },
+ { "id": "export", "title": "Exportieren" }
+ ],
+ "options":
+ {
+ "buffer_features":
+ {
+ "title": "Puffern",
+ "items":
+ [
+ { "id": "buffer_radius", "type": "integer", "title": "Radius (Meter)" },
+ { "id": "buffer_segments", "type": "integer", "title": "Segmente" },
+ { "id": "buffer_submit", "type": "button", "title": "Akzeptieren" }
+ ]
+ }
+ }
+ },
"import":
{
- "geopackageLibURL": "/static/libs/geopackage/4.2.3/"
+ "title": "Ebene hinzufügen",
+ "preview": true,
+ "wms_options": [ "https://sgx.geodatenzentrum.de/wms_topplus_open" ],
+ "wfs_options": [ "http://213.139.159.34:80/geoserver/uesg/wfs" ],
+ "wfs_proxy": "/client/proxy?",
+ "geopackage_lib": "/static/libs/geopackage/4.2.3/"
},
"export":
{
+ "title": "Exportieren",
"logo": "/static/assets/logo.png",
- "gifWebWorker": "/static/libs/gifjs/0.2.0/gif.worker.js",
- "defaultFilename": "Export",
- "defaultMargin": 10
+ "gif_worker": "/static/libs/gifjs/0.2.0/gif.worker.js",
+ "default_filename": "Export",
+ "default_margin": 10
+ },
+ "measure":
+ {
+ "line_color": "rgba( 255, 0, 0, 1.0 )",
+ "line_width": 3.0,
+ "line_dash": [ 5, 10 ],
+ "area_fill": "rgba( 255, 0, 0, 0.3 )",
+ "point_radius": 4.0,
+ "point_fill": "rgba( 255, 255, 255, 1.0 )",
+ "point_stroke": "rgba( 0, 0, 0, 1.0 )",
+ "text_color": "#871d33",
+ "text_back": "rgba( 255, 255, 255, 0.7 )"
},
"tools":
{
+ "editable": true,
+ "interactive_render": true,
"buffer":
{
- "defaultRadius": 5,
- "defaultSegments": 2
- }
+ "default_radius": 5,
+ "default_segments": 3
+ },
+ "snapping":
+ {
+ "show": true,
+ "active": true,
+ "tolerance": 35
+ },
+ "bounds_message": "Ausserhalb des erlaubten Bereichs!",
+ "show_bounds": true
+ },
+ "output":
+ {
+ "id": "netgis-storage"
+ },
+ "attribution":
+ {
+ "prefix": "LANIS"
},
"styles":
{
- "editLayer":
+ "draw":
{
- "fill": "rgba( 255, 0, 0, 0.2 )",
+ "fill": "rgba( 255, 0, 0, 0.5 )",
"stroke": "#ff0000",
- "strokeWidth": 3,
- "pointRadius": 6
+ "width": 3,
+ "radius": 6,
+ "viewport_labels": true
+ },
+ "non_edit":
+ {
+ "fill": "rgba( 80, 80, 80, 0.5 )",
+ "stroke": "#666666",
+ "width": 3,
+ "radius": 6,
+ "viewport_labels": true
},
"select":
{
"fill": "rgba( 0, 127, 255, 0.5 )",
"stroke": "#007fff",
- "strokeWidth": 3,
- "pointRadius": 6
+ "width": 3,
+ "radius": 6
},
"sketch":
{
- "fill": "rgba( 0, 127, 255, 0.2 )",
- "stroke": "#0080ff",
- "strokeWidth": 3,
- "pointRadius": 6
+ "fill": "rgba( 0, 127, 0, 0.5 )",
+ "stroke": "#007f00",
+ "width": 3,
+ "radius": 6
+ },
+ "error":
+ {
+ "fill": "rgba( 255, 0, 0, 0.5 )",
+ "stroke": "#ff0000",
+ "width": 3,
+ "radius": 6
+ },
+ "bounds":
+ {
+ "fill": "rgba( 0, 0, 0, 0.0 )",
+ "stroke": "#000000",
+ "width": 3,
+ "radius": 6
},
"modify":
{
- "fill": "rgba( 0, 127, 255, 0.5 )",
- "stroke": "#0080ff",
- "strokeWidth": 3,
- "pointRadius": 6
+ "fill": "rgba( 255, 127, 0, 0.5 )",
+ "stroke": "#ff7f00",
+ "width": 3,
+ "radius": 6
},
"parcel":
{
- "fill": "rgba( 127, 255, 255, 0.5 )",
- "stroke": "#7fffff",
- "strokeWidth": 3
+ "fill": "rgba( 127, 0, 0, 0.0 )",
+ "stroke": "rgba( 127, 0, 0, 1.0 )",
+ "width": 1.5
},
+
"import":
{
"fill": "rgba( 0, 127, 255, 0.2 )",
@@ -172,4 +304,4 @@
"width": 1.5
}
}
-}
\ No newline at end of file
+}
diff --git a/templates/map/client/dist/netgis.min.css b/templates/map/client/dist/netgis.min.css
new file mode 100644
index 00000000..7b8af696
--- /dev/null
+++ b/templates/map/client/dist/netgis.min.css
@@ -0,0 +1 @@
+.netgis-attribution{position:absolute;right:0;bottom:0;padding:1mm;background:rgba(255,255,255,0.5);font-size:2.5mm;z-index:100}.netgis-client{position:relative;box-sizing:border-box;font-size:4mm;overflow:hidden}.netgis-client *{box-sizing:border-box}.netgis-client button{font-size:inherit}.netgis-contextmenu{position:absolute;width:64mm;z-index:90000}.netgis-contextmenu>*{display:block;position:relative;width:100%;height:12mm;line-height:12mm;padding:0 4mm;text-align:left;background:none}.netgis-contextmenu>label span{position:absolute;left:0;right:50%;height:100%;padding:0 4mm}.netgis-contextmenu>label span:last-of-type{left:50%;right:0;padding:2mm;padding-left:0;padding-right:4mm}.netgis-contextmenu>label span:only-of-type{left:12mm;right:0;padding:0 4mm;padding-left:0;cursor:pointer}.netgis-contextmenu>label input[type=range]{width:100%;cursor:pointer}.netgis-controls{position:absolute;width:12mm;right:4mm;bottom:8mm;overflow:hidden;z-index:100}.netgis-client.netgis-footer>.netgis-controls{bottom:44mm}.netgis-controls button{font-size:5mm!important;color:inherit;width:100%;height:12mm;padding:0;border:none;background-color:inherit;cursor:pointer}.netgis-dropdown{display:inline-block;position:relative;padding:0}.netgis-dropdown>:first-child{z-index:10}.netgis-dropdown ul{display:none;position:absolute;margin:0;padding:0;list-style-type:none}.netgis-dropdown:hover>ul{display:block}.netgis-dropdown li{position:relative;height:12mm}.netgis-dropdown li>button,.netgis-dropdown li>a{display:inline-block;width:100%;height:100%;text-align:left}.netgis-dropdown li>ul{display:none;top:0;left:100%;max-height:100mm;overflow-x:hidden;overflow-y:auto}.netgis-dropdown li>ul li{padding-right:5mm}.netgis-dropdown li:hover>ul{display:block}.netgis-dropdown li i:first-child{margin-right:4mm!important}.netgis-dropdown li i:last-child{margin-left:4mm!important;margin-right:0!important}.netgis-dropdown li>label{display:block;text-align:left}.netgis-dropdown li>label input{width:4mm;margin:0;margin-right:4mm}.netgis-compact .netgis-dropdown li{height:9mm;line-height:9mm}.netgis-compact .netgis-dropdown li button,.netgis-compact .netgis-dropdown li .netgis-button{padding:0 3mm}.netgis-compact .netgis-dropdown li i{margin-right:4mm}@media (max-width:599px){}.netgis-import .netgis-preview-map{position:absolute;width:100%;height:40mm;cursor:grab}.netgis-import .netgis-preview-map:active:hover{cursor:grabbing}.netgis-import .netgis-preview-tree{position:absolute;width:100%;top:52mm;bottom:12mm;overflow-y:auto}.netgis-import .netgis-import-submit{position:absolute;width:100%;height:12mm;bottom:0}.netgis-import .netgis-geoportal .netgis-tree{padding-left:0;list-style-type:none}.netgis-import .netgis-geoportal .netgis-tree li{padding-left:0}.netgis-import .netgis-geoportal .netgis-tree label{padding-left:0;margin-bottom:0;font-weight:normal}.netgis-import .netgis-geoportal .netgis-tree .netgis-item input{margin-right:0}.netgis-map{position:absolute;left:0;right:0;top:12mm;bottom:0;cursor:grab;background:#e0dfdf}.netgis-map:active:hover{cursor:grabbing!important}.netgis-map-overlay{width:1px;height:1px;background:none}.netgis-map.netgis-clickable{cursor:pointer}.netgis-map.netgis-mode-zoom-box,.netgis-map.netgis-mode-zoom-box:active:hover,.netgis-map.netgis-mode-measure-line,.netgis-map.netgis-mode-measure-area{cursor:crosshair}.netgis-map.netgis-mode-measure-line:active:hover,.netgis-map.netgis-mode-measure-area:active:hover{cursor:grabbing}.netgis-map.netgis-mode-draw-points,.netgis-map.netgis-mode-draw-lines,.netgis-map.netgis-mode-draw-polygons,.netgis-map.netgis-mode-cut-features-draw{cursor:crosshair}.netgis-map.netgis-mode-draw-points.netgis-not-allowed,.netgis-map.netgis-mode-draw-lines.netgis-not-allowed,.netgis-map.netgis-mode-draw-polygons.netgis-not-allowed{cursor:no-drop}.netgis-map .ol-scale-bar{right:24mm;bottom:10mm;left:auto}.netgis-map .ol-scale-bar select{position:absolute;width:100%;height:100%;top:-1mm;left:0;opacity:0;background:transparent;pointer-events:all!important;cursor:pointer}.netgis-client.netgis-footer>.netgis-map .ol-scale-bar{bottom:46mm}.netgis-menu{position:absolute;left:0;right:0;top:0;max-height:12mm;line-height:12mm;white-space:nowrap;text-align:right;font-size:0;z-index:10000}.netgis-menu.netgis-menu-large{max-height:100%}.netgis-menu .netgis-menu-toggle{z-index:1}.netgis-menu>*{display:inline-block;min-width:12mm;height:12mm;padding:0 4mm;margin:0;font-size:4mm!important}.netgis-menu>h1{position:absolute;left:0;top:0;bottom:0;font-weight:bold;cursor:default}.netgis-menu a{color:inherit;text-decoration:none}.netgis-menu button,.netgis-menu select{color:inherit;background:none;border:none;outline:none;cursor:pointer}.netgis-menu button img,.netgis-menu a img{position:relative;top:.7mm;height:1em}.netgis-menu button i:not(:only-child),.netgis-menu a i:not(:only-child),.netgis-menu button img:not(:only-child),.netgis-menu a img:not(:only-child){width:4mm;margin-right:3mm;text-align:center}.netgis-menu>.netgis-wrapper{display:inline-block;position:relative;padding:0}.netgis-menu>.netgis-wrapper>.netgis-icon{position:absolute;left:0;top:0;padding-left:4mm;pointer-events:none}.netgis-menu>.netgis-wrapper select{width:100%;height:100%;padding-left:11mm}.netgis-menu>.netgis-wrapper select:last-child{padding-left:4mm}@media (max-width:599px){.netgis-menu>*:not(.netgis-menu-toggle){display:block;width:100%;text-align:left}.netgis-menu{overflow:hidden}.netgis-menu.netgis-menu-large{overflow-y:auto}.netgis-menu .netgis-dropdown{height:auto}.netgis-menu .netgis-dropdown ul{position:relative}.netgis-menu .netgis-dropdown li{height:auto}.netgis-menu .netgis-dropdown li>ul{top:auto;left:auto}}@media (min-width:600px){.netgis-menu-toggle{display:none!important}}.netgis-modal{display:none;position:absolute;width:100%;height:100%;top:0;left:0;padding:6mm;z-index:10000;background:rgba(0,0,0,0.6)}.netgis-modal.netgis-show{display:block}.netgis-modal>*{position:relative;width:100%;height:100%;max-width:150mm;margin:0 auto}.netgis-modal .netgis-content{position:absolute;width:100%;top:12mm;bottom:0;padding:12mm;overflow:auto}.netgis-modal .netgis-button{display:block;width:100%;min-height:12mm;text-align:left}.netgis-panel{position:absolute;left:0;width:80mm;top:12mm;bottom:0;z-index:1000;-webkit-transform:translateX(-110%);transform:translateX(-110%);transition:transform 150ms ease;will-change:transform}.netgis-panel.netgis-show{-webkit-transform:none;transform:none}.netgis-client.netgis-footer>.netgis-panel{bottom:36mm}.netgis-panel>div{position:absolute;left:0;right:0;top:12mm;bottom:0;overflow:auto}.netgis-panel h2{margin:0 4mm;font-size:1em}.netgis-panel .netgis-button,.netgis-panel label{display:block;width:100%;min-height:12mm;text-align:left}.netgis-panel input[type=text]{margin-top:3mm}.netgis-panel .netgis-half{display:inline-block;width:50%!important;padding-right:1mm}.netgis-panel .netgis-half+.netgis-half{padding-left:1mm;padding-right:0}.netgis-panel .netgis-anim-bottom{transition:transform 150ms ease;will-change:transform;-webkit-transform:none;transform:none}.netgis-panel .netgis-anim-bottom.netgis-hide{display:initial;-webkit-transform:translateY(110%);transform:translateY(110%)}.netgis-panel .netgis-resize-bottom{max-height:80%}.netgis-popup{display:none;position:absolute;width:80mm;max-width:100mm;height:20mm;left:0;top:0;transform:translate(-50%,-100%);z-index:1000}.netgis-popup.netgis-fade{opacity:.5;transition:opacity .5s ease}.netgis-popup.netgis-fade:hover{opacity:1}.netgis-popup.netgis-show{display:block}.netgis-popup .netgis-arrow-down{position:absolute;left:50%;bottom:0;transform:translateX(-50%);width:0;height:0;border-left:3mm solid transparent;border-right:3mm solid transparent;border-top:3mm solid white}.netgis-popup .netgis-content{position:absolute;width:100%;min-height:12mm;max-height:100mm;left:0;bottom:2.9mm;padding:4mm 0;overflow:auto;cursor:default;box-shadow:0 1mm 4mm 0 rgba(0,0,0,0.3)}.netgis-popup .netgis-closer{position:absolute;right:0;top:0;height:9mm;background:none;width:100%;text-align:left}.netgis-popup .netgis-closer i{position:absolute;right:3mm}.netgis-popup .netgis-loader{font-size:6mm;text-align:center}.netgis-popup .netgis-wrapper{max-height:80mm;margin-top:5mm;padding:0 3mm;overflow:auto}.netgis-popup table{width:100%;border:0;border-collapse:collapse;table-layout:fixed;word-wrap:break-word}.netgis-popup th,.netgis-popup td{padding:2mm;text-align:left;vertical-align:top}.netgis-popup th[colspan]{padding-top:4mm}.netgis-popup tr:first-of-type th[colspan]{padding-top:0}.netgis-popup .netgis-wrapper button{width:100%;height:12mm;text-align:left}.netgis-popup summary{display:block;height:12mm;line-height:12mm;font-weight:bold}.netgis-popup details>div{padding:4mm}.netgis-search{width:100%;transition:transform 150ms ease;will-change:transform;-webkit-transform:none;transform:none}.netgis-search.netgis-hide{display:initial!important;-webkit-transform:translateY(-200%);transform:translateY(-200%)}.netgis-search>label{display:inline-block;position:relative;width:100%;min-height:12mm}@media (max-width:599px){.netgis-search.netgis-responsive{left:0;right:0}}.netgis-search>label>input{width:100%;min-width:60mm;height:12mm;padding:1mm 4mm;vertical-align:top;border:none}.netgis-search>label>button{position:absolute!important;width:12mm;height:12mm;top:0;right:0;background:none}.netgis-search>ul{max-height:60mm;overflow-y:auto;margin:0;padding:0;list-style-type:none}.netgis-search li .netgis-button{width:100%;height:12mm;padding:0 3mm;text-align:left}.netgis-search li .netgis-button span{opacity:.5}.netgis-search-parcel{position:absolute;top:0;bottom:0;width:100%;overflow:hidden;padding:4mm}.netgis-search-parcel section{position:absolute;left:0;right:0;overflow:auto}.netgis-search-parcel section:first-of-type{top:0;bottom:0;padding:6mm}.netgis-search-parcel section:last-of-type{top:50%;bottom:0}.netgis-search-parcel h3{margin:0;margin-bottom:4mm}.netgis-search-parcel label{display:block;margin:3mm 0;margin-bottom:0;cursor:pointer;font-weight:bold}.netgis-search-parcel label:first-child{margin-top:0}.netgis-search-parcel label span:first-child{display:block}.netgis-search-parcel input{width:100%;height:12mm;margin:3mm 0;padding:0 3mm}.netgis-search-parcel .netgis-loader{width:6mm;height:6mm;top:8mm;right:3mm;font-size:6mm}.netgis-search-parcel ul{margin:0;padding:0;list-style-type:none}.netgis-search-parcel li button{text-align:left}.netgis-search-parcel button{display:block;width:100%;height:12mm;padding:0 3mm;margin:0}.netgis-search-parcel .netgis-table-wrapper{width:100%;margin-top:4mm;overflow:auto}.netgis-search-parcel table{min-width:100%;border-collapse:collapse;white-space:nowrap}.netgis-search-parcel table thead{position:-webkit-sticky;position:sticky;top:0;z-index:10}.netgis-search-parcel tr{height:12mm}.netgis-search-parcel th{text-align:left;padding:0 3mm}.netgis-search-parcel td{text-align:left;padding:0 3mm;cursor:pointer}.netgis-search-parcel td:first-child{padding:0}.netgis-search-parcel table button{display:inline-block;width:12mm;height:12mm;background:none}.netgis-search-parcel p{margin:4mm 3mm;font-style:italic}.netgis-search-place{position:absolute;width:100%;max-width:100mm;right:4mm;top:16mm;z-index:900}.netgis-tabs{position:relative}.netgis-tabs>.netgis-header{position:absolute;width:100%;height:12mm;left:0;top:0;white-space:nowrap;overflow-x:auto;overflow-y:hidden}.netgis-tabs>.netgis-content{position:absolute;width:100%;left:0;top:12mm;bottom:0}.netgis-tabs.netgis-scroll>.netgis-header{height:16mm}.netgis-tabs.netgis-scroll>.netgis-content{top:16mm}.netgis-tabs>.netgis-header .netgis-button{display:inline-block;width:auto}.netgis-tabs>.netgis-content section{position:absolute;width:100%;height:100%;left:0;top:0;padding:12mm;overflow:auto}.netgis-tabs>.netgis-content section.netgis-hide{display:none}.netgis-font{font-family:Arial,sans-serif}.netgis-color-a{background-color:#900;color:#fff}.netgis-color-b{background-color:#430433;color:#fff}.netgis-color-c{background-color:#470f1b;color:#fff}.netgis-color-d{background-color:#f6f5f5;color:#000}.netgis-color-e{background-color:#fff;color:#000}.netgis-hover-a:hover{background-color:#900;color:#fff}.netgis-hover-b:hover{background-color:#430433;color:#fff}.netgis-hover-c:hover{background-color:#470f1b;color:#fff}.netgis-hover-d:hover{background-color:#f6f5f5;color:#000}.netgis-hover-e:hover{background-color:#fff;color:#000}.netgis-text-a{color:#900}.netgis-text-b{color:#430433}.netgis-text-c{color:#470f1b}.netgis-text-d{color:#f6f5f5}.netgis-text-e{color:#fff}.netgis-hover-text-a:hover{color:#900}.netgis-hover-text-b:hover{color:#430433}.netgis-hover-text-c:hover{color:#470f1b}.netgis-hover-text-d:hover{color:#f6f5f5}.netgis-hover-text-e:hover{color:#fff}.netgis-timeslider{position:absolute;width:100%;height:36mm;bottom:0;box-shadow:0 0 4mm 0 rgba(0,0,0,0.3);z-index:1000}.netgis-timeslider:hover{z-index:1000}.netgis-timeslider.netgis-active{z-index:1000;cursor:grabbing}.netgis-timeslider>.netgis-header{position:absolute;width:100%;height:12mm;text-align:left;z-index:1}.netgis-timeslider>.netgis-wrapper{position:absolute;width:100%;top:12mm;bottom:0;overflow-x:auto;cursor:grab}.netgis-timeslider.netgis-active>.netgis-wrapper{cursor:grabbing}.netgis-timeslider table{height:100%;border-collapse:collapse}.netgis-timeslider td{position:relative;min-width:32mm;height:100%;white-space:nowrap}.netgis-timeslider td:not(:empty){padding:0}.netgis-timeslider td .netgis-button{height:100%;opacity:.5;cursor:inherit!important}.netgis-timeslider td .netgis-button .netgis-icon{position:relative}.netgis-timeslider td .netgis-button span{margin-left:2mm!important;margin-right:3mm}.netgis-timeslider td.netgis-active .netgis-button,.netgis-timeslider:not(.netgis-active) td:hover .netgis-button{opacity:1}.netgis-toolbox{position:absolute;top:12mm!important;bottom:0!important;width:100%;overflow:hidden}.netgis-toolbox section{position:absolute;left:0;right:0;overflow:auto}.netgis-toolbox section:first-of-type{top:0;bottom:0}.netgis-toolbox section:last-of-type{top:50%;bottom:0}.netgis-toolbox section:last-of-type>div{position:absolute;width:100%;top:12mm;bottom:0;overflow:auto}.netgis-toolbox button:hover i{color:inherit!important}.netgis-toolbox button.netgis-active{font-weight:bold}.netgis-toolbox label{display:block;width:100%;min-height:12mm;text-align:left;position:relative;padding:4mm;cursor:pointer}.netgis-toolbox input[type=checkbox]{width:4mm;height:4mm;margin:0 4mm 0 0}.netgis-toolbox input[type=checkbox]:last-child{float:right;margin-right:0}.netgis-toolbox input[type=text]{width:100%;height:10mm;padding:0 2mm;margin-top:3mm}.netgis-toolbox input[type=number]{position:absolute;right:2mm;width:24mm;top:2.5mm;height:8mm;padding:0 1mm}.netgis-tree{display:block;line-height:12mm;padding:0;margin:0;list-style-type:none}.netgis-tree ul{padding:0;margin:0;padding-left:9mm;list-style-type:none}.netgis-tree .netgis-folder{position:relative}.netgis-tree summary{display:block}.netgis-tree summary label{text-align:center}.netgis-tree .netgis-folder .netgis-icon{width:6mm;left:12mm;color:#eab000}.netgis-tree .netgis-folder .netgis-partial{opacity:.5}.netgis-tree details[open]>summary>.netgis-hide-open,.netgis-tree details>summary>.netgis-show-open{display:none}.netgis-tree details[open]>summary>.netgis-show-open{display:initial}.netgis-tree .netgis-folder>details>summary>label{position:absolute;width:12mm;top:0;left:0}.netgis-tree .netgis-folder>details>summary>span{margin-left:17mm!important}.netgis-tree .netgis-item{position:relative}.netgis-tree .netgis-item label{padding:0 4mm;padding-left:3mm}.netgis-tree .netgis-item label input{margin-right:4mm}.netgis-tree .netgis-item summary{position:absolute;width:12mm;height:12mm;right:0;top:0;text-align:center}.netgis-tree .netgis-item summary+*{position:relative;margin-left:7.5mm}.netgis-tree .netgis-item details label{position:relative}.netgis-tree .netgis-item details label span{position:absolute;left:0;right:50%;height:100%;padding:0 4mm;overflow:hidden}.netgis-tree .netgis-item details label span:last-of-type{left:50%;right:0;padding:2mm;padding-left:0;padding-right:4mm}.netgis-tree .netgis-item details label input[type=range]{width:100%;cursor:pointer}.netgis-bold{font-weight:bold}.netgis-clip-text{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.netgis-center{text-align:center!important}.netgis-clickable{cursor:pointer!important}.netgis-resize-right{resize:horizontal;overflow-x:auto;min-width:40mm;max-width:100%}.netgis-resize-bottom{resize:vertical;overflow-y:auto;min-height:24mm;max-height:100%}.netgis-noselect{-webkit-touch-callout:none;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.netgis-shadow{box-shadow:0 .5mm 1mm 0 rgba(0,0,0,0.1),0 1mm 2.5mm 0 rgba(0,0,0,0.05)!important}.netgis-shadow-large{box-shadow:0 1mm 2mm 0 rgba(0,0,0,0.1),0 2mm 5mm 0 rgba(0,0,0,0.05)!important}.netgis-text-shadow{text-shadow:0 0 1mm rgba(0,0,0,1.0)}.netgis-round{border-radius:2mm}.netgis-hide{display:none!important}.netgis-client button,.netgis-button{position:relative;padding:0 4mm;font-family:inherit;text-decoration:none;border:none;outline:none;cursor:pointer}.netgis-button .netgis-icon{display:inline-block;position:absolute;width:12mm;left:0;top:0;bottom:0;line-height:12mm;text-align:center;font-size:1.2em}.netgis-button.netgis-center .netgis-icon:first-child{position:static}.netgis-button .netgis-icon:last-child{left:auto;right:0}.netgis-button:not(.netgis-center) .netgis-icon+*:not(.netgis-icon){margin-left:8mm}.netgis-form h3{font-size:1em;margin-top:0;margin-bottom:4mm}.netgis-form ul{padding:0;padding-left:12mm;margin-top:0;margin-bottom:6mm;list-style-type:square}.netgis-form li{padding-left:2mm}.netgis-form label{display:block;margin-bottom:6mm;font-weight:bold;cursor:pointer;user-select:none}.netgis-form input,.netgis-form select{display:block;width:100%;margin-top:4mm;padding:2mm}.netgis-form input[type=file]{padding:6mm;cursor:pointer;background:#efefef}.netgis-form input[type=checkbox]{display:inline-block;width:12mm;margin:0}.netgis-form input[type=checkbox]:first-child{width:4mm;margin-right:3mm;margin-top:2mm;margin-bottom:2mm}.netgis-form button{display:block;width:100%;height:12mm}.netgis-form button:not(:last-child){margin-bottom:6mm}.netgis-form select{cursor:pointer}.netgis-loader{position:absolute;width:100%;height:100%;z-index:999999;text-align:center;font-size:12mm;cursor:progress}.netgis-loader *{position:absolute;width:100%;left:0;top:50%;transform:translateY(-50%);animation:netgis-spin 2s linear infinite}@keyframes netgis-spin{0%{transform:rotate(0deg)}to{transform:rotate(360deg)}}@media (max-width:599px){.netgis-hide-mobile{display:none!important}}@media (min-width:600px){.netgis-hide-desktop{display:none!important}}
\ No newline at end of file
diff --git a/templates/map/client/dist/netgis.min.js b/templates/map/client/dist/netgis.min.js
new file mode 100644
index 00000000..4d7aba0f
--- /dev/null
+++ b/templates/map/client/dist/netgis.min.js
@@ -0,0 +1,462 @@
+var $jscomp=$jscomp||{};$jscomp.scope={};$jscomp.ASSUME_ES5=!1;$jscomp.ASSUME_NO_NATIVE_MAP=!1;$jscomp.ASSUME_NO_NATIVE_SET=!1;$jscomp.SIMPLE_FROUND_POLYFILL=!1;$jscomp.defineProperty=$jscomp.ASSUME_ES5||"function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)};$jscomp.getGlobal=function(a){return"undefined"!=typeof window&&window===a?a:"undefined"!=typeof global&&null!=global?global:a};$jscomp.global=$jscomp.getGlobal(this);
+$jscomp.polyfill=function(a,b,c,d){if(b){c=$jscomp.global;a=a.split(".");for(d=0;dZeichnungsfl\u00e4che: "+netgis.util.formatArea(a,!0)+"":null;this.update()};netgis=netgis||{};netgis.Client=function(a,b){this.container=this.initContainer(a);this.logEvents=!1;netgis.util.isString(b)?(this.showLoader(!0),netgis.util.request(b,this.onConfigResponse.bind(this))):this.init(this.container,b)};
+netgis.Client.prototype.init=function(a,b){this.config=b;this.initParams(b);this.initConfig(b);this.initElements(a);this.initModules(b);this.initEvents();this.initOutput(b);a=new netgis.ContextMenu;a.attachTo(this.container);this.modules.contextmenu=a;this.popup=new netgis.Popup;this.popup.attachTo(this.container)};netgis.Client.prototype.initContainer=function(a){netgis.util.isString(a)&&(a=document.getElementById(a));a.classList.add("netgis-client","netgis-font");return a};
+netgis.Client.prototype.initParams=function(a){var b=window.location.search.substr(1);b=b.split("&");this.params={};for(var c=0;c",this.container.appendChild(this.loader));!1===a?this.loader.classList.add("netgis-hide"):this.loader.classList.remove("netgis-hide")};netgis.Client.prototype.handleEvent=function(a){var b=a.type;a=a.detail;!0===this.logEvents&&console.info("EVENT:",b,a)};
+netgis.Client.prototype.addModule=function(a,b){b=new b(this.config);b.attachTo&&b.attachTo(this.container);return this.modules[a]=b};netgis.Client.prototype.isMobile=function(){return netgis.util.isMobile(this.container)};netgis.Client.prototype.onConfigResponse=function(a){a=JSON.parse(a);this.init(this.container,a);this.showLoader(!1)};
+netgis.Client.prototype.requestContextWMC=function(a,b){if(-1c.width&&(a-=d.width);b+d.height>c.height&&(b-=d.height);this.container.style.left=a+"px";this.container.style.top=b+"px"};
+netgis.ContextMenu.prototype.onContextMenuShow=function(a){a=a.detail;this.clear();for(var b=0;bExportieren",this.onExportClickPDF.bind(this));
+this.sections.jpeg=this.tabs.getContentSection(a);a+=1;this.addInputNumber(this.sections.jpeg,"Breite (Pixel):",1600,0);this.addInputNumber(this.sections.jpeg,"H\u00f6he (Pixel):",900,0);this.addCheckbox(this.sections.jpeg,"Querformat",!0);this.addButton(this.sections.jpeg,"Exportieren",this.onExportClickJPEG.bind(this));this.sections.png=this.tabs.getContentSection(a);a+=1;this.addInputNumber(this.sections.png,"Breite (Pixel):",1600,0);this.addInputNumber(this.sections.png,
+"H\u00f6he (Pixel):",900,0);this.addCheckbox(this.sections.png,"Querformat",!0);this.addButton(this.sections.png,"Exportieren",this.onExportClickPNG.bind(this));this.sections.gif=this.tabs.getContentSection(a);a+=1;this.addInputNumber(this.sections.gif,"Breite (Pixel):",1600,0);this.addInputNumber(this.sections.gif,"H\u00f6he (Pixel):",900,0);this.addCheckbox(this.sections.gif,"Querformat",!0);this.addButton(this.sections.gif,"Exportieren",
+this.onExportClickGIF.bind(this));this.sections.geojson=this.tabs.getContentSection(a);this.addCheckbox(this.sections.geojson,"Nicht-Editierbare Geometrien einbeziehen",!1);this.addButton(this.sections.geojson,"Exportieren",this.onExportClickGeoJSON.bind(this))};
+netgis.Export.prototype.attachTo=function(a){a.appendChild(this.modal.container);a.addEventListener(netgis.Events.EXPORT_SHOW,this.onExportShow.bind(this));a.addEventListener(netgis.Events.EXPORT_END,this.onExportEnd.bind(this))};netgis.Export.prototype.addText=function(a,b){var c=document.createElement("div");c.innerHTML=b;a.appendChild(c);return c};
+netgis.Export.prototype.addButton=function(a,b,c){var d=document.createElement("button");d.className="netgis-button netgis-center netgis-color-a netgis-hover-c netgis-shadow";d.setAttribute("type","button");d.innerHTML=b;c&&(d.onclick=c);a.appendChild(d);return d};
+netgis.Export.prototype.addInputText=function(a,b,c){var d=document.createElement("label");d.innerHTML=b;var e=document.createElement("input");e.setAttribute("type","text");d.appendChild(e);if(c){b="list-"+netgis.util.stringToID(b);var f=document.createElement("datalist");f.setAttribute("id",b);for(var g=0;gHinzuf\u00fcgen",this.onGeoportalSubmit.bind(this)));this.sections.wms=this.tabs.getContentSection(a);a+=1;this.addInputText(this.sections.wms,"WMS-URL:",this.config["import"].wms_options);this.addButton(this.sections.wms,"Dienst laden",this.onWMSLoadClick.bind(this));
+this.addInputText(this.sections.wms,"Bezeichnung:");this.addInputSelect(this.sections.wms,"Ebene:");this.addInputSelect(this.sections.wms,"Format:");this.addButton(this.sections.wms,"Hinzuf\u00fcgen",this.onWMSAcceptClick.bind(this));this.showDetailsWMS(!1);this.sections.wfs=this.tabs.getContentSection(a);a+=1;this.addInputText(this.sections.wfs,"WFS-URL:",this.config["import"].wfs_options);this.addButton(this.sections.wfs,"Dienst laden",
+this.onWFSLoadClick.bind(this));this.addInputText(this.sections.wfs,"Bezeichnung:");this.addInputSelect(this.sections.wfs,"Ebene:");this.addInputSelect(this.sections.wfs,"Format:");this.addButton(this.sections.wfs,"Hinzuf\u00fcgen",this.onWFSAcceptClick.bind(this));this.showDetailsWFS(!1);this.sections.geojson=this.tabs.getContentSection(a);a+=1;this.addInputFile(this.sections.geojson,"GeoJSON-Datei:",".geojson,.json");this.addText(this.sections.geojson,
+"Unterst\u00fctzte Koordinatensysteme:
- Web Mercator (EPSG:3857)
- WGS84 / Lon-Lat (EPSG:4326)
- ETRS89 / UTM Zone 32N (EPSG:25832)
");this.addButton(this.sections.geojson,"Datei laden",this.onGeoJSONAcceptClick.bind(this));this.sections.gml=this.tabs.getContentSection(a);a+=1;this.addInputFile(this.sections.gml,"GML-Datei:",".gml,.xml");this.addText(this.sections.gml,"Unterst\u00fctzte Koordinatensysteme:
- Web Mercator (EPSG:3857)
- WGS84 / Lon-Lat (EPSG:4326)
- ETRS89 / UTM Zone 32N (EPSG:25832)
");
+this.addButton(this.sections.gml,"Datei laden",this.onGMLAcceptClick.bind(this));this.sections.geopackage=this.tabs.getContentSection(a);a+=1;this.addInputFile(this.sections.geopackage,"GeoPackage-Datei:",".gpkg");this.addText(this.sections.geopackage,"Unterst\u00fctzte Koordinatensysteme:
- Web Mercator (EPSG:3857)
- WGS84 / Lon-Lat (EPSG:4326)
- ETRS89 / UTM Zone 32N (EPSG:25832)
");this.addButton(this.sections.geopackage,
+"Datei laden",this.onGeoPackageAcceptClick.bind(this));this.sections.spatialite=this.tabs.getContentSection(a);a+=1;this.addInputFile(this.sections.spatialite,"Spatialite-Datei:",".sqlite");this.addText(this.sections.spatialite,"Unterst\u00fctzte Koordinatensysteme:
- Web Mercator (EPSG:3857)
- WGS84 / Lon-Lat (EPSG:4326)
- ETRS89 / UTM Zone 32N (EPSG:25832)
");this.addButton(this.sections.spatialite,"Datei laden",
+this.onSpatialiteAcceptClick.bind(this));this.sections.shapefile=this.tabs.getContentSection(a);this.addInputFile(this.sections.shapefile,"Shapefile-Zip-Datei:",".zip");this.addText(this.sections.shapefile,"Unterst\u00fctzte Koordinatensysteme:
- Web Mercator (EPSG:3857)
- WGS84 / Lon-Lat (EPSG:4326)
- ETRS89 / UTM Zone 32N (EPSG:25832)
");this.addButton(this.sections.shapefile,"Datei laden",this.onShapefileAcceptClick.bind(this))};
+netgis.Import.prototype.initPreview=function(){this.preview=new netgis.Modal("Vorschau");this.preview.attachTo(this.modal.content);this.previewMapContainer=document.createElement("div");this.previewMapContainer.className="netgis-preview-map";this.preview.content.appendChild(this.previewMapContainer);if(ol){var a=this.config.map;a={projection:a.projection,center:a.centerLonLat?ol.proj.fromLonLat(a.centerLonLat):a.center,zoom:a.zoom};this.previewMap=new ol.Map({target:this.previewMapContainer,view:new ol.View(a),
+pixelRatio:1,moveTolerance:3,controls:[]});this.previewMap.getView().padding=[10,10,10,10];this.previewMap.addLayer(new ol.layer.Tile({source:new ol.source.OSM}))}this.previewTree=new netgis.Tree;this.previewTree.container.classList.add("netgis-preview-tree");this.previewTree.attachTo(this.preview.content);this.previewTree.container.addEventListener(netgis.Events.TREE_ITEM_CHANGE,this.onPreviewTreeItemChange.bind(this));this.previewSubmit=document.createElement("button");this.previewSubmit.setAttribute("type",
+"button");this.previewSubmit.className="netgis-import-submit netgis-button netgis-center netgis-color-a netgis-hover-c netgis-shadow";this.previewSubmit.innerHTML="Hinzuf\u00fcgen";this.previewSubmit.addEventListener("click",this.onPreviewSubmitClick.bind(this));this.preview.content.appendChild(this.previewSubmit)};
+netgis.Import.prototype.attachTo=function(a){a.appendChild(this.modal.container);a.addEventListener(netgis.Events.IMPORT_LAYER_SHOW,this.onImportShow.bind(this));a.addEventListener(netgis.Events.IMPORT_LAYER_PREVIEW_FEATURES,this.onImportPreviewFeatures.bind(this))};netgis.Import.prototype.addText=function(a,b){var c=document.createElement("div");c.innerHTML=b;a.appendChild(c);return c};
+netgis.Import.prototype.addButton=function(a,b,c){var d=document.createElement("button");d.className="netgis-button netgis-center netgis-color-a netgis-hover-c netgis-shadow";d.setAttribute("type","button");d.innerHTML=b;c&&(d.onclick=c);a.appendChild(d);return d};
+netgis.Import.prototype.addInputText=function(a,b,c){var d=document.createElement("label");d.innerHTML=b;var e=document.createElement("input");e.setAttribute("type","text");d.appendChild(e);if(c){b="list-"+netgis.util.stringToID(b);var f=document.createElement("datalist");f.setAttribute("id",b);for(var g=0;gb.length)){var c=b.indexOf("?");a=-1b.length)){var c=b.indexOf("?");a=-1",b.title,"",a,"
"].join(""))};netgis=netgis||{};netgis.LayerID=Object.freeze({EDITABLE:"editable-layer",NON_EDITABLE:"non-editable-layer"});netgis=netgis||{};netgis.LayerTree=function(a){this.config=a;this.importFolder=null;this.initElements();this.initConfig(a);this.initFolders()};netgis.LayerTree.prototype.initElements=function(){this.panel=new netgis.Panel("Layers");this.tree=new netgis.Tree;this.tree.attachTo(this.panel.content);this.tree.container.addEventListener(netgis.Events.TREE_ITEM_CHANGE,this.onTreeItemChange.bind(this));this.tree.container.addEventListener(netgis.Events.TREE_ITEM_SLIDER_CHANGE,this.onTreeItemSliderChange.bind(this))};
+netgis.LayerTree.prototype.initFolders=function(){this.editFolder=this.tree.addFolder(null,"edit-folder","Zeichnung",!0);this.tree.addCheckbox(this.editFolder,netgis.LayerID.EDITABLE,"Editierbar");this.tree.setItemChecked(netgis.LayerID.EDITABLE,!0);this.tree.addCheckbox(this.editFolder,netgis.LayerID.NON_EDITABLE,"Nicht-Editierbar");this.tree.setItemChecked(netgis.LayerID.NON_EDITABLE,!0);this.editFolder.classList.add("netgis-hide")};
+netgis.LayerTree.prototype.initConfig=function(a,b){a.layertree&&a.layertree.title&&this.panel.setTitle(a.layertree.title);for(var c=a.folders,d={},e=0;e=e)return c;!0===b.viewport_labels&&(b=this.view.calculateExtent(this.map.getSize()),f=ol.geom.Polygon.fromExtent(b),b=new jsts.io.OL3Parser,d=b.read(d),f=b.read(f),d=d.intersection(f),d=b.write(d),c.setGeometry(d));e=netgis.util.formatArea(e,!0);(a=a.getProperties().title)&&(e=a+"\n"+e);c.setText(new ol.style.Text({text:e,font:"4mm Arial, sans-serif",fill:new ol.style.Fill({color:g}),backgroundFill:new ol.style.Fill({color:"rgba( 255, 255, 255, 0.5 )"}),padding:[2,4,2,4]}))}return c};
+netgis.Map.prototype.styleNonEdit=function(a){var b=this.config.styles.non_edit,c=this.config.styles.select,d=a.getGeometry(),e=this.hoverFeature===a;-1=e)return c;!0===b.viewport_labels&&(b=this.map.getView().calculateExtent(this.map.getSize()),f=ol.geom.Polygon.fromExtent(b),b=new jsts.io.OL3Parser,d=b.read(d),f=b.read(f),d=d.intersection(f),d=b.write(d),c.setGeometry(d));e=netgis.util.formatArea(e,!0);(a=a.getProperties().title)&&(e=a+"\n"+e);c.setText(new ol.style.Text({text:e,font:"4mm Arial, sans-serif",fill:new ol.style.Fill({color:g}),backgroundFill:new ol.style.Fill({color:"rgba( 255, 255, 255, 0.5 )"}),padding:[2,4,2,4]}))}return c};
+netgis.Map.prototype.styleSketch=function(a){var b=this.config.styles[this.drawError?"error":"sketch"],c=a.getGeometry(),d=new ol.style.Style({image:new ol.style.Circle({radius:b.radius,fill:new ol.style.Fill({color:b.fill})}),fill:new ol.style.Fill({color:b.fill}),stroke:new ol.style.Stroke({color:b.stroke,width:b.width})});c instanceof ol.geom.Polygon&&(c=c.getArea(),d.setText(new ol.style.Text({text:[netgis.util.formatArea(c,!0),"4mm sans-serif"],font:"Arial",fill:new ol.style.Fill({color:b.stroke}),
+backgroundFill:new ol.style.Fill({color:"rgba( 255, 255, 255, 0.5 )"}),padding:[2,4,2,4]})));a=new ol.style.Style({image:new ol.style.Circle({radius:b.radius,fill:new ol.style.Fill({color:b.stroke})}),geometry:this.getGeometryPoints(a)});return[d,a]};
+netgis.Map.prototype.styleModify=function(a){var b=this.config.styles.modify,c=new ol.style.Style({image:new ol.style.Circle({radius:b.radius,fill:new ol.style.Fill({color:b.stroke})}),fill:new ol.style.Fill({color:b.fill}),stroke:new ol.style.Stroke({color:b.stroke,width:b.width})}),d=new ol.style.Style({image:new ol.style.Circle({radius:b.radius,fill:new ol.style.Fill({color:b.stroke})}),geometry:this.getGeometryPoints(a)});a=a.getGeometry();a instanceof ol.geom.Polygon&&(a=a.getArea(),c.setText(new ol.style.Text({text:[netgis.util.formatArea(a,
+!0),"4mm sans-serif"],font:"Arial",fill:new ol.style.Fill({color:b.stroke}),backgroundFill:new ol.style.Fill({color:"rgba( 255, 255, 255, 0.5 )"}),padding:[2,4,2,4]})));return[c,d]};netgis.Map.prototype.styleHover=function(a){a=this.config.styles.select;return new ol.style.Style({image:new ol.style.Circle({radius:a.radius,fill:new ol.style.Fill({color:a.stroke})}),fill:new ol.style.Fill({color:a.fill}),stroke:new ol.style.Stroke({color:a.stroke,width:a.width}),zIndex:1})};
+netgis.Map.prototype.getGeometryPoints=function(a){var b=a.getGeometry();if(b instanceof ol.geom.LineString)return new ol.geom.MultiPoint(b.getCoordinates());if(b instanceof ol.geom.Polygon){a=[];b=b.getCoordinates();for(var c=0;cg;++g)e[g]=d/Math.pow(2,g),f[g]=g;source=new ol.source.WMTS({url:a,params:{LAYER:b,FORMAT:"image/png",TRANSPARENT:"true",VERSION:"1.1.1"},layer:b,format:"image/jpeg",matrixSet:"UTM32",tileGrid:new ol.tilegrid.WMTS({origin:ol.extent.getTopLeft(c),resolutions:e,matrixIds:f})})};
+netgis.Map.prototype.createLayerGeoJSON=function(a){if(netgis.util.isObject(a)){var b=new ol.format.GeoJSON,c=b.readProjection(a);a=b.readFeatures(a,{featureProjection:this.view.getProjection()});c=c.getCode();switch(c){case "EPSG:3857":case "EPSG:4326":case this.view.getProjection().getCode():break;default:console.warn("unsupported import projection '"+c+"'")}var d=new ol.layer.Vector({source:new ol.source.Vector({features:a})});return d}if(netgis.util.isString(a)){d=new ol.layer.Vector({source:new ol.source.Vector({features:[]})});
+var e=this;netgis.util.request(a,function(a){a=JSON.parse(a);a=e.createLayerGeoJSON(a);d.getSource().addFeatures(a.getSource().getFeatures())});return d}};
+netgis.Map.prototype.createLayerGML=function(a){console.warn("GML support is experimental!");var b=[];a=(new DOMParser).parseFromString(a,"text/xml").getElementsByTagName("gml:featureMember");for(var c=0;ca.length)){var b=this.previewLayer.getSource().getFeatures()[0];b&&(a=a[0].getGeometry(),a=this.createBufferGeometry(a,this.drawBufferRadius,this.drawBufferSegments),b.setGeometry(a))}}};
+netgis.Map.prototype.isPointInsideLayer=function(a,b){a=a.getSource().getFeatures();for(var c=0;cc.length)return!1}else if(b instanceof ol.geom.Polygon&&(c=c[0],4>c.length||0>=b.getArea()))return!1;c=new jsts.io.OL3Parser;b=c.read(b);a=a.getSource().getFeatures();for(var d=0;da.length)){for(var b=a[0].getGeometry().getExtent(),c=1;cthis.viewHistoryMax&&this.viewHistory.shift();this.viewIndex=this.viewHistory.length-1};
+netgis.Map.prototype.gotoViewHistory=function(a){if(!(1>this.viewHistory.length)){var b=this.viewHistory.length-1;0>a&&(a=b);a>b&&(a=0);a!==this.viewIndex&&(b=this.viewHistory[a],this.viewIndex=a,this.viewFromHistory=!0,this.view.setCenter(b.center),this.view.setZoom(b.zoom))}};netgis.Map.prototype.setPadding=function(a,b,c,d){var e=this.paddingBuffer;this.view.padding=[a+e,b+e,c+e,d+e]};
+netgis.Map.prototype.exportImage=function(a,b,c,d,e){var f=this,g=this.container,h=this.map,k=this.config["export"],l=new Image;l.onload=function(){var m=document.createElement("div");m.style.position="fixed";m.style.top="0px";m.style.left="0px";m.style.width=b+"px";m.style.height=c+"px";m.style.background="white";m.style.zIndex=-1;m.style.opacity=0;m.style.pointerEvents="none";g.appendChild(m);h.setTarget(m);h.once("rendercomplete",function(){var n=document.createElement("canvas");n.width=b;n.height=
+c;var q=n.getContext("2d");q.webkitImageSmoothingEnabled=!1;q.mozImageSmoothingEnabled=!1;q.imageSmoothingEnabled=!1;Array.prototype.forEach.call(document.querySelectorAll(".ol-layer canvas"),function(a){if(0n.width){var u=v;w=u*t;w>r&&(w=r,u=w/t)}else w=r,u=w/t,u>v&&(u=v,w=u*t);t=new jsPDF(d?"l":"p");var x=e;x+=(r-w)/2;r=e;r+=(v-u)/2;t.addImage(n.toDataURL("image/png,1.0",1),"PNG",x,r,w,u);t.setFillColor(255,255,255);t.rect(x,r+u-11,80,11,"F");t.setFontSize(8);
+t.text("Datum: "+netgis.util.getTimeStamp(),x+2,r+u-2-4);t.text("Quelle: "+window.location.href,x+2,r+u-2);n=t.output("bloburl",{filename:k.default_filename+".pdf"});window.open(n,"_blank");break;case "jpeg":window.navigator.msSaveBlob?window.navigator.msSaveBlob(n.msToBlob(),k.default_filename+".jpg"):(p.setAttribute("download",k.default_filename+".jpg"),p.setAttribute("href",n.toDataURL("image/jpeg",1)),p.click());break;case "png":window.navigator.msSaveBlob?window.navigator.msSaveBlob(n.msToBlob(),
+k.default_filename+".png"):(p.setAttribute("download",k.default_filename+".png"),p.setAttribute("href",n.toDataURL("image/png",1)),p.click());break;case "gif":p.setAttribute("download",k.default_filename+".gif"),v=new GIF({workerScript:k.gif_worker,quality:1}),v.addFrame(n),v.on("finished",function(a){p.setAttribute("href",window.URL.createObjectURL(a));p.click()}),v.render()}h.setTarget(g);g.removeChild(m);netgis.util.invoke(f.container,netgis.Events.EXPORT_END,null)});h.renderSync()};l.src=k.logo};
+netgis.Map.prototype.exportFeatures=function(a){var b=this.editLayer.getSource().getFeatures();!0===a&&(a=this.nonEditLayer.getSource().getFeatures(),b=b.concat(a));b=(new ol.format.GeoJSON).writeFeaturesObject(b,{featureProjection:this.view.getProjection(),dataProjection:"EPSG:4326"});a=this.config["export"].default_filename+".geojson";b.name=a;netgis.util.downloadJSON(b,a);netgis.util.invoke(this.container,netgis.Events.EXPORT_END,null)};netgis.Map.prototype.onClientContextResponse=function(a){this.initConfig(a.detail.context.config)};
+netgis.Map.prototype.onEditLayerLoaded=function(a){a=a.detail.geojson;var b=new ol.format.GeoJSON;b.readProjection(a);a=b.readFeatures(a,{featureProjection:this.view.getProjection().getCode()});var c=this,d=a.slice();window.setTimeout(function(){c.zoomFeatures(d)},10);b=[];for(var e=0;ea[0].length)for(var d=0;d";this.container.appendChild(this.toggle)};
+netgis.Menu.prototype.initConfig=function(a){!0===a.menu.compact&&this.container.classList.add("netgis-compact");this.addHeader(a.menu.header);for(var b=a.menu.items,c=0;c"+b+"";d.setAttribute("type","button");c&&(d.onclick=c);a&&a.appendChild(d);return d};netgis.Modal.prototype.onHeaderClick=function(a){this.hide()};netgis.Modal.prototype.onContainerClick=function(a){a.target===this.container&&this.hide()};netgis=netgis||{};
+netgis.Modes=Object.freeze({VIEW:"view",ZOOM_BOX:"zoom-box",MEASURE_LINE:"measure-line",MEASURE_AREA:"measure-area",DRAW_POINTS:"draw-points",DRAW_LINES:"draw-lines",DRAW_POLYGONS:"draw-polygons",MODIFY_FEATURES:"modify-features",DELETE_FEATURES:"delete-features",BUFFER_FEATURES:"buffer-features",BUFFER_FEATURES_EDIT:"buffer-features-edit",BUFFER_FEATURES_DYNAMIC:"buffer-features-dynamic",CUT_FEATURES:"cut-features",CUT_FEATURES_DRAW:"cut-features-draw",CUT_FEATURES_DYNAMIC:"cut-features-dynamic",SEARCH_PARCEL:"search-parcel"});netgis=netgis||{};
+netgis.OWS=function(){return{read:function(a,b){b={layers:[],folders:[]};netgis.util.isDefined(a.properties)&&(b.bbox=a.properties.bbox);a=a.features;for(var c=0;c"+b+"";d.setAttribute("type","button");c&&(d.onpointerdown=c);a&&a.appendChild(d);return d};
+netgis.Panel.prototype.show=function(){this.container.classList.contains("netgis-show")||(this.container.classList.add("netgis-show"),netgis.util.invoke(this.container,netgis.Events.PANEL_TOGGLE,{visible:!0,width:this.container.getBoundingClientRect().width}))};netgis.Panel.prototype.hide=function(){this.container.classList.contains("netgis-show")&&(this.container.classList.remove("netgis-show"),netgis.util.invoke(this.container,netgis.Events.PANEL_TOGGLE,{visible:!1}))};
+netgis.Panel.prototype.toggle=function(){this.container.classList.toggle("netgis-show");var a=this.container.classList.contains("netgis-show");netgis.util.invoke(this.container,netgis.Events.PANEL_TOGGLE,{visible:a,width:a?this.container.getBoundingClientRect().width:void 0})};netgis.Panel.prototype.visible=function(){return this.container.classList.contains("netgis-show")};netgis.Panel.prototype.width=function(){return this.container.getBoundingClientRect().width};
+netgis.Panel.prototype.setTitle=function(a){this.header.getElementsByTagName("span")[0].innerHTML=a};netgis.Panel.prototype.onHeaderClick=function(a){this.hide()};netgis.Panel.prototype.onResize=function(a){this.container.classList.contains("netgis-show")&&(a=this.container.getBoundingClientRect(),netgis.util.invoke(this.container,netgis.Events.PANEL_RESIZE,{width:a.width}))};netgis=netgis||{};netgis.Popup=function(){this.initElements()};
+netgis.Popup.prototype.initElements=function(){document.body.addEventListener("pointerdown",this.onDocumentPointerDown.bind(this));this.container=document.createElement("div");this.container.className="netgis-popup";this.container.addEventListener("pointerdown",this.onPointerDown.bind(this));this.content=document.createElement("div");this.content.className="netgis-content netgis-color-e netgis-round";this.container.appendChild(this.content);this.arrow=document.createElement("div");this.arrow.className=
+"netgis-arrow-down";this.container.appendChild(this.arrow);this.closer=document.createElement("button");this.closer.setAttribute("type","button");this.closer.className="netgis-closer netgis-color-e netgis-text-a";this.closer.innerHTML="";this.closer.onclick=this.onCloserClick.bind(this);this.content.appendChild(this.closer);this.loader=document.createElement("div");this.loader.className="netgis-loader netgis-text-a";this.loader.innerHTML="";
+this.wrapper=document.createElement("div");this.wrapper.className="netgis-wrapper";this.content.appendChild(this.wrapper)};netgis.Popup.prototype.attachTo=function(a){a.appendChild(this.container)};netgis.Popup.prototype.show=function(){this.container.classList.add("netgis-show")};netgis.Popup.prototype.hide=function(){this.container.classList.remove("netgis-show")};netgis.Popup.prototype.showLoader=function(){this.content.appendChild(this.loader)};
+netgis.Popup.prototype.hideLoader=function(){this.loader.parentNode===this.content&&this.content.removeChild(this.loader)};
+netgis.Popup.prototype.setPosition=function(a,b){var c=this.container.parentNode.getBoundingClientRect(),d=this.arrow.getBoundingClientRect();a>c.width-d.width&&(a=c.width-d.width);aa.x?this.content.style.left=-a.x+"px":a.x+a.width>c.width&&(this.content.style.left=-(a.x+a.width-c.width)+"px")};
+netgis.Popup.prototype.setHeader=function(a){this.closer.getElementsByTagName("span")[0].innerHTML=a};netgis.Popup.prototype.setContent=function(a){this.wrapper.innerHTML=a};netgis.Popup.prototype.clearContent=function(){this.wrapper.innerHTML=""};netgis.Popup.prototype.addContent=function(a){this.wrapper.innerHTML+=a};netgis.Popup.prototype.onDocumentPointerDown=function(a){};netgis.Popup.prototype.onPointerDown=function(a){a.stopPropagation()};netgis.Popup.prototype.onCloserClick=function(a){this.hide()};netgis=netgis||{};netgis.Search=function(a){this.debounce=400;this.initElements(a);this.initEvents()};
+netgis.Search.prototype.initElements=function(a){var b=document.createElement("div");b.className="netgis-search";this.container=b;var c=document.createElement("label");b.appendChild(c);this.label=c;var d=document.createElement("input");d.className="netgis-round netgis-shadow";d.setAttribute("type","text");d.setAttribute("placeholder",a);c.appendChild(d);this.input=d;a=document.createElement("button");a.setAttribute("type","button");a.innerHTML="";c.appendChild(a);this.button=
+a;a=document.createElement("button");a.setAttribute("type","button");a.className="netgis-hide";a.innerHTML="";c.appendChild(a);this.closer=a;c=document.createElement("ul");b.appendChild(c);this.results=c};
+netgis.Search.prototype.initEvents=function(){this.input.addEventListener("change",this.onInputChange.bind(this));this.input.addEventListener("keydown",this.onInputKeyDown.bind(this));this.input.addEventListener("keyup",this.onInputKeyUp.bind(this));this.button.addEventListener("click",this.onButtonClick.bind(this));this.closer.addEventListener("click",this.onCloserClick.bind(this))};netgis.Search.prototype.attachTo=function(a){a.appendChild(this.container)};netgis.Search.prototype.show=function(){this.container.classList.remove("netgis-hide")};
+netgis.Search.prototype.hide=function(){this.container.classList.add("netgis-hide")};netgis.Search.prototype.toggle=function(){this.container.classList.toggle("netgis-hide")};netgis.Search.prototype.isVisible=function(){return!this.container.classList.contains("netgis-hide")};netgis.Search.prototype.minimize=function(){this.container.classList.remove("netgis-color-e","netgis-shadow");this.input.classList.add("netgis-shadow")};
+netgis.Search.prototype.maximize=function(){this.container.classList.add("netgis-color-e","netgis-shadow");this.input.classList.remove("netgis-shadow")};netgis.Search.prototype.setTitle=function(a){this.input.setAttribute("placeholder",a)};
+netgis.Search.prototype.addResult=function(a,b){var c=document.createElement("li"),d=document.createElement("button");d.className="netgis-button netgis-clip-text netgis-color-e netgis-hover-a";d.innerHTML=a;d.setAttribute("type","button");d.setAttribute("title",d.innerText);d.setAttribute("data-result",b);d.addEventListener("click",this.onResultClick.bind(this));c.appendChild(d);0===this.results.childNodes.length&&(this.button.classList.add("netgis-hide"),this.closer.classList.remove("netgis-hide"));
+this.results.appendChild(c);this.maximize();return c};netgis.Search.prototype.clearResults=function(){this.results.innerHTML="";this.minimize();netgis.util.invoke(this.container,netgis.Events.SEARCH_CLEAR,null)};netgis.Search.prototype.clearAll=function(){this.clearResults();this.lastQuery=null;this.input.value="";this.button.classList.remove("netgis-hide");this.closer.classList.add("netgis-hide")};
+netgis.Search.prototype.requestSearch=function(a){this.lastQuery&&this.lastQuery===a||(this.lastQuery=a,netgis.util.invoke(this.container,netgis.Events.SEARCH_CHANGE,{query:a}))};netgis.Search.prototype.onInputKeyDown=function(a){if(13===a.keyCode)return a.preventDefault(),!1};netgis.Search.prototype.onInputKeyUp=function(a){switch(a.keyCode){case 13:a=this.results.getElementsByTagName("button");0";b.appendChild(this.nameLoader);this.nameList=document.createElement("ul");a.appendChild(this.nameList);
+b=this.createInput("Gemarkungsnummer:");this.districtInput=b.children[0];a.appendChild(b);b=this.createInput("Flurnummer:");this.fieldInput=b.children[0];this.fieldInput.addEventListener("keyup",this.onInputFieldKey.bind(this));a.appendChild(b);b=this.createInput("Flurst\u00fccksnummer (Z\u00e4hler/Nenner):");this.parcelInputA=b.children[1];this.parcelInputA.style.width="48%";this.parcelInputB=this.parcelInputA.cloneNode(!0);this.parcelInputB.style.marginLeft="4%";b.appendChild(this.parcelInputB);
+a.appendChild(b);b=document.createElement("button");b.setAttribute("type","button");b.addEventListener("click",this.onParcelSearchClick.bind(this));b.className="netgis-color-a netgis-hover-c";b.innerHTML="Flurst\u00fccke suchen";b.style.marginTop="4mm";a.appendChild(b);b=document.createElement("section");b.className="netgis-hide";this.bottom=b;this.container.appendChild(b);var c=document.createElement("button");c.className="netgis-button netgis-clip-text netgis-color-c";c.innerHTML="Flurst\u00fccke ";
+c.setAttribute("type","button");c.addEventListener("click",this.onBottomHeaderClick.bind(this));b.appendChild(c);this.parcelCount=c.getElementsByTagName("span")[1];this.parcelInfo=document.createElement("p");this.parcelTable=this.createTable(";Flur;Z\u00e4hler;Nenner;FKZ;Fl\u00e4che (qm)".split(";"));this.parcelTable.classList.add("netgis-hide");this.parcelTable.style.position="absolute";this.parcelTable.style.width="100%";this.parcelTable.style.top="12mm";this.parcelTable.style.bottom="0mm";this.parcelTable.style.margin=
+"0mm";this.parcelTable.style.overflow="auto";b.appendChild(this.parcelTable);this.parcelList=this.parcelTable.getElementsByTagName("tbody")[0];this.parcelReset=document.createElement("button");this.parcelReset.setAttribute("type","button");this.parcelReset.addEventListener("click",this.onResetClick.bind(this));this.parcelReset.className="netgis-color-a netgis-hover-c";this.parcelReset.innerHTML="Zur\u00fccksetzen";this.parcelReset.style.marginTop="4mm";a.appendChild(this.parcelReset)};
+netgis.SearchParcel.prototype.initEvents=function(){this.resizeObserver=(new ResizeObserver(this.onTopResize.bind(this))).observe(this.top)};
+netgis.SearchParcel.prototype.initConfig=function(a){this.districtsLayer=a.searchparcel.districts_service;this.districtsLayer.id=this.districtsLayerID;this.districtsLayer.style=a.styles.parcel;this.districtsLayer.order=99999;a.layers.push(this.districtsLayer);this.fieldsLayer={id:this.fieldsLayerID,type:netgis.LayerTypes.GEOJSON,style:a.styles.parcel,order:99999,data:null};a.layers.push(this.fieldsLayer);this.parcelsLayer={id:this.parcelsLayerID,type:netgis.LayerTypes.WKT,style:a.styles.parcel,order:99999,
+data:null};a.layers.push(this.parcelsLayer);if(!0===a.searchparcel.open){var b=this;window.setTimeout(function(){b.panel.show()},100)}};
+netgis.SearchParcel.prototype.attachTo=function(a){this.panel.attachTo(a);a.addEventListener(netgis.Events.CLIENT_SET_MODE,this.onClientSetMode.bind(this));a.addEventListener(netgis.Events.SEARCHPARCEL_TOGGLE,this.onSearchParcelToggle.bind(this));a.addEventListener(netgis.Events.LAYERTREE_TOGGLE,this.onLayerTreeToggle.bind(this));a.addEventListener(netgis.Events.TOOLBOX_TOGGLE,this.onToolboxToggle.bind(this));a.addEventListener(netgis.Events.MAP_FEATURE_ENTER,this.onMapFeatureEnter.bind(this));a.addEventListener(netgis.Events.MAP_FEATURE_CLICK,
+this.onMapFeatureClick.bind(this));a.addEventListener(netgis.Events.MAP_FEATURE_LEAVE,this.onMapFeatureLeave.bind(this))};netgis.SearchParcel.prototype.createInput=function(a){var b=document.createElement("label");b.className="netgis-hover-text-primary";b.innerHTML=a;a=document.createElement("input");a.setAttribute("type","text");b.appendChild(a);return b};
+netgis.SearchParcel.prototype.createNameItem=function(a){var b=document.createElement("li"),c=document.createElement("button");c.setAttribute("type","button");c.addEventListener("click",this.onNameItemClick.bind(this));c.className="netgis-color-e netgis-hover-a netgis-text-a netgis-hover-text-e";c.innerHTML=a;b.appendChild(c);return b};
+netgis.SearchParcel.prototype.createTable=function(a){var b=document.createElement("div");b.className="netgis-table-wrapper";var c=document.createElement("table");b.appendChild(c);var d=document.createElement("thead");c.appendChild(d);var e=document.createElement("tr");e.className="netgis-color-d netgis-shadow";d.appendChild(e);for(d=0;d";f.appendChild(g);f=document.createElement("td");f.innerHTML=a;h.appendChild(f);a=document.createElement("td");a.innerHTML=b;h.appendChild(a);b=document.createElement("td");
+b.innerHTML=c;h.appendChild(b);c=document.createElement("td");c.innerHTML=netgis.util.trim(d,"_");h.appendChild(c);d=document.createElement("td");d.innerHTML=e;h.appendChild(d);return h};
+netgis.SearchParcel.prototype.reset=function(){this.hideBottom();this.nameLoader.classList.add("netgis-hide");this.nameInput.value="";this.districtInput.value="";this.fieldInput.value="";this.parcelInputA.value="";this.parcelInputB.value="";this.nameList.innerHTML="";this.parcelInfo.innerHTML="";this.parcelList.innerHTML="";this.parcelTable.classList.add("netgis-hide");this.parcelReset.classList.add("netgis-hide");this.parcelCount.innerHTML="";var a=this;window.setTimeout(function(){a.top.scrollTop=
+0;a.parcelTable.scrollTop=0},10);netgis.util.invoke(this.container,netgis.Events.SEARCHPARCEL_RESET,null);this.panel.visible()&&this.showDistricts(!0);this.showFields(!1);this.showParcels(!1)};
+netgis.SearchParcel.prototype.showDistricts=function(a){a?(netgis.util.invoke(this.container,netgis.Events.MAP_LAYER_TOGGLE,{id:this.districtsLayerID,on:!0}),netgis.util.invoke(this.container,netgis.Events.MAP_ZOOM_LEVEL,{z:this.config.searchparcel.districts_service.min_zoom})):netgis.util.invoke(this.container,netgis.Events.MAP_LAYER_TOGGLE,{id:this.districtsLayerID,on:!1})};
+netgis.SearchParcel.prototype.showFields=function(a,b){a?(b.crs={type:"name",properties:{name:"urn:ogc:def:crs:EPSG::25832"}},this.fieldsLayer.data=b,netgis.util.invoke(this.container,netgis.Events.MAP_LAYER_TOGGLE,{id:this.fieldsLayerID,on:!0}),netgis.util.invoke(this.container,netgis.Events.MAP_ZOOM_LAYER,{id:this.fieldsLayerID})):(netgis.util.invoke(this.container,netgis.Events.MAP_LAYER_TOGGLE,{id:this.fieldsLayerID,on:!1}),this.fieldsLayer.data=null)};
+netgis.SearchParcel.prototype.showParcels=function(a,b){if(a){a=[];for(var c=0;c"+(b.filter_property+"");netgis.util.request(c+(""+a+""),this.onFieldsResponse.bind(this))};
+netgis.SearchParcel.prototype.onFieldsResponse=function(a){a=JSON.parse(a);this.showDistricts(!1);this.showFields(!0,a);this.showParcels(!1)};netgis.SearchParcel.prototype.selectFirstName=function(){var a=this.nameList.getElementsByTagName("button");0b?this.container.classList.add("netgis-scroll"):this.container.classList.remove("netgis-scroll")};
+netgis.Tabs.prototype.onHeaderButtonClick=function(a){a=a.currentTarget;for(var b=this.header.getElementsByClassName("netgis-button"),c=0,d=0;d=a;a++);var b=this;window.setTimeout(function(){b.container.scrollLeft=0},1)};
+netgis.TimeSlider.prototype.initElements=function(){this.container=document.createElement("section");this.container.className="netgis-timeslider netgis-footer netgis-noselect netgis-color-e netgis-hide";document.addEventListener("pointermove",this.onPointerMove.bind(this));document.addEventListener("pointerup",this.onPointerUp.bind(this));this.header=document.createElement("button");this.header.className="netgis-header netgis-button netgis-clip-text netgis-color-a netgis-hover-c netgis-shadow";this.header.innerHTML=
+"TimeSlider";this.header.setAttribute("type","button");this.header.addEventListener("click",this.onHeaderClick.bind(this));this.container.appendChild(this.header);this.wrapper=document.createElement("div");this.wrapper.className="netgis-wrapper";this.wrapper.addEventListener("pointerdown",this.onPointerDown.bind(this));this.container.appendChild(this.wrapper);this.table=document.createElement("table");this.wrapper.appendChild(this.table);
+this.top=document.createElement("tr");this.table.appendChild(this.top);this.bottom=document.createElement("tr")};netgis.TimeSlider.prototype.attachTo=function(a){a.appendChild(this.container);a.addEventListener(netgis.Events.TIMESLIDER_SHOW,this.onTimeSliderShow.bind(this));a.addEventListener(netgis.Events.TIMESLIDER_HIDE,this.onTimeSliderHide.bind(this))};
+netgis.TimeSlider.prototype.setVisible=function(a){a?(this.container.classList.remove("netgis-hide"),this.container.parentNode.classList.add("netgis-footer")):(this.container.classList.add("netgis-hide"),this.container.parentNode.classList.remove("netgis-footer"))};netgis.TimeSlider.prototype.setTitle=function(a){this.header.getElementsByTagName("span")[0].innerHTML=a};netgis.TimeSlider.prototype.clearTimeSteps=function(){this.top.innerHTML=""};
+netgis.TimeSlider.prototype.addTimeStep=function(a,b){var c=document.createElement("td");c.setAttribute("data-id",a);a=document.createElement("button");a.className="netgis-button netgis-color-e netgis-hover-d";a.innerHTML=""+b+"";a.setAttribute("type","button");a.addEventListener("click",this.onTimeStepClick.bind(this));c.appendChild(a);this.top.appendChild(c)};
+netgis.TimeSlider.prototype.addTimeStep_01=function(a,b){a=document.createElement("td");var c=document.createElement("td");this.insertTop?a.innerHTML=b:c.innerHTML=b;this.top.appendChild(a);this.bottom.appendChild(c);this.insertTop=!this.insertTop};
+netgis.TimeSlider.prototype.setActiveTimeStep=function(a){var b=this.top.getElementsByTagName("td"),c=b[a],d=c.getAttribute("data-id");console.info("Set Active Step:",a,d);for(var e=0;ea.length||(-1===a.indexOf("GetCapabilities")&&(a+="&REQUEST=GetCapabilities"),netgis.util.request(a,this.onServiceResponseWMST.bind(this),{id:b}))};
+netgis.TimeSlider.prototype.onServiceResponseWMST=function(a,b){for(var c=(new DOMParser).parseFromString(a,"text/xml").documentElement.getElementsByTagName("Layer"),d,e=0;eEinstellungen";b.setAttribute("type","button");b.addEventListener("click",this.onBottomHeaderClick.bind(this));this.bottom.appendChild(b);
+this.bottomTitle=b.getElementsByTagName("span")[0];a.toolbox&&!0===a.toolbox.open&&this.panel.show()};
+netgis.Toolbox.prototype.initOptions=function(a){var b=a.toolbox.options;if(b)for(var c in b);b=a.tools;a=[];b.buffer||(b.buffer={});this.bottomPanels.drawPoints=document.createElement("div");a.push(this.addCheckbox(this.bottomPanels.drawPoints,"Einrasten",this.onDrawSnapToggle.bind(this)));this.addCheckbox(this.bottomPanels.drawPoints,"Puffern",this.onDrawBufferToggle.bind(this));this.addInputNumber(this.bottomPanels.drawPoints,"Radius (Meter):",b.buffer.default_radius,this.onDrawBufferChange.bind(this));
+this.addInputNumber(this.bottomPanels.drawPoints,"Segmente:",b.buffer.default_segments,this.onDrawBufferChange.bind(this));this.bottom.appendChild(this.bottomPanels.drawPoints);this.bottomPanels.drawLines=document.createElement("div");a.push(this.addCheckbox(this.bottomPanels.drawLines,"Einrasten",this.onDrawSnapToggle.bind(this)));this.addCheckbox(this.bottomPanels.drawLines,"Puffern",this.onDrawBufferToggle.bind(this));this.addInputNumber(this.bottomPanels.drawLines,"Radius (Meter):",b.buffer.default_radius,
+this.onDrawBufferChange.bind(this));this.addInputNumber(this.bottomPanels.drawLines,"Segmente:",b.buffer.default_segments,this.onDrawBufferChange.bind(this));this.bottom.appendChild(this.bottomPanels.drawLines);this.showDrawBufferOptions(!1);this.bottomPanels.drawPolygons=document.createElement("div");a.push(this.addCheckbox(this.bottomPanels.drawPolygons,"Einrasten",this.onDrawSnapToggle.bind(this)));this.bottom.appendChild(this.bottomPanels.drawPolygons);this.bottomPanels.bufferFeatures=document.createElement("div");
+this.addInputNumber(this.bottomPanels.bufferFeatures,"Radius (Meter):",b.buffer.default_radius,this.onBufferFeaturesChange.bind(this));this.addInputNumber(this.bottomPanels.bufferFeatures,"Segmente:",b.buffer.default_segments,this.onBufferFeaturesChange.bind(this));this.addButton(this.bottomPanels.bufferFeatures,null,"Akzeptieren",this.onBufferFeaturesAccept.bind(this));this.bottom.appendChild(this.bottomPanels.bufferFeatures);
+this.bottomPanels.modifyFeatures=document.createElement("div");a.push(this.addCheckbox(this.bottomPanels.modifyFeatures,"Einrasten",this.onDrawSnapToggle.bind(this)));this.bottom.appendChild(this.bottomPanels.modifyFeatures);if(this.config.tools&&this.config.tools.snapping){if(!1===this.config.tools.snapping.show)for(b=0;b"+c+"";b.appendChild(g);c=document.createElement("label");
+g.appendChild(c);g=document.createElement("input");g.setAttribute("type","checkbox");g.onchange=this.onFolderChange.bind(this);c.appendChild(g);!0===e&&f.classList.add("netgis-nocheck");e=document.createElement("ul");b.appendChild(e);a=a?a.getElementsByTagName("ul")[0]:this.container;d?a.insertBefore(f,a.firstChild):a.appendChild(f);return f};
+netgis.Tree.prototype.addCheckbox=function(a,b,c,d,e,f){var g=document.createElement("li");g.className="netgis-item";var h=document.createElement("label");h.className="netgis-button netgis-noselect netgis-clip-text netgis-color-e netgis-hover-d";h.innerHTML=""+c+"";g.appendChild(h);c=document.createElement("input");c.setAttribute("type","checkbox");c.setAttribute("data-id",b);d&&(c.checked=d);c.onchange=this.onItemChange.bind(this);h.insertBefore(c,h.firstChild);f&&this.addItemDetails(g,
+b,f);a=a?a.getElementsByTagName("ul")[0]:this.container;e?a.insertBefore(g,a.firstChild):a.appendChild(g);return g};
+netgis.Tree.prototype.addRadioButton=function(a,b,c,d,e){var f=document.createElement("li");f.className="netgis-item";var g=document.createElement("label");g.className="netgis-button netgis-noselect netgis-clip-text netgis-color-e netgis-hover-d";g.innerHTML=""+c+"";f.appendChild(g);c=a?"radio-"+a.getAttribute("data-id"):"radio-noname";var h=document.createElement("input");h.setAttribute("type","radio");h.setAttribute("name",c);h.setAttribute("value","radio-"+b);h.setAttribute("data-id",
+b);d&&(h.checked=d);h.onchange=this.onItemChange.bind(this);g.insertBefore(h,g.firstChild);e&&this.addItemDetails(f,b,e);a?a.getElementsByTagName("ul")[0].appendChild(f):this.container.appendChild(f);return f};
+netgis.Tree.prototype.addButton=function(a,b,c,d){var e=document.createElement("li"),f=document.createElement("button");f.innerHTML=c;f.className="netgis-button netgis-color-e netgis-hover-d netgis-clip-text";f.setAttribute("type","button");e.appendChild(f);b&&f.setAttribute("data-id",b);d&&(f.onclick=d);f.addEventListener("click",this.onButtonClick.bind(this));a?a.getElementsByTagName("ul")[0].appendChild(e):this.container.appendChild(e);return e};
+netgis.Tree.prototype.addSpace=function(a){var b=document.createElement("li");b.className="netgis-space";a?a.getElementsByTagName("ul")[0].appendChild(b):this.container.appendChild(b);return b};
+netgis.Tree.prototype.addItemDetails=function(a,b,c){var d=document.createElement("details");d.className="netgis-noselect";var e=document.createElement("summary");e.className="netgis-clickable netgis-hover-d";e.innerHTML="";d.appendChild(e);e=document.createElement("div");d.appendChild(e);for(var f=0;fa.getBoundingClientRect().width:600>document.body.getBoundingClientRect().width},clone:function(a){return JSON.parse(JSON.stringify(a))},stringToID:function(a,
+b){b||(b="-");a=a.trim();a=a.toLowerCase();a=this.replace(a," ",b);a=this.replace(a,"\n",b);a=this.replace(a,"\t",b);a=this.replace(a,"\\.",b);a=this.replace(a,"\\,",b);a=this.replace(a,"\\!",b);a=this.replace(a,"\\?",b);a=this.replace(a,":",b);a=this.replace(a,";",b);a=this.replace(a,'"',b);a=this.replace(a,"'",b);a=this.replace(a,"\\\u00a7",b);a=this.replace(a,"\\$",b);a=this.replace(a,"\\%",b);a=this.replace(a,"\\&",b);a=this.replace(a,"\\/",b);a=this.replace(a,"\\\\",b);a=this.replace(a,"\\(",
+b);a=this.replace(a,"\\)",b);a=this.replace(a,"\\{",b);a=this.replace(a,"\\}",b);a=this.replace(a,"\\[",b);a=this.replace(a,"\\]",b);a=this.replace(a,"=",b);a=this.replace(a,"\\+",b);a=this.replace(a,"\\*",b);a=this.replace(a,"\\~",b);a=this.replace(a,"\\^",b);a=this.replace(a,"\\\u00b0",b);a=this.replace(a,"\u00b2",b);a=this.replace(a,"\u00b3",b);a=this.replace(a,"\\#",b);a=this.replace(a,"\\<",b);a=this.replace(a,"\\>",b);a=this.replace(a,"\\|",b);a=this.replace(a,"\\@",b);a=this.replace(a,"\u20ac",
+b);a=this.replace(a,"\u00b5",b);a=this.trim(a,b);a=this.replace(a,"\u00e4","ae");a=this.replace(a,"\u00f6","oe");a=this.replace(a,"\u00fc","ue");a=this.replace(a,"\u00df","ss");a=this.replace(a,"\u00e1","a");a=this.replace(a,"\u00e0","a");a=this.replace(a,"\u00e2","a");a=this.replace(a,"\u00e9","e");a=this.replace(a,"\u00e8","e");a=this.replace(a,"\u00ea","e");a=this.replace(a,"\u00ed","i");a=this.replace(a,"\u00ec","i");a=this.replace(a,"\u00ee","i");a=this.replace(a,"\u00f3","o");a=this.replace(a,
+"\u00f2","o");a=this.replace(a,"\u00f4","o");a=this.replace(a,"\u00fa","u");a=this.replace(a,"\u00f9","u");return a=this.replace(a,"\u00fb","u")},replace:function(a,b,e){return a.replace(new RegExp(b,"g"),e)},trim:function(a,b){a=a.replace(new RegExp("^"+b+"+"),"");return a=a.replace(new RegExp(b+"+$"),"")},foreach:a,template:function(b,d){a(d,function(a,c){b=b.replace(new RegExp("{"+a+"}","g"),c)});return b},newlines:function(a){return a.replace(/\n/g,"
")},create:function(a){var b=document.createElement("tbody");
+b.innerHTML=a;return b.children[0]},size:function(a){a=(new TextEncoder).encode(JSON.stringify(a)).length;var b=a/1024;return{bytes:a,kilobytes:b,megabytes:b/1024}},request:function(a,b,e){var c=new XMLHttpRequest;e&&(c._requestData=e);c.onload=function(){b(this.responseText,this._requestData,this)};c.withCredentials=!1;c.open("GET",a,!0);c.send();return c},downloadJSON:function(a,b){a="data:text/json;charset=utf-8,"+encodeURIComponent(JSON.stringify(a));var c=document.createElement("a");c.setAttribute("href",
+a);c.setAttribute("download",b);document.body.appendChild(c);c.click();c.remove()},padstr:function(a,b){for(a=a.toString();a.lengthc&&(c="0"+c);10>f&&(f="0"+f);10>g&&(g="0"+g);10>h&&(h="0"+h);10>b&&(b="0"+b);a=[a,c,f,"_",g,h,b].join("")}else a=b.getDate()+"."+(b.getMonth()+1)+
+"."+b.getFullYear(),a+=" "+b.getHours()+":"+b.getMinutes();return a},getUserLanguage:b,getFileExtension:function(a){a=a.split(".");return 1>=a.length?"":a[a.length-1]},formatDistance:function(a){return 100(e||1E5))?d?Math.round(a/1E6*1E3)/
+1E3:Math.round(a/1E6):d?Math.round(100*a)/100:Math.round(a);0===a&&(e=!1);a=a.toLocaleString(b());return a+(e?" km\u00b2":" m\u00b2")},hexToRGB:function(a){"#"===a.charAt(0)&&(a=a.substr(1));a=Number.parseInt(a,16);return[a>>16&255,a>>8&255,a&255]},invoke:function(a,b,e){a.dispatchEvent(new CustomEvent(b,{bubbles:!0,detail:e}))},handler:function(a,b){return function(c){b||(b=c);netgis.util.invoke(this,a,b)}}}}();netgis=netgis||{};netgis.WMC=function(){};netgis.WMC.prototype.requestContext=function(a,b){this.callback=b;netgis.util.request(a,this.onContextResponse.bind(this))};netgis.WMC.prototype.onContextResponse=function(a){a=JSON.parse(a);this.fromJSON(a)};netgis.WMC.prototype.requestLayers=function(a){a="./proxy.php?https://www.geoportal.rlp.de/mapbender/php/mod_callMetadata.php?languageCode=de&resultTarget=web&maxResults=40&resourceIds="+a.join(",");netgis.util.request(a,this.onLayersResponse.bind(this))};
+netgis.WMC.prototype.onLayersResponse=function(a){a=JSON.parse(a).wms.srv;this.services=[];for(var b=0;bd?1:0});this.callback&&this.callback({config:this.toConfig()})};
+netgis.WMC.prototype.parseLayers=function(a){var b=[];if(a)for(var c=0;cf?-1:0})};
+netgis.WMC.prototype.fromJSON=function(a){var b=a.wmc;this.id=b.id;this.title=b.title;this.crs=b.crs;var c=b.bbox;c=c.split(",");for(var d=0;dd?1:0});this.callback&&
+this.callback({config:this.toConfig()})};netgis.WMC.prototype.parseLayers=function(a){var b=[];if(a)for(var c=0;cf?-1:0})};
+netgis.WMC.prototype.fromJSON=function(a){var b=a.wmc;this.id=b.id;this.title=b.title;this.crs=b.crs;var c=b.bbox;c=c.split(",");for(b=0;bGeoPortal",modules:{search_parcel:!1},map:{attribution:this.title+", GeoPortal RLP",projection:this.crs,bbox:this.bbox,scalebar:!0},search:{url:"./proxy.php?https://www.geoportal.rlp.de/mapbender/geoportal/gaz_geom_mobile.php?outputFormat=json&resultTarget=web&searchEPSG={epsg}&maxResults=5&maxRows=5&featureClass=P&style=full&searchText={q}&name_startsWith={q}"}},b=[],c=[],d=this.layers.length,e=0;e
-
+
-
-
+
-
+
@@ -19,13 +17,14 @@
-
+
-
-
+
-
+