Skip to content

Commit

Permalink
Do not query non-querable layers
Browse files Browse the repository at this point in the history
  • Loading branch information
tsauerwein committed May 26, 2016
1 parent c600a57 commit 5a48161
Show file tree
Hide file tree
Showing 4 changed files with 908 additions and 3 deletions.
21 changes: 20 additions & 1 deletion contribs/gmf/externs/gmf-themes.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ GmfThemesNode.prototype.children;


/**
* @type {Object.<string, string>}
* @type {Array.<GmfChildLayerNode>}
*/
GmfThemesNode.prototype.childLayers;

Expand Down Expand Up @@ -82,3 +82,22 @@ GmfThemesNode.prototype.url;
* @type {string|undefined}
*/
GmfThemesNode.prototype.wmsUrl;



/**
* @constructor
*/
var GmfChildLayerNode = function() {};


/**
* @type {string}
*/
GmfChildLayerNode.prototype.name;


/**
* @type {number|boolean|undefined}
*/
GmfChildLayerNode.prototype.queryable;
4 changes: 3 additions & 1 deletion contribs/gmf/src/services/querymanager.js
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,9 @@ gmf.QueryManager.prototype.createSources_ = function(node) {
if (node.childLayers && node.childLayers.length) {
var childLayerNames = [];
node.childLayers.forEach(function(childLayer) {
childLayerNames.push(childLayer.name);
if (childLayer.queryable) {
childLayerNames.push(childLayer.name);
}
}, this);
layers = childLayerNames.join(',');
} else if (node.type === 'WMS') {
Expand Down

0 comments on commit 5a48161

Please sign in to comment.