@@ -381,7 +381,7 @@ var mv = (function () {
381
381
} else {
382
382
$ ( "#search-message" ) . text ( "Aucun résultat pour cette recherche." ) ;
383
383
}
384
- } ,
384
+ } ,
385
385
386
386
getConfLayers : function ( ) {
387
387
// CAS 2 : Ajout d'une couche via ces paramètres
@@ -411,14 +411,18 @@ var mv = (function () {
411
411
. attr ( "data-layerid" , layerid )
412
412
. attr ( "data-title" , layername )
413
413
. attr ( "visible" , true )
414
+ . attr ( "tiled" , true )
415
+ . attr ( "queryable" , true )
414
416
. find ( ".layer-name" ) . text ( layername ) ;
415
417
var layer = {
416
418
"id" : layerid ,
417
419
"title" : layername ,
418
420
"name" : layername ,
419
421
"type" : layertype ,
420
422
"url" : layerurl ,
421
- "visible" : true
423
+ "visible" : true ,
424
+ "tiled" : true ,
425
+ "queryable" : true
422
426
} ;
423
427
424
428
// Paramètres supplémentaires si Vector-TMS
@@ -434,14 +438,7 @@ var mv = (function () {
434
438
$ ( "#mod-layerNew" ) . modal ( 'hide' ) ;
435
439
$ ( "#mod-themeOptions" ) . modal ( 'show' ) ;
436
440
437
- // Reset input
438
- document . getElementById ( 'newlayer-type' ) . value = '' ;
439
- [ ...document . querySelectorAll ( ".param-type" ) ] . forEach ( e => e . classList . add ( "d-none" ) ) ;
440
- [ ...document . querySelectorAll ( "#commonParamType >div" ) ] . forEach ( e => e . classList . add ( "d-none" ) ) ;
441
- [ ...newLayerByParam . querySelectorAll ( "input" ) ] . forEach ( function ( x ) {
442
- x . value = "" ;
443
- x . classList . remove ( "is-invalid" ) ;
444
- } ) ;
441
+ mv . resetConfLayer ( ) ;
445
442
return
446
443
}
447
444
// CAS 1 : Ajout d'une couche via un catalogue
@@ -491,6 +488,17 @@ var mv = (function () {
491
488
$ ( "#mod-themeOptions" ) . modal ( 'show' ) ;
492
489
//remove selection from results
493
490
$ ( ".ogc-result input[type='checkbox']:checked" ) . prop ( "checked" , false ) ;
491
+ } ,
492
+
493
+ resetConfLayer : function ( ) {
494
+ // Reset input
495
+ document . getElementById ( 'newlayer-type' ) . value = '' ;
496
+ [ ...document . querySelectorAll ( ".param-type" ) ] . forEach ( e => e . classList . add ( "d-none" ) ) ;
497
+ [ ...document . querySelectorAll ( "#commonParamType >div" ) ] . forEach ( e => e . classList . add ( "d-none" ) ) ;
498
+ [ ...newLayerByParam . querySelectorAll ( "input" ) ] . forEach ( function ( x ) {
499
+ x . value = "" ;
500
+ x . classList . remove ( "is-invalid" ) ;
501
+ } ) ;
494
502
} ,
495
503
496
504
resetSearch : function ( ) {
0 commit comments