@@ -158,29 +158,29 @@ const Map = (props: MapProps) => {
158158 setShowUncertainty ( true ) ;
159159 console . log ( 'getting capabilities for ' , currentLayer ) ;
160160
161- if ( layerConf . wms_secondary_layer_name ) {
162- if ( layerConf . wms_secondary_layer_name . indexOf ( '{' ) ) {
163- for ( let j of Object . keys ( currentMap ) ) {
164- layerConf . wms_secondary_layer_name =
165- layerConf . wms_secondary_layer_name . replaceAll (
166- '{' + j + '}' ,
167- currentMap [ j ] ,
168- ) ;
169- }
170- }
171- }
172-
173- if ( layerConf . wms_main_layer_name ) {
174- if ( layerConf . wms_main_layer_name . indexOf ( '{' ) ) {
175- for ( let j of Object . keys ( currentMap ) ) {
176- layerConf . wms_main_layer_name =
177- layerConf . wms_main_layer_name . replaceAll (
178- '{' + j + '}' ,
179- currentMap [ j ] ,
180- ) ;
181- }
182- }
183- }
161+ // if (layerConf.wms_secondary_layer_name) {
162+ // if (layerConf.wms_secondary_layer_name.indexOf('{')) {
163+ // for (let j of Object.keys(currentMap)) {
164+ // layerConf.wms_secondary_layer_name =
165+ // layerConf.wms_secondary_layer_name.replaceAll(
166+ // '{' + j + '}',
167+ // currentMap[j],
168+ // );
169+ // }
170+ // }
171+ // }
172+ //
173+ // if (layerConf.wms_main_layer_name) {
174+ // if (layerConf.wms_main_layer_name.indexOf('{')) {
175+ // for (let j of Object.keys(currentMap)) {
176+ // layerConf.wms_main_layer_name =
177+ // layerConf.wms_main_layer_name.replaceAll(
178+ // '{' + j + '}',
179+ // currentMap[j],
180+ // );
181+ // }
182+ // }
183+ // }
184184
185185 api . getCapabilities ( currentLayer ) . then ( ( x : string ) => {
186186 let xml = x ;
@@ -386,7 +386,7 @@ const Map = (props: MapProps) => {
386386 layer = { layerConf . wms_base_url }
387387 opacity = { opacity }
388388 show = {
389- showUncertainty
389+ showUncertainty || data !== 'forecast'
390390 ? layerConf . wms_main_layer_name
391391 : layerConf . wms_secondary_layer_name
392392 }
0 commit comments