UpdateWorkflow

AMD: require(["esri/widgets/Editor/UpdateWorkflow"], (UpdateWorkflow) => { /* code goes here */ });
ESM: import UpdateWorkflow from "@arcgis/core/widgets/Editor/UpdateWorkflow";
Class: esri/widgets/Editor/UpdateWorkflow
Inheritance: UpdateWorkflow Workflow Accessor
Since: ArcGIS API for JavaScript 4.15

A read-only class containing the logic used when updating and/or deleting features using the Editor widget.

Update a single feature

editfeature

The following stages depict editing a single feature.

Stage Edit single feature example
1 - After selecting the feature to edit, the initial panel contains the UpdateWorkflowData.viewModel. selectfeature
2 - Once a feature is selected, the subsequent attribute panel has access to UpdateWorkflowData.edits, UpdateWorkflowData.editableItem, and UpdateWorkflowData.viewModel. updateattributes

Update multiple features

The following stages depict editing multiple features.

Stage edit multiple features example
1 - After selecting (ovelapped) features to edit, the initial panel contains the UpdateWorkflowData.viewModel. selectfeature
2 - If multiple features are selected, the subsequent attribute panel has access to UpdateWorkflowData.candidates and UpdateWorkflowData.viewModel. multiplefeatureselection
3 - Once a feature is selected, the subsequent attribute panel has access to UpdateWorkflowData.edits, UpdateWorkflowData.editableItem, and UpdateWorkflowData.viewModel. selectedfeatureupdate

This workflow is only enabled if the feature service allows this operation.

See also:

Property Overview

Any properties can be set, retrieved or listened to. See the Working with Properties topic.
Show inherited properties Hide inherited properties
Name Type Summary Class
CreateWorkflowData|CreateFeaturesWorkflowData|UpdateWorkflowDatamore details

The shared workflow data.

more detailsWorkflow
Stringmore details

The name of the class.

more detailsAccessor
Booleanmore details

This property indicates whether there is a next step in the workflow.

more detailsWorkflow
Booleanmore details

This property indicates if there is a previous step in the workflow.

more detailsWorkflow
Booleanmore details

Indicates whether the workflow is considered active.

more detailsWorkflow
Stringmore details

The name of the current step in the workflow.

more detailsWorkflow
Stringmore details

The type of workflow.

more detailsUpdateWorkflow

Property Details

The shared workflow data. This can be either CreateFeaturesWorkflowData (use this in place of the deprecated CreateWorkflowData) or UpdateWorkflowData.

declaredClass Stringreadonly inherited

The name of the class. The declared class name is formatted as esri.folder.className.

hasNextStep Booleanreadonly inherited

This property indicates whether there is a next step in the workflow.

hasPreviousStep Booleanreadonly inherited

This property indicates if there is a previous step in the workflow.

started Booleanreadonly inherited

Indicates whether the workflow is considered active.

Default Value:false
stepId Stringreadonly inherited

The name of the current step in the workflow.

type Stringreadonly

The type of workflow.

For UpdateWorkflow the type is always "update".

Method Overview

Show inherited methods Hide inherited methods
Name Return Type Summary Class
Promise<void>more details

Cancels the active workflow.

more detailsWorkflow
Promise<void>more details

Call this method when the workflow is considered finished.

more detailsWorkflow
Promise<void>more details

Moves to the next step in the workflow.

more detailsWorkflow
more details

Adds one or more handles which are to be tied to the lifecycle of the object.

more detailsAccessor
Promise<void>more details

Moves to the previous step in the workflow.

more detailsWorkflow
Promise<void>more details

Resets the workflow.

more detailsWorkflow
Promise<void>more details

Starts the workflow.

more detailsWorkflow

Method Details

cancel(){Promise<void>}inherited

Cancels the active workflow.

Returns:
Type Description
Promise<void> Resolves when the active workflow is canceled.
commit(){Promise<void>}inherited

Call this method when the workflow is considered finished. This is used to help process the editing results.

Returns:
Type Description
Promise<void> Resolves when the active workflow commits and processes the edited results.

Moves to the next step in the workflow.

Returns:
Type Description
Promise<void> Resolves when moved to the next step within the active workflow.
own(handleOrHandles)inherited
Since: ArcGIS API for JavaScript 4.24

Adds one or more handles which are to be tied to the lifecycle of the object. The handles will be removed when the object is destroyed.

// Manually manage handles
const handle = reactiveUtils.whenOnce(() => !view.updating)
  .then(() => {
    wkidSelect.disabled = false;
});

handle.remove();

// Assign a handle using own()
this.own(reactiveUtils.whenOnce(() => !view.updating)
  .then(() => {
    wkidSelect.disabled = false;
  }));
Parameter:
handleOrHandles WatchHandle|WatchHandle[]

Handles marked for removal once the object is destroyed.

Moves to the previous step in the workflow.

Parameters:
options Object
optional

Options when calling this method.

Specification:
cancelCurrentStep Boolean

Cancels the current workflow when calling this method. Default value is false.

Returns:
Type Description
Promise<void> Resolves when moved to the previous step within the active workflow.
reset(){Promise<void>}inherited

Resets the workflow.

Returns:
Type Description
Promise<void> Resolves when the active workflow is reset.
start(){Promise<void>}inherited

Starts the workflow.

Returns:
Type Description
Promise<void> Resolves when the active workflow starts.

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.