Skip to content

Commit

Permalink
Better parsing of wfs attributes (= better filters)
Browse files Browse the repository at this point in the history
  • Loading branch information
ger-benjamin committed Mar 13, 2018
1 parent 5ad6ec9 commit 138eab9
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion src/ol-ext/format/wfsattribute.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,18 @@ ngeo.format.WFSAttribute = class {
if (!ngeo.Attribute.setGeometryType(attribute, type)) {
if (type === 'gml:TimeInstantType') {
attribute.type = ngeo.AttributeType.DATETIME;
} else if (type === 'double') {
} else if (type === 'date') {
attribute.type = ngeo.AttributeType.DATE;
} else if (type === 'dateTime') {
attribute.type = ngeo.AttributeType.DATETIME;
} else if (type === 'time') {
attribute.type = ngeo.AttributeType.TIME;
} else if (type === 'decimal' || type === 'double') {
attribute.type = ngeo.AttributeType.NUMBER;
attribute.numType = ngeo.NumberType.FLOAT;
} else if (type === 'integer') {
attribute.type = ngeo.AttributeType.NUMBER;
attribute.numType = ngeo.NumberType.INTEGER;
} else {
attribute.type = ngeo.AttributeType.TEXT;
}
Expand Down

0 comments on commit 138eab9

Please sign in to comment.