@vertigis/arcgis-extensions 39.1.1 → 39.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AppConfig.schema.json +4 -0
- package/data/TaskSettings.d.ts +17 -0
- package/data/TaskSettings.js +1 -1
- package/docs/html/assets/search.js +1 -1
- package/docs/html/classes/data_TaskSettings.TaskSettings.html +28 -1
- package/docs/html/interfaces/data_TaskSettings.TaskSettingsProperties.html +8 -1
- package/docs/html/types/support__restApiJson.RestApiDomain.html +1 -1
- package/docs/html/variables/version.version.html +1 -1
- package/mapping/SubtypeGroupLayerExtension.js +1 -1
- package/package.json +1 -1
- package/support/_restApiJson.d.ts +3 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
|
@@ -46,6 +46,7 @@ that are performed on a map.</p>
|
|
|
46
46
|
<a href="data_TaskSettings.TaskSettings.html#enableSearch" class="tsd-index-link tsd-kind-accessor tsd-parent-kind-class"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-262144-path"></use><use href="#icon-262144-text"></use></svg><span>enable<wbr/>Search</span></a>
|
|
47
47
|
<a href="data_TaskSettings.TaskSettings.html#enableUpdate" class="tsd-index-link tsd-kind-accessor tsd-parent-kind-class"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-262144-path"></use><use href="#icon-262144-text"></use></svg><span>enable<wbr/>Update</span></a>
|
|
48
48
|
<a href="data_TaskSettings.TaskSettings.html#parent" class="tsd-index-link tsd-kind-accessor tsd-parent-kind-class tsd-is-inherited"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-262144-path"></use><use href="#icon-262144-text"></use></svg><span>parent</span></a>
|
|
49
|
+
<a href="data_TaskSettings.TaskSettings.html#useStudioSearch" class="tsd-index-link tsd-kind-accessor tsd-parent-kind-class"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-262144-path"></use><use href="#icon-262144-text"></use></svg><span>use<wbr/>Studio<wbr/>Search</span></a>
|
|
49
50
|
</div></section>
|
|
50
51
|
<section class="tsd-index-section">
|
|
51
52
|
<h3 class="tsd-index-heading">Methods</h3>
|
|
@@ -241,7 +242,32 @@ default.</p>
|
|
|
241
242
|
<li>
|
|
242
243
|
<h5>value: <a href="support_Settings.Settings.html" class="tsd-signature-type" data-tsd-kind="Class">Settings</a><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type" data-tsd-kind="Type parameter">TProperties</span><span class="tsd-signature-symbol">></span></h5></li></ul></div>
|
|
243
244
|
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources">
|
|
244
|
-
<p>Inherited from Settings.parent</p></aside></li></ul></section
|
|
245
|
+
<p>Inherited from Settings.parent</p></aside></li></ul></section>
|
|
246
|
+
<section class="tsd-panel tsd-member tsd-kind-accessor tsd-parent-kind-class"><a id="useStudioSearch" class="tsd-anchor"></a>
|
|
247
|
+
<h3 class="tsd-anchor-link"><span>use<wbr/>Studio<wbr/>Search</span><a href="#useStudioSearch" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
|
|
248
|
+
<ul class="tsd-signatures tsd-kind-accessor tsd-parent-kind-class">
|
|
249
|
+
<li class="tsd-signature" id="useStudioSearch.useStudioSearch-1"><span class="tsd-signature-symbol">get</span> useStudioSearch<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">boolean</span></li>
|
|
250
|
+
<li class="tsd-description">
|
|
251
|
+
<div class="tsd-comment tsd-typography"><p>Determines whether a second type of search should be available,
|
|
252
|
+
specifically VertiGIS Studio Search. Things to note:</p>
|
|
253
|
+
<ul>
|
|
254
|
+
<li>This setting requires enableSearch to be set to true in order to have any
|
|
255
|
+
effect.</li>
|
|
256
|
+
<li>By enabling this setting a new search index will be created in VertiGIS
|
|
257
|
+
Studio Search Designer.</li>
|
|
258
|
+
<li>Note that not all sources support VertiGIS Studio Search.</li>
|
|
259
|
+
<li>False by default.</li>
|
|
260
|
+
</ul>
|
|
261
|
+
</div>
|
|
262
|
+
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">boolean</span></h4></li>
|
|
263
|
+
<li class="tsd-signature" id="useStudioSearch.useStudioSearch-2"><span class="tsd-signature-symbol">set</span> useStudioSearch<span class="tsd-signature-symbol">(</span>value<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li>
|
|
264
|
+
<li class="tsd-description">
|
|
265
|
+
<div class="tsd-parameters">
|
|
266
|
+
<h4 class="tsd-parameters-title">Parameters</h4>
|
|
267
|
+
<ul class="tsd-parameter-list">
|
|
268
|
+
<li>
|
|
269
|
+
<h5>value: <span class="tsd-signature-type">boolean</span></h5></li></ul></div>
|
|
270
|
+
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4></li></ul></section></section>
|
|
245
271
|
<section class="tsd-panel-group tsd-member-group">
|
|
246
272
|
<h2>Methods</h2>
|
|
247
273
|
<section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class tsd-is-protected tsd-is-inherited"><a id="_getCollectionSetting" class="tsd-anchor"></a>
|
|
@@ -1277,6 +1303,7 @@ value, if any.</p>
|
|
|
1277
1303
|
<li class="tsd-kind-accessor tsd-parent-kind-class"><a href="data_TaskSettings.TaskSettings.html#enableSearch" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-262144-path"></use><use href="#icon-262144-text"></use></svg>enable<wbr/>Search</a></li>
|
|
1278
1304
|
<li class="tsd-kind-accessor tsd-parent-kind-class"><a href="data_TaskSettings.TaskSettings.html#enableUpdate" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-262144-path"></use><use href="#icon-262144-text"></use></svg>enable<wbr/>Update</a></li>
|
|
1279
1305
|
<li class="tsd-kind-accessor tsd-parent-kind-class tsd-is-inherited"><a href="data_TaskSettings.TaskSettings.html#parent" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-262144-path"></use><use href="#icon-262144-text"></use></svg>parent</a></li>
|
|
1306
|
+
<li class="tsd-kind-accessor tsd-parent-kind-class"><a href="data_TaskSettings.TaskSettings.html#useStudioSearch" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-262144-path"></use><use href="#icon-262144-text"></use></svg>use<wbr/>Studio<wbr/>Search</a></li>
|
|
1280
1307
|
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-protected tsd-is-inherited"><a href="data_TaskSettings.TaskSettings.html#_getCollectionSetting" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg>_get<wbr/>Collection<wbr/>Setting</a></li>
|
|
1281
1308
|
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-protected tsd-is-inherited"><a href="data_TaskSettings.TaskSettings.html#_getNestedSettings" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg>_get<wbr/>Nested<wbr/>Settings</a></li>
|
|
1282
1309
|
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-protected"><a href="data_TaskSettings.TaskSettings.html#_getSerializableProperties" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg>_get<wbr/>Serializable<wbr/>Properties</a></li>
|
|
@@ -39,6 +39,7 @@
|
|
|
39
39
|
<a href="data_TaskSettings.TaskSettingsProperties.html#enableQuery" class="tsd-index-link tsd-kind-property tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-1024-path"></use><use href="#icon-1024-text"></use></svg><span>enable<wbr/>Query?</span></a>
|
|
40
40
|
<a href="data_TaskSettings.TaskSettingsProperties.html#enableSearch" class="tsd-index-link tsd-kind-property tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-1024-path"></use><use href="#icon-1024-text"></use></svg><span>enable<wbr/>Search?</span></a>
|
|
41
41
|
<a href="data_TaskSettings.TaskSettingsProperties.html#enableUpdate" class="tsd-index-link tsd-kind-property tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-1024-path"></use><use href="#icon-1024-text"></use></svg><span>enable<wbr/>Update?</span></a>
|
|
42
|
+
<a href="data_TaskSettings.TaskSettingsProperties.html#useStudioSearch" class="tsd-index-link tsd-kind-property tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-1024-path"></use><use href="#icon-1024-text"></use></svg><span>use<wbr/>Studio<wbr/>Search?</span></a>
|
|
42
43
|
</div></section></div></details></section></section>
|
|
43
44
|
<section class="tsd-panel-group tsd-member-group">
|
|
44
45
|
<h2>Properties</h2>
|
|
@@ -81,6 +82,11 @@
|
|
|
81
82
|
<h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagOptional">Optional</code> <span>enable<wbr/>Update</span><a href="#enableUpdate" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
|
|
82
83
|
<div class="tsd-signature">enable<wbr/>Update<span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span></div>
|
|
83
84
|
<div class="tsd-comment tsd-typography"><p>See <a href="../classes/data_TaskSettings.TaskSettings.html#enableUpdate">enableUpdate</a>.</p>
|
|
85
|
+
</div></section>
|
|
86
|
+
<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-interface"><a id="useStudioSearch" class="tsd-anchor"></a>
|
|
87
|
+
<h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagOptional">Optional</code> <span>use<wbr/>Studio<wbr/>Search</span><a href="#useStudioSearch" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
|
|
88
|
+
<div class="tsd-signature">use<wbr/>Studio<wbr/>Search<span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span></div>
|
|
89
|
+
<div class="tsd-comment tsd-typography"><p>See <a href="../classes/data_TaskSettings.TaskSettings.html#useStudioSearch">useStudioSearch</a>.</p>
|
|
84
90
|
</div></section></section></div>
|
|
85
91
|
<div class="col-4 col-menu menu-sticky-wrap menu-highlight">
|
|
86
92
|
<div class="tsd-navigation settings">
|
|
@@ -665,5 +671,6 @@
|
|
|
665
671
|
<li class="tsd-kind-property tsd-parent-kind-interface"><a href="data_TaskSettings.TaskSettingsProperties.html#enableIdentify" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-1024-path"></use><use href="#icon-1024-text"></use></svg>enable<wbr/>Identify?</a></li>
|
|
666
672
|
<li class="tsd-kind-property tsd-parent-kind-interface"><a href="data_TaskSettings.TaskSettingsProperties.html#enableQuery" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-1024-path"></use><use href="#icon-1024-text"></use></svg>enable<wbr/>Query?</a></li>
|
|
667
673
|
<li class="tsd-kind-property tsd-parent-kind-interface"><a href="data_TaskSettings.TaskSettingsProperties.html#enableSearch" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-1024-path"></use><use href="#icon-1024-text"></use></svg>enable<wbr/>Search?</a></li>
|
|
668
|
-
<li class="tsd-kind-property tsd-parent-kind-interface"><a href="data_TaskSettings.TaskSettingsProperties.html#enableUpdate" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-1024-path"></use><use href="#icon-1024-text"></use></svg>enable<wbr/>Update?</a></li
|
|
674
|
+
<li class="tsd-kind-property tsd-parent-kind-interface"><a href="data_TaskSettings.TaskSettingsProperties.html#enableUpdate" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-1024-path"></use><use href="#icon-1024-text"></use></svg>enable<wbr/>Update?</a></li>
|
|
675
|
+
<li class="tsd-kind-property tsd-parent-kind-interface"><a href="data_TaskSettings.TaskSettingsProperties.html#useStudioSearch" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-1024-path"></use><use href="#icon-1024-text"></use></svg>use<wbr/>Studio<wbr/>Search?</a></li></ul></li></ul></nav></div></div>
|
|
669
676
|
<div class="overlay"></div><script src="../assets/main.js"></script></body></html>
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
<li><a href="../modules/support__restApiJson.html">support/_restApiJson</a></li>
|
|
17
17
|
<li><a href="support__restApiJson.RestApiDomain.html">RestApiDomain</a></li></ul>
|
|
18
18
|
<h1>Type alias RestApiDomain</h1></div>
|
|
19
|
-
<div class="tsd-signature">Rest<wbr/>Api<wbr/>Domain<span class="tsd-signature-symbol">:</span> <a href="../interfaces/support__restApiJson.RestApiRangeDomain.html" class="tsd-signature-type" data-tsd-kind="Interface">RestApiRangeDomain</a><span class="tsd-signature-symbol"> | </span><a href="../interfaces/support__restApiJson.RestApiCodedValueDomain.html" class="tsd-signature-type" data-tsd-kind="Interface">RestApiCodedValueDomain</a></div></div>
|
|
19
|
+
<div class="tsd-signature">Rest<wbr/>Api<wbr/>Domain<span class="tsd-signature-symbol">:</span> <a href="../interfaces/support__restApiJson.RestApiRangeDomain.html" class="tsd-signature-type" data-tsd-kind="Interface">RestApiRangeDomain</a><span class="tsd-signature-symbol"> | </span><a href="../interfaces/support__restApiJson.RestApiCodedValueDomain.html" class="tsd-signature-type" data-tsd-kind="Interface">RestApiCodedValueDomain</a><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-symbol">{ </span><br/><span> </span>type<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">"inherited"</span><span class="tsd-signature-symbol">; </span><br/><span class="tsd-signature-symbol">}</span></div></div>
|
|
20
20
|
<div class="col-4 col-menu menu-sticky-wrap menu-highlight">
|
|
21
21
|
<div class="tsd-navigation settings">
|
|
22
22
|
<details class="tsd-index-accordion"><summary class="tsd-accordion-summary">
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
<li><a href="../modules/version.html">version</a></li>
|
|
17
17
|
<li><a href="version.version.html">version</a></li></ul>
|
|
18
18
|
<h1>Variable version<code class="tsd-tag ts-flagConst">Const</code> </h1></div>
|
|
19
|
-
<div class="tsd-signature">version<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"39.
|
|
19
|
+
<div class="tsd-signature">version<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">"39.2.0"</span><span class="tsd-signature-symbol"> = "39.2.0"</span></div>
|
|
20
20
|
<div class="tsd-comment tsd-typography"><p>The current version of the Geocortex ArcGIS Extensions API.</p>
|
|
21
21
|
</div></div>
|
|
22
22
|
<div class="col-4 col-menu menu-sticky-wrap menu-highlight">
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{__decorate as e}from"tslib";import t from"@arcgis/core/layers/support/FeatureType.js";import r from"@arcgis/core/rest/support/AttachmentQuery";import{toAttachment as a}from"../data/Attachment.js";import{toGraphic as s}from"../data/Feature.js";import{FeatureSaveError as i}from"../data/FeatureSaveError.js";import{addAttachment as l,deleteAttachments as o,supportsAttachmentEditing as n}from"../data/support/attachments.js";import{SubtypeGroupLayer as p}from"../portal/SubtypeGroupLayer.js";import{SubtypeSublayer as u}from"../portal/SubtypeSublayer.js";import{Template as y}from"../portal/Template.js";import{cancelify as d}from"../support/Cancellable.js";import{serializable as c}from"../support/Serializable.js";import{ArcGISRelationshipCollection as
|
|
1
|
+
import{__decorate as e}from"tslib";import t from"@arcgis/core/layers/support/FeatureType.js";import r from"@arcgis/core/rest/support/AttachmentQuery";import{toAttachment as a}from"../data/Attachment.js";import{toGraphic as s}from"../data/Feature.js";import{FeatureSaveError as i}from"../data/FeatureSaveError.js";import{addAttachment as l,deleteAttachments as o,supportsAttachmentEditing as n}from"../data/support/attachments.js";import{SubtypeGroupLayer as p}from"../portal/SubtypeGroupLayer.js";import{SubtypeSublayer as u}from"../portal/SubtypeSublayer.js";import{Template as y}from"../portal/Template.js";import{cancelify as d}from"../support/Cancellable.js";import{serializable as c}from"../support/Serializable.js";import{ArcGISRelationshipCollection as m}from"../support/_ArcGISRelationshipCollection.js";import{executeQuery as h}from"../support/_query.js";import{ReadOnlyCollection as f}from"../utilities/ReadOnlyCollection.js";import{isFeatureLayer as b,isSubtypeGroupLayer as _}from"../utilities/_layers.js";import{parse as g}from"../utilities/number.js";import{SubtypeSublayerExtension as w}from"./SubtypeSublayerExtension.js";import{LayerExtension as F,LayerExtensionReadOnlySchema as E}from"./_LayerExtension.js";import{ArrayWrappedCollection as S}from"./support/ArrayWrappedCollection.js";import{addOutFields as C,getGlobalIdField as j,isGlobalIdUsed as A}from"./support/layers.js";let I=class extends F{get enableClientSideData(){return this._enableClientSideData}set enableClientSideData(e){this._enableClientSideData=e,this._updateClientSideFields()}get layer(){return super.layer}get sublayerExtensions(){return super.sublayerExtensions}get supportsSublayers(){return!0}get sublayersAreReadOnly(){return!1}get hasFeatures(){return!0}get _layerView(){return this.layer&&this.mapExtension?._allLayerViews.find((e=>e.layer===this.layer))}_getProjectWebmapJSON(){const e=super._getProjectWebmapJSON();return!e||this.dynamicallyAddedLayer||(e.layers=this.sublayerExtensions.toArray().map((e=>{const{layerDefinition:t,visibility:r,subtypeCode:a,layerType:s}=u.fromEsriApiSubtypeSublayer(e.sublayer),i={layerType:s,visibility:r,subtypeCode:a};return t?.drawingInfo&&(i.layerDefinition={drawingInfo:t.drawingInfo}),i}))),e}_createRelationships(){return new SubtypeGroupLayerRelationshipCollection(this)}async _onInitialize(){await super._onInitialize(),await this.relationships.initialize();const e=this.layer.sourceJSON?.templates?.map((e=>y.toEsriApiFeatureTemplate(e)));if(this.sublayerExtensions.filter((e=>!!e.sublayer)).forEach((t=>{const r=this.layer.sourceJSON?.types.filter((e=>e.name===t.title))[0]?.templates;r?t.sublayer.templates=r.map((e=>y.toEsriApiFeatureTemplate(e))):1!==e.length||1===this.sublayerExtensions.length||t.sublayer.templates?function(e){return 1===e.sublayer.templates.length&&"New Feature"===e.sublayer.templates[0].name}(t)&&(t.sublayer.templates[0].name=t.sublayer.title):t.sublayer.templates=e.map((e=>{const r=y.toEsriApiFeatureTemplate(y.fromEsriApiFeatureTemplate(e));r.name=t.title;const a=r.prototype?.attributes;return"number"==typeof a?.[this.layer.subtypeField]&&(a[this.layer.subtypeField]=t.sublayer.subtypeCode),r}))})),this.layer.subtypes){this._subtypes=this.layer.subtypes.map((e=>new t({id:e.code,name:e.name,domains:e.domains??{},templates:this.sublayerExtensions.map((e=>e.sublayer)).find((t=>t.subtypeCode===e.code)).templates})));for(const e of this._subtypes)for(const[t,r]of Object.entries(e.domains)){const e=this.layer.fields.find((e=>e.name===t));e&&!e.domain&&(e.domain=r)}}}async _postInitialize(){await super._postInitialize(),this._updateClientSideFields(),this._watchHandles.push(this.watch("layer",(()=>{this._updateClientSideFields()}),!0))}_capabilities(){const e=n(this.layer);return this.layer?.capabilities?.operations?{...this.layer.capabilities.operations,supportsAttachmentEditing:e}:{...super._capabilities(),supportsAttachmentEditing:e}}_createSublayerExtension(e){return new w(e)}_getSerializableProperties(){const e=super._getSerializableProperties();return{...e,layer:{...this._toPropertyDef(e.layer),default:{layerType:"SubtypeGroupLayer"}},enableClientSideData:{serializeModes:["initial"],default:!1},attachmentTypes:["initial"]}}_isSupportedLayer(e){return _(e)}_createSchema(){return new x(this)}async _getAttachments(e){if(!this.layer?.capabilities?.data?.supportsAttachment)return[];const t=+e.primaryKey,s=new r({objectIds:[t]}),i=await this.layer.queryAttachments(s);return i?.[t]?.length?i[t].map((e=>a(e,e.url))):[]}async _addAttachment(e,t){return l(e,this.layer,t,{attachmentTypes:this.attachmentTypes})}async _deleteAttachments(e,t){return o(e,this.layer,t)}async _applyPortalItemProperties(e){if("Feature Service"!==e.type)throw new Error(`Cannot create SubtypeGroupLayer from Portal item that has type: ${e.type}`);const t={layerType:"SubtypeGroupLayer"};let{url:r}=e;r.match(".*MapServer/\\d{1,}/?$")||r.match(".*FeatureServer/\\d{1,}/?$")||(r=`${r}/0`),t.url=r,await p.applyToEsriApiLayer(t,this.layer);const a=await e.fetchData();a&&await p.applyToEsriApiLayer(a,this.layer)}_getFeatures(e,t){if(!this.layer)return super._getFeatures(e,t);const r=this.layer.createQuery();return r.objectIds=e.map((e=>g(e))),r.where=void 0,r.outFields=t.outFields,r.returnGeometry=t.returnGeometry,h(r,this,this.layer,t.cancelToken)}async _addFeatures(e,t){const r=Array.from(e);if(0===r.length||!this.layer)return;const a=await this._applyEdits({addFeatures:r.map(s)},t);if(!a.addFeatureResults||a.addFeatureResults.length!==r.length)throw new i("Received malformed response from server while saving feature(s).");let l;if(a.addFeatureResults.forEach(((e,t)=>{const{objectId:a,globalId:s,error:o}=e,n=r[t];if(o){l=l||new i("Errors encountered when adding features.");const{title:r}=n;l.errors.set(`${r}-${t}`,new Error(`Failed to add feature '${r}'. ${e.error.name} : ${e.error.message}`))}else{const{primaryKeyField:e}=n.schema;n.attributes.set(e,a);const t=j(this.layer);t&&s&&n.attributes.set(t,s)}})),l)throw l}async _updateFeatures(e,t){const r=Array.from(e);if(0===r.length)return;const a=await this._applyEdits({updateFeatures:Array.from(e).map(s)},t);if(!a.updateFeatureResults||a.updateFeatureResults.length!==r.length)throw new i("Received malformed response from server while saving feature(s).");let l;if(a.updateFeatureResults.forEach(((e,t)=>{if(e.error){l=l||new i("Errors encountered when updating features.");const{primaryKey:a}=r[t];l.errors.set(a,new Error(`Failed to update feature with id ${a}. ${e.error.name} : ${e.error.message}`))}})),l)throw l}async _deleteFeatures(e,t){if(0===e.length)return;const r=await this._applyEdits({deleteFeatures:e.map((e=>({objectId:e})))},t);if(!r.deleteFeatureResults)throw new i("Received malformed response from server while saving feature(s).");let a;if(r.deleteFeatureResults.forEach(((t,r)=>{if(t.error){a=a||new i("Errors encountered when deleting features.");const s=e[r];a.errors.set(s,new Error(`Failed to delete feature with id ${s}. ${t.error.name} : ${t.error.message}`))}})),a)throw a}async _applyEdits(e,t={}){const r=A(this.layer,e),a=this.layer.applyEdits(e,{globalIdUsed:r}),s=await d(a,t.cancelToken);if(!s)throw new i("Received malformed response from server while saving feature(s).");return s}_updateClientSideFields(){this.layer&&this._enableClientSideData&&(C(this.layer,this.featureSettings.outFields),this.allSublayerExtensions.forEach((e=>C(this.layer,e.featureSettings.outFields))))}};I=e([c],I);export{I as SubtypeGroupLayerExtension};let x=class extends E{constructor(e){super(e),this._fieldCollection=this._createFieldCollection(),this._typesCollection=this._createTypesCollection()}get types(){return this._typesCollection}get _types(){return this._typesCollection}get _fields(){return this._fieldCollection}_createFieldCollection(){return new f(new S({parent:this._layerExtension,targetProperty:"layer",arrayProperty:"fields"}))}_createTypesCollection(){return new f(new S({parent:this._layerExtension,arrayProperty:"_subtypes"}))}_getPropertyBindings(){return{primaryKeyField:"objectIdField",geometryType:"geometryType",spatialReference:"spatialReference",displayField:"displayField",typeIdField:"subtypeField"}}};x=e([c],x);export{x as SubtypeGroupLayerSchema};export class SubtypeGroupLayerRelationshipCollection extends m{get _sourceUrl(){const e=this._source.layer;if(e)return`${e.url}/${e.layerId}`}get _sourceLayerId(){return this._source.layer?.layerId}_findRelatedSource(e){if(!this._source.mapExtension||!this._source.layer||!this._sourceUrl)return;const t=this._sourceUrl.slice(0,this._sourceUrl.length-`${this._sourceLayerId}`.length-1),r=this._source.mapExtension.allLayerExtensions.initializedItems.find((r=>(b(r.layer)||_(r.layer))&&r.layer.url===t&&r.layer.layerId===e));return r||this._source.mapExtension.tableExtensions.initializedItems.find((r=>b(r.table)&&r.table.url===t&&r.table.layerId===e))}}
|
package/package.json
CHANGED
|
@@ -4,7 +4,9 @@ export interface RestApiSubtype {
|
|
|
4
4
|
defaultValues?: Record<string, unknown>;
|
|
5
5
|
domains?: Record<string, RestApiDomain>;
|
|
6
6
|
}
|
|
7
|
-
export type RestApiDomain = RestApiRangeDomain | RestApiCodedValueDomain
|
|
7
|
+
export type RestApiDomain = RestApiRangeDomain | RestApiCodedValueDomain | {
|
|
8
|
+
type: "inherited";
|
|
9
|
+
};
|
|
8
10
|
export interface RestApiRangeDomain {
|
|
9
11
|
type: "range";
|
|
10
12
|
name: string;
|
package/version.d.ts
CHANGED
package/version.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const version="39.
|
|
1
|
+
export const version="39.2.0";
|