Skip to content

Interactive interface for browsing global, full-resolution satellite imagery

Began looping through measurements to match layer.id to category - Matching layer.id to display the category/source description.

ZachTRice7874b690e291
diff --git a/web/js/layers/wv.layers.info.js b/web/js/layers/wv.layers.info.js
index 5cf2deb72..492a61756 100644
--- a/web/js/layers/wv.layers.info.js
+++ b/web/js/layers/wv.layers.info.js
@@ -70,6 +70,23 @@ wv.layers.info = wv.layers.info || function(config, models, layer) {
wv.ui.closeDialog();
};
+ // TODO: Check if layer.id is in measurements.[name].sources.settings[layer.id],
+ // if it is, show that sources.description
+ // console.log(config);
+ // console.log(layer.id);
+
+ _.each(config.measurements, function( name, nameKey ) {
+ var current = config.measurements;
+ _.each(name, function( source, sourceKey ) {
+ // console.log(name);
+ if(name.sources) { console.log(name.sources); }
+ _.each(source, function( setting, settingKey ) {
+ // console.log(setting);
+ });
+ });
+ });
+
+ // TODO output the sources.description here. layer.metadata is incomplete.
var renderDescription = function($dialog) {
if( layer.metadata ) {
$.get('config/metadata/' + layer.metadata + '.html')