laptop and a wrench

Bug

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

Zuletzt veröffentlicht: April 23, 2015 ArcGIS API for JavaScript
Bug-ID-Nummer BUG-000086608
EingereichtApril 2, 2015
Zuletzt geändertJanuary 2, 2021
Gilt fürArcGIS API for JavaScript
Gefunden in Version3.13
Server-PlattformWindows
Client-Plattform7 64 Bit
Version Fixed3.14
StatusFixed

Workaround

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); } }

Schritte zur Reproduzierung

Bug-ID: BUG-000086608

Software:

  • ArcGIS API for JavaScript

Hilfe von ArcGIS-Expert*innen erhalten

Technischen Support kontaktieren

Die Esri Support-App herunterladen

Zu den Download-Optionen

Weitere Informationen zu diesem Thema erkunden