Types
import type { BatchAttributeFormState, BatchAttributeFormMode, AttributeFormSupportedLayerUnion, SubmitResult, PendingAttachmentEdits } from "@arcgis/core/widgets/BatchAttributeForm/types.js";

Type definitions

BatchAttributeFormState

Type definition
Since
ArcGIS Maps SDK for JavaScript 5.0

The current state of the BatchAttributeForm.

Type
"not-loaded" | "loading" | "failed" | "loaded"

BatchAttributeFormMode

Type definition
Since
ArcGIS Maps SDK for JavaScript 5.0

The mode of the form.

Type
"single" | "batch"

AttributeFormSupportedLayerUnion

Type definition
Since
ArcGIS Maps SDK for JavaScript 5.0

An array of layers included in the BatchAttributeForm. Each layer must support feature editing and field access.

SubmitResult

Type definition
Since
ArcGIS Maps SDK for JavaScript 5.0

Describes the state of a single feature's attribute values at the time of a form submission.

feature

Property
Type
Graphic
Since
ArcGIS Maps SDK for JavaScript 5.0

The feature described by this result object.

invalidFields

Property
Type
string[]
Since
ArcGIS Maps SDK for JavaScript 5.0

The names of fields that have invalid values for this feature.

values

Property
Type
Graphic["attributes"]
Since
ArcGIS Maps SDK for JavaScript 5.0

The updated attribute values for the feature.

attachmentEdits

Property
Type
PendingAttachmentEdits[] | undefined
Since
ArcGIS Maps SDK for JavaScript 5.1

Staged attachment edits for this feature.

invalidAttachmentElementIds

Property
Type
string[] | undefined
Since
ArcGIS Maps SDK for JavaScript 5.1

The element ids of attachment elements that are currently invalid.

PendingAttachmentEdits

Type definition
Since
ArcGIS Maps SDK for JavaScript 5.1

Attachment edits staged for a single attachment element.

label

Property
Type
string | null | undefined
Since
ArcGIS Maps SDK for JavaScript 5.1

The display label of the attachment element input.

keywords

Property
Type
string | undefined
Since
ArcGIS Maps SDK for JavaScript 5.1

The keywords value configured on the attachment element input.

adds

Property
Type
AddAttachmentEdit[]
Since
ArcGIS Maps SDK for JavaScript 5.1

Attachments staged to be added.

updates

Property
Type
UpdateAttachmentEdit[]
Since
ArcGIS Maps SDK for JavaScript 5.1

Attachments staged to be updated.

deletes

Property
Type
DeleteAttachmentEdit[]
Since
ArcGIS Maps SDK for JavaScript 5.1

Attachments staged to be deleted.

BaseAttachmentEdit

Type definition
Since
ArcGIS Maps SDK for JavaScript 5.1

Information about an individual attachment edit, used for adding, updating, or deleting attachments.

feature

Property
Type
Graphic
Since
ArcGIS Maps SDK for JavaScript 5.1

The feature, objectId or globalId of the feature associated with the attachment.

contentType

Property
Type
string | undefined
Since
ArcGIS Maps SDK for JavaScript 5.1

The content type of the attachment. For example, 'image/jpeg'.

globalId

Property
Type
string
Since
ArcGIS Maps SDK for JavaScript 5.1

The unique globalId of the attachment.

keywords

Property
Type
string | undefined
Since
ArcGIS Maps SDK for JavaScript 5.1

The keywords value for an individual attachment.

name

Property
Type
string | undefined
Since
ArcGIS Maps SDK for JavaScript 5.1

The name of the attachment.

AddAttachmentEdit

Type definition
Since
ArcGIS Maps SDK for JavaScript 5.1

Information about a single attachment to be added.

Supertypes
BaseAttachmentEdit

data

Property
Type
Blob | File | string
Since
ArcGIS Maps SDK for JavaScript 5.1

The raw attachment data.

UpdateAttachmentEdit

Type definition
Since
ArcGIS Maps SDK for JavaScript 5.1

Information about a single attachment to be updated.

Supertypes
BaseAttachmentEdit

data

Property
Type
Blob | File | string
Since
ArcGIS Maps SDK for JavaScript 5.1

The raw attachment data.

id

Property
Type
number
Since
ArcGIS Maps SDK for JavaScript 5.1

The unique identifier of the attachment.

DeleteAttachmentEdit

Type definition
Since
ArcGIS Maps SDK for JavaScript 5.1

Information about a single attachment to be deleted.

Supertypes
BaseAttachmentEdit

id

Property
Type
number
Since
ArcGIS Maps SDK for JavaScript 5.1

The unique identifier of the attachment.

SubmitEvent

Type definition
Since
ArcGIS Maps SDK for JavaScript 5.0

name

Property
Type
"submit"
Since
ArcGIS Maps SDK for JavaScript 5.0

The name of the event.

results

Property
Type
SubmitResult[]
Since
ArcGIS Maps SDK for JavaScript 5.0

An array containing a result object for each feature in the form.

valid

Property
Type
boolean
Since
ArcGIS Maps SDK for JavaScript 5.0

Indicates whether the form is valid. This is true if all features in the form have valid attribute values, and false if any feature has at least one invalid attribute value.

AttachmentsChangeEvent

Type definition
Since
ArcGIS Maps SDK for JavaScript 5.1

name

Property
Type
"attachments-change"
Since
ArcGIS Maps SDK for JavaScript 5.1

The name of the event.

feature

Property
Type
Graphic
Since
ArcGIS Maps SDK for JavaScript 5.1

The feature whose attachment edits were updated.

attachmentEdits

Property
Type
PendingAttachmentEdits[]
Since
ArcGIS Maps SDK for JavaScript 5.1

The current attachment edits for the updated feature.

valid

Property
Type
boolean
Since
ArcGIS Maps SDK for JavaScript 5.1

Indicates whether the form is valid.

SelectedAttachmentIdentifier

Type definition
Since
ArcGIS Maps SDK for JavaScript 5.1

Selected attachment reference information.

ValueChangeActor

Type definition
Type
"user" | "expression"

ValueChangeEvent

Type definition
Since
ArcGIS Maps SDK for JavaScript 5.0

features

Property
Type
Graphic[]
Since
ArcGIS Maps SDK for JavaScript 5.0

The features affected by the value change.

fieldName

Property
Type
string
Since
ArcGIS Maps SDK for JavaScript 5.0

The name of the field that was changed.

name

Property
Type
"value-change"
Since
ArcGIS Maps SDK for JavaScript 5.0

The name of the event.

value

Property
Type
FieldValue
Since
ArcGIS Maps SDK for JavaScript 5.0

The updated field value.

ValuesChangeEvent

Type definition
Since
ArcGIS Maps SDK for JavaScript 5.1

Describes a field value change event with per-feature change details.

data

Property
Type
ValuesChangeData[]
Since
ArcGIS Maps SDK for JavaScript 5.1

The changed values for each affected feature.

fieldName

Property
Type
string | undefined
Since
ArcGIS Maps SDK for JavaScript 5.1

The field whose value was interactively changed. The event data may include changes to additional fields that were triggered by expressions.

For events where the source is expressions, this field will be undefined, no field is interactively changed in these cases.

name

Property
Type
"values-change"
Since
ArcGIS Maps SDK for JavaScript 5.1

The name of the event.

source

Property
Type
ValueChangeActor

Indicates whether the root cause of the values changing.

ValueDescription
"user"The value changes originated from a user-initiated change. The event may include expression-driven changes that were triggered as a result of the change the user made.
"expression"All value changes are the result of expressions evaluations, and the expressions were evaluated due to some condition other than a user-intiated value change. For example, the expressions were intially evaluated when the form was loaded.

ValuesChangeData

Type definition
Since
ArcGIS Maps SDK for JavaScript 5.1

Describes all field changes applied to a single feature during a values-change event.

feature

Property
Type
Graphic
Since
ArcGIS Maps SDK for JavaScript 5.1

The feature whose values changed.

changes

Property
Type
ValueChange[]
Since
ArcGIS Maps SDK for JavaScript 5.1

The field-level changes that were applied to the feature.

ValueChange

Type definition
Since
ArcGIS Maps SDK for JavaScript 5.1

Describes a single field change for a feature in a values-change event.

fieldName

Property
Type
string
Since
ArcGIS Maps SDK for JavaScript 5.1

The name of the field that changed.

value

Property
Type
FieldValue
Since
ArcGIS Maps SDK for JavaScript 5.1

The updated value for the field.

AttributeFormSupportedLayerInfo

Type definition
Since
ArcGIS Maps SDK for JavaScript 5.0

Configurations used for setting the layer's FormTemplate within BatchAttributeForm.

layer

Property
Type
AttributeFormSupportedLayerUnion
Since
ArcGIS Maps SDK for JavaScript 5.0

The associated layer containing the fields to edit.

formTemplate

Property
Type
FormTemplate | undefined
Since
ArcGIS Maps SDK for JavaScript 5.0

A template that defines the feature's form content. Use this when setting the fields for editing.