laptop and a wrench

漏洞

Resizing the array of point graphics on the graphics layer does not reflect on the map view while zooming in or out when accessing the graphics.

上次发布: January 11, 2022 ArcGIS API for JavaScript
漏洞 ID 编号 BUG-000143342
已提交September 30, 2021
上次修改时间June 5, 2024
适用范围ArcGIS API for JavaScript
找到的版本4.21
操作系统Windows OS
操作系统版本10.0
状态Will Not Be Addressed

附加信息

The issue is due to a user error.

解决办法

To change Graphic.symbol at runtime, do one of the following:

  • Clone the symbol and change its properties.
  • Assign a new symbol.

The following code works. There is no need to remove and add graphics from GraphicsLayer to change graphic symbols. Use the layer.graphics.getItemAt() method to get the graphic instead of layer.graphics.items. 

var gp0 = layer.graphics.getItemAt(0);

var gp1 = layer.graphics.getItemAt(1);

var gp2 = layer.graphics.getItemAt(2);

const symbol0 = gp0.symbol.clone();

symbol0.size = 10 * rate;

   

gp0.symbol = symbol0;

gp1.symbol = symbol0;

gp2.symbol = symbol0;

重现步骤

漏洞 ID: BUG-000143342

软件:

  • ArcGIS API for JavaScript

当漏洞状态发生变化时获得通知

下载 Esri 支持应用程序

发现关于本主题的更多内容

获取来自 ArcGIS 专家的帮助

联系技术支持部门

下载 Esri 支持应用程序

转至下载选项