Wrap values in <Literal>
This commit is contained in:
@@ -667,8 +667,14 @@ ol.format.WFS.writeIsNullFilter_ = function(node, filter, objectStack) {
|
||||
*/
|
||||
ol.format.WFS.writeIsBetweenFilter_ = function(node, filter, objectStack) {
|
||||
ol.format.WFS.writeOgcPropertyName_(node, filter.propertyName);
|
||||
ol.format.WFS.writeOgcExpression_('LowerBoundary', node, '' + filter.lowerBoundary);
|
||||
ol.format.WFS.writeOgcExpression_('UpperBoundary', node, '' + filter.upperBoundary);
|
||||
|
||||
var lowerBoundary = ol.xml.createElementNS('http://www.opengis.net/ogc', 'LowerBoundary');
|
||||
node.appendChild(lowerBoundary);
|
||||
ol.format.WFS.writeOgcLiteral_(lowerBoundary, '' + filter.lowerBoundary);
|
||||
|
||||
var upperBoundary = ol.xml.createElementNS('http://www.opengis.net/ogc', 'UpperBoundary');
|
||||
node.appendChild(upperBoundary);
|
||||
ol.format.WFS.writeOgcLiteral_(upperBoundary, '' + filter.upperBoundary);
|
||||
};
|
||||
|
||||
|
||||
|
||||
@@ -369,8 +369,8 @@ describe('ol.format.WFS', function() {
|
||||
' <ogc:Filter xmlns:ogc="http://www.opengis.net/ogc">' +
|
||||
' <ogc:PropertyIsBetween>' +
|
||||
' <ogc:PropertyName>area</ogc:PropertyName>' +
|
||||
' <ogc:LowerBoundary>100</ogc:LowerBoundary>' +
|
||||
' <ogc:UpperBoundary>1000</ogc:UpperBoundary>' +
|
||||
' <ogc:LowerBoundary><ogc:Literal>100</ogc:Literal></ogc:LowerBoundary>' +
|
||||
' <ogc:UpperBoundary><ogc:Literal>1000</ogc:Literal></ogc:UpperBoundary>' +
|
||||
' </ogc:PropertyIsBetween>' +
|
||||
' </ogc:Filter>' +
|
||||
'</wfs:Query>';
|
||||
|
||||
Reference in New Issue
Block a user