File tree Expand file tree Collapse file tree 2 files changed +18
-0
lines changed Expand file tree Collapse file tree 2 files changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -956,6 +956,16 @@ namespace QgsWms
956
956
else
957
957
layers = stylizedLayers ( params );
958
958
959
+ // add QUERY_LAYERS to list of available layers for more flexibility
960
+ for ( const QString &queryLayer : queryLayers )
961
+ {
962
+ if ( mNicknameLayers .contains ( queryLayer )
963
+ && !layers.contains ( mNicknameLayers [queryLayer] ) )
964
+ {
965
+ layers.append ( mNicknameLayers [queryLayer] );
966
+ }
967
+ }
968
+
959
969
// create the mapSettings and the output image
960
970
QgsMapSettings mapSettings;
961
971
std::unique_ptr<QImage> outputImage ( createImage () );
Original file line number Diff line number Diff line change @@ -84,6 +84,14 @@ def test_getfeatureinfo(self):
84
84
'query_layers=testlayer%20%C3%A8%C3%A9&X=190&Y=320' ,
85
85
'wms_getfeatureinfo-text-xml' )
86
86
87
+ self .wms_request_compare ('GetFeatureInfo' ,
88
+ '&layers=&styles=&' +
89
+ 'info_format=text%2Fxml&transparent=true&' +
90
+ 'width=600&height=400&srs=EPSG%3A3857&bbox=913190.6389747962%2C' +
91
+ '5606005.488876367%2C913235.426296057%2C5606035.347090538&' +
92
+ 'query_layers=testlayer%20%C3%A8%C3%A9&X=190&Y=320' ,
93
+ 'wms_getfeatureinfo-text-xml' )
94
+
87
95
# Test getfeatureinfo response html
88
96
self .wms_request_compare ('GetFeatureInfo' ,
89
97
'&layers=testlayer%20%C3%A8%C3%A9&styles=&' +
You can’t perform that action at this time.
0 commit comments