From 7075a30ffff83b69e282020b01a692186074e490 Mon Sep 17 00:00:00 2001 From: Bart van den Eijnden Date: Tue, 16 Jul 2013 13:26:53 +0200 Subject: [PATCH] allow people to specify viewparams url parameter for sql views on WMS sources --- src/script/plugins/WMSSource.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/script/plugins/WMSSource.js b/src/script/plugins/WMSSource.js index 3ca9ee22..0e4dce85 100644 --- a/src/script/plugins/WMSSource.js +++ b/src/script/plugins/WMSSource.js @@ -440,6 +440,7 @@ gxp.plugins.WMSSource = Ext.extend(gxp.plugins.LayerSource, { layers: config.name, transparent: "transparent" in config ? config.transparent : true, cql_filter: config.cql_filter, + viewparams: config.viewparams, format: config.format }, { projection: srs @@ -516,7 +517,8 @@ gxp.plugins.WMSSource = Ext.extend(gxp.plugins.LayerSource, { STYLES: config.styles, FORMAT: config.format, TRANSPARENT: config.transparent, - CQL_FILTER: config.cql_filter + CQL_FILTER: config.cql_filter, + VIEWPARAMS: config.viewparams }); var singleTile = false; @@ -869,6 +871,7 @@ gxp.plugins.WMSSource = Ext.extend(gxp.plugins.LayerSource, { tiled: !options.singleTile, transparent: params.TRANSPARENT, cql_filter: params.CQL_FILTER, + viewparams: params.VIEWPARAMS, minscale: options.minScale, maxscale: options.maxScale, infoFormat: record.get("infoFormat")