laptop and a wrench

Bogue

Reordered layers in a map service sample works incorrectly when all the layers are turned off.

Dernière publication: April 23, 2015 ArcGIS API for JavaScript
Numéro d’ID de bogue BUG-000086608
EnvoiApril 2, 2015
Dernière modificationJanuary 2, 2021
S’applique àArcGIS API for JavaScript
Version trouvée3.13
Plateforme serveurWindows
Plateforme client7 64 Bit
Version Fixed3.14
StatutFixed

Solution de contournement

Find the attached sample. Replace the code for Toggle Layers function with the following: function toggleLayer(e) { showLoading(); for (var info in infos) { var i = infos[info]; if (i.name === e.target.name) { i.visible = !i.visible; } } var visible = getVisibleLayers(); if (visible.length === 0) { usaLayer.setVisibleLayers([-1]); } else { usaLayer.setDynamicLayerInfos(visible); } }

Étapes pour reproduire

ID de bogue: BUG-000086608

Logiciel:

  • ArcGIS API for JavaScript

Obtenir de l’aide auprès des experts ArcGIS

Contacter le support technique

Télécharger l’application Esri Support

Accéder aux options de téléchargement

En savoir plus sur ce sujet