import UpdateWorkflow from "@arcgis/core/widgets/Editor/UpdateWorkflow.js";const UpdateWorkflow = await $arcgis.import("@arcgis/core/widgets/Editor/UpdateWorkflow.js");- Inheritance:
- UpdateWorkflow→
Workflow<UpdateWorkflowData‚ UpdateWorkflowStep>→ Accessor
- Since
- ArcGIS Maps SDK for JavaScript 4.15
A read-only class containing the logic used when updating and/or deleting features using the Editor widget.
This workflow is only enabled if the feature service allows this operation.
Constructors
Constructor
Parameters
| Parameter | Type | Description | Required |
|---|---|---|---|
| properties | | |
Properties
| Property | Type | Class |
|---|---|---|
data readonly | | |
declaredClass readonly inherited | ||
hasNextStep readonly inherited | ||
hasPreviousStep readonly | | |
started readonly inherited | ||
stepId readonly inherited | S | |
type readonly | "update" | |
data
- Type
- UpdateWorkflowData
- Since
- ArcGIS Maps SDK for JavaScript 4.30
The shared workflow data.
hasPreviousStep
- Type
- boolean
This property indicates if there is a previous step in the workflow.
stepId
- Type
- S
The name of the current step in the workflow.
Methods
| Method | Signature | Class |
|---|---|---|
cancel inherited | cancel(options?: CancelWorkflowOptions): Promise<void> | |
commit inherited | commit(): Promise<void> | |
emit inherited | emit<Type extends EventNames<this>>(type: Type, event?: this["@eventTypes"][Type]): boolean | |
hasEventListener inherited | hasEventListener<Type extends EventNames<this>>(type: Type): boolean | |
next inherited | next(): Promise<void> | |
on inherited | on<Type extends EventNames<this>>(type: Type, listener: EventedCallback<this["@eventTypes"][Type]>): ResourceHandle | |
previous inherited | previous(options?: WorkflowPreviousOptions): Promise<void> | |
reset inherited | reset(): Promise<void> | |
start inherited | start(): Promise<any> |
cancel
- Signature
-
cancel (options?: CancelWorkflowOptions): Promise<void>
Cancels the active workflow.
Parameters
| Parameter | Type | Description | Required |
|---|---|---|---|
| options | An object with the following properties. | |
emit
- Signature
-
emit <Type extends EventNames<this>>(type: Type, event?: this["@eventTypes"][Type]): boolean
- Type parameters
- <Type extends EventNames<this>>
Emits an event on the instance. This method should only be used when creating subclasses of this class.
hasEventListener
- Signature
-
hasEventListener <Type extends EventNames<this>>(type: Type): boolean
- Type parameters
- <Type extends EventNames<this>>
Indicates whether there is an event listener on the instance that matches the provided event name.
Parameters
| Parameter | Type | Description | Required |
|---|---|---|---|
| type | Type | The name of the event. | |
- Returns
- boolean
Returns true if the class supports the input event.
on
- Signature
-
on <Type extends EventNames<this>>(type: Type, listener: EventedCallback<this["@eventTypes"][Type]>): ResourceHandle
- Type parameters
- <Type extends EventNames<this>>
Registers an event handler on the instance. Call this method to hook an event with a listener.
Parameters
| Parameter | Type | Description | Required |
|---|---|---|---|
| type | Type | An event or an array of events to listen for. | |
| listener | EventedCallback<this["@eventTypes"][Type]> | The function to call when the event fires. | |
- Returns
- ResourceHandle
Returns an event handler with a
remove()method that should be called to stop listening for the event(s).Property Type Description remove Function When called, removes the listener from the event.
Example
view.on("click", function(event){ // event is the event handle returned after the event fires. console.log(event.mapPoint);}); previous
- Signature
-
previous (options?: WorkflowPreviousOptions): Promise<void>
Moves to the previous step in the workflow.
Parameters
| Parameter | Type | Description | Required |
|---|---|---|---|
| options | Options when calling this method. | |