Editor widget with simple toolbar | ArcGIS API for JavaScript

This sample shows how to edit multiple feature layers using the Editor widget.The editor widget is highly customizable, developers can add and remove functionality depending on their editing use case. In this sample, you can edit existing hydrologic features or create new ones. The editor widget has an optional toolbar that lets the developer define additional functionality they want to include in the editing application. In this sample the freehand polygon and polyline drawing tools are added to provide end users the ability to sketch features as if they were drawing them with a pencil. The reshape tool is also added so end-users can easily adjust the shape of existing features. Note that a custom template picker is defined in the settings object. This is useful when you want to modify the default appearance of the template picker. In this case the number of columns is set and the template picker determines the appropriate number of rows. After defining the desired functionality you pass the settings to the params object then pass that into the Editor's constructor. This samples enables snapping, added at version 2.3, using the map.enableSnapping() method. Snapping can be disabled using map.disableSnapping(). In this snippet snapping is enabled for the editor and several snapping options are specified. Source.

Яндекс.Метрика Рейтинг@Mail.ru Free Web Counter
page counter
Last Modified: April 24, 2016 @ 7:03 am