make GetRecords request work against pyCSW

This commit is contained in:
Bart van den Eijnden
2012-01-16 14:25:29 +01:00
parent 0e8b3f2ff8
commit 33fd43d0ed

View File

@@ -30,6 +30,7 @@ OpenLayers.Format.CSWGetRecords.v2_0_2 = OpenLayers.Class(OpenLayers.Format.XML,
csw: "http://www.opengis.net/cat/csw/2.0.2",
dc: "http://purl.org/dc/elements/1.1/",
dct: "http://purl.org/dc/terms/",
gmd: "http://www.isotc211.org/2005/gmd",
geonet: "http://www.fao.org/geonetwork",
ogc: "http://www.opengis.net/ogc",
ows: "http://www.opengis.net/ows",
@@ -309,6 +310,7 @@ OpenLayers.Format.CSWGetRecords.v2_0_2 = OpenLayers.Class(OpenLayers.Format.XML,
*/
write: function(options) {
var node = this.writeNode("csw:GetRecords", options);
node.setAttribute("xmlns:gmd", this.namespaces.gmd);
return OpenLayers.Format.XML.prototype.write.apply(this, [node]);
},