import RelationshipElementInput from "@arcgis/core/widgets/BatchAttributeForm/inputs/RelationshipElementInput.js";const RelationshipElementInput = await $arcgis.import("@arcgis/core/widgets/BatchAttributeForm/inputs/RelationshipElementInput.js");- Inheritance
- RelationshipElementInput→
EditableInput<any>→ InputBase→ Accessor
- Since
- ArcGIS Maps SDK for JavaScript 5.1
This is a read-only support class that represents a relationship element in a BatchAttributeForm.
Constructors
Constructor
Parameters
| Parameter | Type | Description | Required |
|---|---|---|---|
| properties | | |
Properties
| Property | Type | Class |
|---|---|---|
| readonly inherited | ||
| readonly inherited | ||
| readonly | | |
| readonly | | |
| readonly inherited | ||
| readonly inherited | ||
| readonly inherited | ||
| readonly | | |
| readonly | | |
| readonly inherited | ||
| readonly | | |
| readonly inherited | ||
| readonly | | |
| readonly | | |
| readonly | "relationship" | |
| readonly | | |
| readonly inherited | ||
| readonly inherited |
displayCount
- Type
- number
A numeric value indicating the maximum number of related features to display in the list of related records.
If the total amount of features is greater than the displayCount, a Show all button displays.
- Default value
- 3
displayType
- Type
- string
A string value indicating how to display related records within the relationship content.
Currently, list is the only supported value.
| Value | Description |
|---|---|
| list | Shows a list of related records from the specified relationship. |
- Default value
- "list"
editable
- Type
- boolean
Indicates if the input is editable.
editType
- Type
- EditType
The type of edit operation the form is being used for. This can influence whether a field is editable or not (e.g., the layer only allows certain edit operations)
This is also the value that will be set for the Arcade variable
$editcontext.editType in the Arcade context used to evaluate form
expressions.
Accepted values are "INSERT", "UPDATE", "DELETE", and "NA".
For FieldInputs with value expressions, this property is also used in
determining whether or not the value expressions should be applied. Per the
Web Map Specification,
value expressions are ignored if the associated layer field is not
editable. Determining whether the layer field is editable must consider
whether the specific type of edit being attempted is allowed. For example,
if a layer has the supportsAdd capability but does not have the
supportsUpdate capability, then the value expression will be applied if
editType is INSERT but ignored if editType is UPDATE.
For the purposes of determining whether or not the layer allows the current
edit type, a value of "NA" is always considered allowed.
- Default value
- "NA"
existsInAllLayers
- Type
- boolean
Indicates whether the input pertains to all the features in the BatchAttributeForm in which the input belongs.
- Default value
- true
layer
Identifies the single feature layer associated with this relationship element. The layer must support feature editing and field access.
The following layer types are supported:
- FeatureLayer
- GeoJSONLayer
- SceneLayer (with
featureLayerproperty) - SubtypeSublayer
- OrientedImageryLayer
- KnowledgeGraphSublayer
layers
An array of layers included in the BatchAttributeForm. Each layer must support feature editing and field access.
The following layer types are supported:
- FeatureLayer
- GeoJSONLayer
- SceneLayer (with
featureLayerproperty) - SubtypeSublayer
- OrientedImageryLayer
- KnowledgeGraphSublayer
orderByFields
- Type
- RelatedRecordsInfoFieldOrder[] | null | undefined
An array of RelatedRecordsInfoFieldOrder
objects indicating the field display order for the related records
and whether they should be sorted in ascending asc or descending desc order.
relationshipId
- Type
- number
The numeric id value for the defined relationship.
This value can be found on the service
itself or on the service's relationships resource
if supportsRelationshipResource is true.
valid
- Type
- boolean
Indicates whether the input currently has valid user input.