Преглед изворни кода

added WFS_URL to override in GetFeature js

Piotr Labudda пре 8 година
родитељ
комит
38593f9945
1 измењених фајлова са 9 додато и 0 уклоњено
  1. 9 0
      SE/static/p5WFS/GetFeature.js

+ 9 - 0
SE/static/p5WFS/GetFeature.js

@@ -121,6 +121,15 @@ function p5WFS_GetFeature(typeName, query) { // @returns Promise
 		'&REQUEST=GetFeature' +
 		'&TYPENAME=' + typeName +
 		'&SRSNAME=EPSG:3003'
+	;
+	if ('WFS_URL' in query && query['WFS_URL'].length) {
+		link = query['WFS_URL']
+		link += ( (-1 !== query['WFS_URL'].indexOf('?')) ? '&' : '?' )
+		link += 'SERVICE=WFS&VERSION=1.0.0'
+		link += '&REQUEST=GetFeature'
+		link += '&TYPENAME=' + typeName
+		link += '&SRSNAME=EPSG:3003'
+	}
 	//	'&Filter=<ogc:Filter><ogc:Or><ogc:PropertyIsEqualTo><ogc:PropertyName>ID</ogc:PropertyName><ogc:Literal>' + id + '</ogc:Literal></ogc:PropertyIsEqualTo></ogc:Or></ogc:Filter>'
 	var query = query || {}
 	if ('featureID' in query) link += '&featureID=' + query['featureID']