Hello;

In first place I want to apologize about writing in English; my French in not good enough. Second, I can't be sure there's no other reports of the error I found, so... Sorry again.

I started yesterday using the OpenLayers addition of GML 3.2, WFS 2.0 and FES 2.0. When using one of my custom filters I found that the class OpenLayers.Format.Filter.v2 hasn't have a way of dealing with FeatureId filters that are nested inside of an "And" or "Or" Filter.

Looking into the code of both the modified OpenLayers.Format.Filter.v2 and the OpenLayers original OpenLayers.Format.Filter.v1, I've build a rather fast and ugly roundabout changing the "And" and "Or" functions inside writers object:
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
            "And": function(filter) {
                var node = this.createElementNSPlus("fes:And");
                var childFilter;
                for(var i=0; i<filter.filters.length; ++i) {
                    childFilter = filter.filters[i];
	                var sub = childFilter.CLASS_NAME.split(".").pop();
	                if(sub == "FeatureId") {
	                    for(var i=0; i<childFilter.fids.length; ++i) {
	                        this.writeNode("FeatureId", childFilter.fids[i], node);
	                    }
	                } else {
	                    this.writeNode(this.getFilterType(childFilter), childFilter, node);
	                }
                }
                return node;
            },
            "Or": function(filter) {
                var node = this.createElementNSPlus("fes:Or");
                var childFilter;
                for(var i=0; i<filter.filters.length; ++i) {
                    childFilter = filter.filters[i];
	                var sub = childFilter.CLASS_NAME.split(".").pop();
	                if(sub == "FeatureId") {
	                    for(var i=0; i<childFilter.fids.length; ++i) {
	                        this.writeNode("FeatureId", childFilter.fids[i], node);
	                    }
	                } else {
	                    this.writeNode(this.getFilterType(childFilter), childFilter, node);
	                }
                }
                return node;
            },
I hope this is the place to report this. I haven't found any bug report place related.
The above solution it's not the best way to do it, but it's a first step and it works.

Thanks & regards from Spain.