@webiny/api-headless-cms-ddb-es 0.0.0-unstable.9bd236cf5e → 0.0.0-unstable.9f53ea597d
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/README.md +6 -30
- package/configurations.d.ts +18 -15
- package/configurations.js +33 -45
- package/configurations.js.map +1 -1
- package/definitions/entry.d.ts +4 -6
- package/definitions/entry.js +8 -179
- package/definitions/entry.js.map +1 -1
- package/definitions/group.d.ts +6 -7
- package/definitions/group.js +8 -63
- package/definitions/group.js.map +1 -1
- package/definitions/model.d.ts +6 -7
- package/definitions/model.js +8 -107
- package/definitions/model.js.map +1 -1
- package/definitions/types.d.ts +65 -0
- package/definitions/types.js +0 -0
- package/elasticsearch/createElasticsearchIndex.d.ts +5 -5
- package/elasticsearch/createElasticsearchIndex.js +41 -36
- package/elasticsearch/createElasticsearchIndex.js.map +1 -1
- package/elasticsearch/deleteElasticsearchIndex.d.ts +5 -3
- package/elasticsearch/deleteElasticsearchIndex.js +19 -34
- package/elasticsearch/deleteElasticsearchIndex.js.map +1 -1
- package/exports/api/cms/opensearch.d.ts +9 -0
- package/exports/api/cms/opensearch.js +9 -0
- package/feature.d.ts +1 -0
- package/feature.js +201 -0
- package/feature.js.map +1 -0
- package/features/CmsEntryOpenSearchBodyModifier/abstractions.d.ts +16 -0
- package/features/CmsEntryOpenSearchBodyModifier/abstractions.js +5 -0
- package/features/CmsEntryOpenSearchBodyModifier/abstractions.js.map +1 -0
- package/features/CmsEntryOpenSearchBodyModifier/index.d.ts +1 -0
- package/features/CmsEntryOpenSearchBodyModifier/index.js +1 -0
- package/features/CmsEntryOpenSearchFieldIndex/CmsEntryOpenSearchFieldIndexRegistry.d.ts +14 -0
- package/features/CmsEntryOpenSearchFieldIndex/CmsEntryOpenSearchFieldIndexRegistry.js +42 -0
- package/features/CmsEntryOpenSearchFieldIndex/CmsEntryOpenSearchFieldIndexRegistry.js.map +1 -0
- package/features/CmsEntryOpenSearchFieldIndex/abstractions/CmsEntryOpenSearchFieldIndex.d.ts +32 -0
- package/features/CmsEntryOpenSearchFieldIndex/abstractions/CmsEntryOpenSearchFieldIndex.js +5 -0
- package/features/CmsEntryOpenSearchFieldIndex/abstractions/CmsEntryOpenSearchFieldIndex.js.map +1 -0
- package/features/CmsEntryOpenSearchFieldIndex/abstractions/CmsEntryOpenSearchFieldIndexRegistry.d.ts +11 -0
- package/features/CmsEntryOpenSearchFieldIndex/abstractions/CmsEntryOpenSearchFieldIndexRegistry.js +5 -0
- package/features/CmsEntryOpenSearchFieldIndex/abstractions/CmsEntryOpenSearchFieldIndexRegistry.js.map +1 -0
- package/features/CmsEntryOpenSearchFieldIndex/constants.d.ts +1 -0
- package/features/CmsEntryOpenSearchFieldIndex/constants.js +4 -0
- package/features/CmsEntryOpenSearchFieldIndex/constants.js.map +1 -0
- package/features/CmsEntryOpenSearchFieldIndex/feature.d.ts +4 -0
- package/features/CmsEntryOpenSearchFieldIndex/feature.js +29 -0
- package/features/CmsEntryOpenSearchFieldIndex/feature.js.map +1 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/DateTimeFieldIndex.d.ts +11 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/DateTimeFieldIndex.js +60 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/DateTimeFieldIndex.js.map +1 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/DefaultFieldIndex.d.ts +13 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/DefaultFieldIndex.js +33 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/DefaultFieldIndex.js.map +1 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/JsonFieldIndex.d.ts +10 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/JsonFieldIndex.js +21 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/JsonFieldIndex.js.map +1 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/LongTextFieldIndex.d.ts +10 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/LongTextFieldIndex.js +22 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/LongTextFieldIndex.js.map +1 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/NumberFieldIndex.d.ts +11 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/NumberFieldIndex.js +32 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/NumberFieldIndex.js.map +1 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/ObjectFieldIndex.d.ts +12 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/ObjectFieldIndex.js +107 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/ObjectFieldIndex.js.map +1 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/RichTextFieldIndex.d.ts +10 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/RichTextFieldIndex.js +21 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/RichTextFieldIndex.js.map +1 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/TextCompressedFieldIndex.d.ts +15 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/TextCompressedFieldIndex.js +40 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/TextCompressedFieldIndex.js.map +1 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/TextEncryptedFieldIndex.d.ts +15 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/TextEncryptedFieldIndex.js +40 -0
- package/features/CmsEntryOpenSearchFieldIndex/fields/TextEncryptedFieldIndex.js.map +1 -0
- package/features/CmsEntryOpenSearchFieldIndex/index.d.ts +3 -0
- package/features/CmsEntryOpenSearchFieldIndex/index.js +3 -0
- package/features/CmsEntryOpenSearchFilter/CmsEntryOpenSearchFilterRegistry.d.ts +11 -0
- package/features/CmsEntryOpenSearchFilter/CmsEntryOpenSearchFilterRegistry.js +36 -0
- package/features/CmsEntryOpenSearchFilter/CmsEntryOpenSearchFilterRegistry.js.map +1 -0
- package/features/CmsEntryOpenSearchFilter/abstractions/CmsEntryOpenSearchFilter.d.ts +37 -0
- package/features/CmsEntryOpenSearchFilter/abstractions/CmsEntryOpenSearchFilter.js +5 -0
- package/features/CmsEntryOpenSearchFilter/abstractions/CmsEntryOpenSearchFilter.js.map +1 -0
- package/features/CmsEntryOpenSearchFilter/abstractions/CmsEntryOpenSearchFilterRegistry.d.ts +9 -0
- package/features/CmsEntryOpenSearchFilter/abstractions/CmsEntryOpenSearchFilterRegistry.js +5 -0
- package/features/CmsEntryOpenSearchFilter/abstractions/CmsEntryOpenSearchFilterRegistry.js.map +1 -0
- package/features/CmsEntryOpenSearchFilter/constants.d.ts +1 -0
- package/features/CmsEntryOpenSearchFilter/constants.js +4 -0
- package/features/CmsEntryOpenSearchFilter/constants.js.map +1 -0
- package/features/CmsEntryOpenSearchFilter/feature.d.ts +4 -0
- package/features/CmsEntryOpenSearchFilter/feature.js +17 -0
- package/features/CmsEntryOpenSearchFilter/feature.js.map +1 -0
- package/features/CmsEntryOpenSearchFilter/fields/DefaultFilter.d.ts +9 -0
- package/features/CmsEntryOpenSearchFilter/fields/DefaultFilter.js +26 -0
- package/features/CmsEntryOpenSearchFilter/fields/DefaultFilter.js.map +1 -0
- package/features/CmsEntryOpenSearchFilter/fields/ObjectFilter.d.ts +9 -0
- package/features/CmsEntryOpenSearchFilter/fields/ObjectFilter.js +43 -0
- package/features/CmsEntryOpenSearchFilter/fields/ObjectFilter.js.map +1 -0
- package/features/CmsEntryOpenSearchFilter/fields/RefFilter.d.ts +9 -0
- package/features/CmsEntryOpenSearchFilter/fields/RefFilter.js +36 -0
- package/features/CmsEntryOpenSearchFilter/fields/RefFilter.js.map +1 -0
- package/features/CmsEntryOpenSearchFilter/index.d.ts +3 -0
- package/features/CmsEntryOpenSearchFilter/index.js +3 -0
- package/features/CmsEntryOpenSearchFullTextSearch/abstractions.d.ts +20 -0
- package/features/CmsEntryOpenSearchFullTextSearch/abstractions.js +5 -0
- package/features/CmsEntryOpenSearchFullTextSearch/abstractions.js.map +1 -0
- package/features/CmsEntryOpenSearchFullTextSearch/index.d.ts +1 -0
- package/features/CmsEntryOpenSearchFullTextSearch/index.js +1 -0
- package/features/CmsEntryOpenSearchQueryModifier/abstractions.d.ts +16 -0
- package/features/CmsEntryOpenSearchQueryModifier/abstractions.js +5 -0
- package/features/CmsEntryOpenSearchQueryModifier/abstractions.js.map +1 -0
- package/features/CmsEntryOpenSearchQueryModifier/index.d.ts +1 -0
- package/features/CmsEntryOpenSearchQueryModifier/index.js +1 -0
- package/features/CmsEntryOpenSearchSortModifier/abstractions.d.ts +15 -0
- package/features/CmsEntryOpenSearchSortModifier/abstractions.js +5 -0
- package/features/CmsEntryOpenSearchSortModifier/abstractions.js.map +1 -0
- package/features/CmsEntryOpenSearchSortModifier/index.d.ts +1 -0
- package/features/CmsEntryOpenSearchSortModifier/index.js +1 -0
- package/features/CmsEntryOpenSearchValueSearch/CmsEntryOpenSearchValueSearchRegistry.d.ts +12 -0
- package/features/CmsEntryOpenSearchValueSearch/CmsEntryOpenSearchValueSearchRegistry.js +31 -0
- package/features/CmsEntryOpenSearchValueSearch/CmsEntryOpenSearchValueSearchRegistry.js.map +1 -0
- package/features/CmsEntryOpenSearchValueSearch/abstractions/CmsEntryOpenSearchValueSearch.d.ts +22 -0
- package/features/CmsEntryOpenSearchValueSearch/abstractions/CmsEntryOpenSearchValueSearch.js +5 -0
- package/features/CmsEntryOpenSearchValueSearch/abstractions/CmsEntryOpenSearchValueSearch.js.map +1 -0
- package/features/CmsEntryOpenSearchValueSearch/abstractions/CmsEntryOpenSearchValueSearchRegistry.d.ts +10 -0
- package/features/CmsEntryOpenSearchValueSearch/abstractions/CmsEntryOpenSearchValueSearchRegistry.js +5 -0
- package/features/CmsEntryOpenSearchValueSearch/abstractions/CmsEntryOpenSearchValueSearchRegistry.js.map +1 -0
- package/features/CmsEntryOpenSearchValueSearch/feature.d.ts +4 -0
- package/features/CmsEntryOpenSearchValueSearch/feature.js +17 -0
- package/features/CmsEntryOpenSearchValueSearch/feature.js.map +1 -0
- package/features/CmsEntryOpenSearchValueSearch/fields/RefSearch.d.ts +10 -0
- package/features/CmsEntryOpenSearchValueSearch/fields/RefSearch.js +21 -0
- package/features/CmsEntryOpenSearchValueSearch/fields/RefSearch.js.map +1 -0
- package/features/CmsEntryOpenSearchValueSearch/fields/SearchableJsonSearch.d.ts +10 -0
- package/features/CmsEntryOpenSearchValueSearch/fields/SearchableJsonSearch.js +44 -0
- package/features/CmsEntryOpenSearchValueSearch/fields/SearchableJsonSearch.js.map +1 -0
- package/features/CmsEntryOpenSearchValueSearch/fields/TimeSearch.d.ts +10 -0
- package/features/CmsEntryOpenSearchValueSearch/fields/TimeSearch.js +22 -0
- package/features/CmsEntryOpenSearchValueSearch/fields/TimeSearch.js.map +1 -0
- package/features/CmsEntryOpenSearchValueSearch/index.d.ts +3 -0
- package/features/CmsEntryOpenSearchValueSearch/index.js +3 -0
- package/features/CmsEntryOpenSearchValuesModifier/abstractions.d.ts +23 -0
- package/features/CmsEntryOpenSearchValuesModifier/abstractions.js +5 -0
- package/features/CmsEntryOpenSearchValuesModifier/abstractions.js.map +1 -0
- package/features/CmsEntryOpenSearchValuesModifier/index.d.ts +1 -0
- package/features/CmsEntryOpenSearchValuesModifier/index.js +1 -0
- package/features/CmsModelOpenSearchIndex/CmsModelOpenSearchIndexProvider.d.ts +25 -0
- package/features/CmsModelOpenSearchIndex/CmsModelOpenSearchIndexProvider.js +36 -0
- package/features/CmsModelOpenSearchIndex/CmsModelOpenSearchIndexProvider.js.map +1 -0
- package/features/CmsModelOpenSearchIndex/DefaultCmsModelOpenSearchIndex.d.ts +8 -0
- package/features/CmsModelOpenSearchIndex/DefaultCmsModelOpenSearchIndex.js +17 -0
- package/features/CmsModelOpenSearchIndex/DefaultCmsModelOpenSearchIndex.js.map +1 -0
- package/features/CmsModelOpenSearchIndex/abstractions.d.ts +20 -0
- package/features/CmsModelOpenSearchIndex/abstractions.js +5 -0
- package/features/CmsModelOpenSearchIndex/abstractions.js.map +1 -0
- package/features/CmsModelOpenSearchIndex/feature.d.ts +4 -0
- package/features/CmsModelOpenSearchIndex/feature.js +13 -0
- package/features/CmsModelOpenSearchIndex/feature.js.map +1 -0
- package/features/CmsModelOpenSearchIndex/index.d.ts +3 -0
- package/features/CmsModelOpenSearchIndex/index.js +3 -0
- package/helpers/entryIndexHelpers.d.ts +13 -11
- package/helpers/entryIndexHelpers.js +71 -181
- package/helpers/entryIndexHelpers.js.map +1 -1
- package/helpers/fieldIdentifier.d.ts +1 -1
- package/helpers/fieldIdentifier.js +18 -38
- package/helpers/fieldIdentifier.js.map +1 -1
- package/helpers/index.d.ts +2 -2
- package/helpers/index.js +2 -29
- package/index.d.ts +1 -3
- package/index.js +1 -225
- package/operations/entry/dataLoader/DataLoaderCache.d.ts +1 -2
- package/operations/entry/dataLoader/DataLoaderCache.js +21 -35
- package/operations/entry/dataLoader/DataLoaderCache.js.map +1 -1
- package/operations/entry/dataLoader/constants.js +2 -7
- package/operations/entry/dataLoader/constants.js.map +1 -1
- package/operations/entry/dataLoader/createBatchScheduleFn.js +7 -22
- package/operations/entry/dataLoader/createBatchScheduleFn.js.map +1 -1
- package/operations/entry/dataLoader/getAllEntryRevisions.d.ts +3 -3
- package/operations/entry/dataLoader/getAllEntryRevisions.js +20 -41
- package/operations/entry/dataLoader/getAllEntryRevisions.js.map +1 -1
- package/operations/entry/dataLoader/getLatestRevisionByEntryId.d.ts +3 -3
- package/operations/entry/dataLoader/getLatestRevisionByEntryId.js +30 -48
- package/operations/entry/dataLoader/getLatestRevisionByEntryId.js.map +1 -1
- package/operations/entry/dataLoader/getPublishedRevisionByEntryId.d.ts +3 -3
- package/operations/entry/dataLoader/getPublishedRevisionByEntryId.js +30 -48
- package/operations/entry/dataLoader/getPublishedRevisionByEntryId.js.map +1 -1
- package/operations/entry/dataLoader/getRevisionById.d.ts +3 -3
- package/operations/entry/dataLoader/getRevisionById.js +36 -58
- package/operations/entry/dataLoader/getRevisionById.js.map +1 -1
- package/operations/entry/dataLoader/index.d.ts +3 -3
- package/operations/entry/dataLoader/index.js +13 -35
- package/operations/entry/dataLoader/index.js.map +1 -1
- package/operations/entry/dataLoader/types.d.ts +4 -4
- package/operations/entry/dataLoader/types.js +0 -7
- package/operations/entry/dataLoaders.d.ts +13 -13
- package/operations/entry/dataLoaders.js +83 -109
- package/operations/entry/dataLoaders.js.map +1 -1
- package/operations/entry/elasticsearch/assignMinimumShouldMatchToQuery.d.ts +1 -1
- package/operations/entry/elasticsearch/assignMinimumShouldMatchToQuery.js +6 -31
- package/operations/entry/elasticsearch/assignMinimumShouldMatchToQuery.js.map +1 -1
- package/operations/entry/elasticsearch/body.d.ts +25 -6
- package/operations/entry/elasticsearch/body.js +83 -136
- package/operations/entry/elasticsearch/body.js.map +1 -1
- package/operations/entry/elasticsearch/fields/createSystemField.d.ts +4 -0
- package/operations/entry/elasticsearch/fields/createSystemField.js +9 -0
- package/operations/entry/elasticsearch/fields/createSystemField.js.map +1 -0
- package/operations/entry/elasticsearch/fields/live.d.ts +2 -0
- package/operations/entry/elasticsearch/fields/live.js +50 -0
- package/operations/entry/elasticsearch/fields/live.js.map +1 -0
- package/operations/entry/elasticsearch/fields/location.d.ts +2 -0
- package/operations/entry/elasticsearch/fields/location.js +50 -0
- package/operations/entry/elasticsearch/fields/location.js.map +1 -0
- package/operations/entry/elasticsearch/fields/state.d.ts +2 -0
- package/operations/entry/elasticsearch/fields/state.js +104 -0
- package/operations/entry/elasticsearch/fields/state.js.map +1 -0
- package/operations/entry/elasticsearch/fields.d.ts +8 -6
- package/operations/entry/elasticsearch/fields.js +198 -306
- package/operations/entry/elasticsearch/fields.js.map +1 -1
- package/operations/entry/elasticsearch/filtering/applyFiltering.d.ts +6 -5
- package/operations/entry/elasticsearch/filtering/applyFiltering.js +35 -56
- package/operations/entry/elasticsearch/filtering/applyFiltering.js.map +1 -1
- package/operations/entry/elasticsearch/filtering/exec.d.ts +13 -8
- package/operations/entry/elasticsearch/filtering/exec.js +91 -170
- package/operations/entry/elasticsearch/filtering/exec.js.map +1 -1
- package/operations/entry/elasticsearch/filtering/index.d.ts +1 -1
- package/operations/entry/elasticsearch/filtering/index.js +1 -18
- package/operations/entry/elasticsearch/filtering/path.d.ts +4 -3
- package/operations/entry/elasticsearch/filtering/path.js +24 -45
- package/operations/entry/elasticsearch/filtering/path.js.map +1 -1
- package/operations/entry/elasticsearch/filtering/populated.d.ts +2 -2
- package/operations/entry/elasticsearch/filtering/populated.js +8 -21
- package/operations/entry/elasticsearch/filtering/populated.js.map +1 -1
- package/operations/entry/elasticsearch/filtering/values.d.ts +1 -1
- package/operations/entry/elasticsearch/filtering/values.js +11 -20
- package/operations/entry/elasticsearch/filtering/values.js.map +1 -1
- package/operations/entry/elasticsearch/fullTextSearch.d.ts +7 -6
- package/operations/entry/elasticsearch/fullTextSearch.js +45 -85
- package/operations/entry/elasticsearch/fullTextSearch.js.map +1 -1
- package/operations/entry/elasticsearch/fullTextSearchFields.d.ts +4 -4
- package/operations/entry/elasticsearch/fullTextSearchFields.js +7 -24
- package/operations/entry/elasticsearch/fullTextSearchFields.js.map +1 -1
- package/operations/entry/elasticsearch/initialQuery.d.ts +5 -4
- package/operations/entry/elasticsearch/initialQuery.js +36 -99
- package/operations/entry/elasticsearch/initialQuery.js.map +1 -1
- package/operations/entry/elasticsearch/keyword.d.ts +1 -1
- package/operations/entry/elasticsearch/keyword.js +14 -33
- package/operations/entry/elasticsearch/keyword.js.map +1 -1
- package/operations/entry/elasticsearch/plugins/operator.d.ts +4 -5
- package/operations/entry/elasticsearch/plugins/operator.js +7 -36
- package/operations/entry/elasticsearch/plugins/operator.js.map +1 -1
- package/operations/entry/elasticsearch/shouldIgnoreEsResponseError.js +6 -11
- package/operations/entry/elasticsearch/shouldIgnoreEsResponseError.js.map +1 -1
- package/operations/entry/elasticsearch/sort.d.ts +9 -6
- package/operations/entry/elasticsearch/sort.js +74 -83
- package/operations/entry/elasticsearch/sort.js.map +1 -1
- package/operations/entry/elasticsearch/transformValueForSearch.d.ts +3 -10
- package/operations/entry/elasticsearch/transformValueForSearch.js +9 -29
- package/operations/entry/elasticsearch/transformValueForSearch.js.map +1 -1
- package/operations/entry/elasticsearch/types.d.ts +4 -14
- package/operations/entry/elasticsearch/types.js +0 -7
- package/operations/entry/index.d.ts +32 -5
- package/operations/entry/index.js +1332 -1845
- package/operations/entry/index.js.map +1 -1
- package/operations/entry/keys.d.ts +31 -1
- package/operations/entry/keys.js +44 -27
- package/operations/entry/keys.js.map +1 -1
- package/operations/entry/recordType.js +4 -18
- package/operations/entry/recordType.js.map +1 -1
- package/operations/entry/transformations/convertEntryKeys.d.ts +6 -6
- package/operations/entry/transformations/convertEntryKeys.js +21 -34
- package/operations/entry/transformations/convertEntryKeys.js.map +1 -1
- package/operations/entry/transformations/index.d.ts +22 -18
- package/operations/entry/transformations/index.js +87 -123
- package/operations/entry/transformations/index.js.map +1 -1
- package/operations/entry/transformations/modifyEntryValues.d.ts +30 -35
- package/operations/entry/transformations/modifyEntryValues.js +12 -24
- package/operations/entry/transformations/modifyEntryValues.js.map +1 -1
- package/operations/entry/transformations/transformEntryKeys.d.ts +8 -8
- package/operations/entry/transformations/transformEntryKeys.js +14 -24
- package/operations/entry/transformations/transformEntryKeys.js.map +1 -1
- package/operations/entry/transformations/transformEntryToIndex.d.ts +8 -8
- package/operations/entry/transformations/transformEntryToIndex.js +17 -28
- package/operations/entry/transformations/transformEntryToIndex.js.map +1 -1
- package/operations/group/index.d.ts +7 -6
- package/operations/group/index.js +112 -170
- package/operations/group/index.js.map +1 -1
- package/operations/model/index.d.ts +6 -4
- package/operations/model/index.js +111 -175
- package/operations/model/index.js.map +1 -1
- package/package.json +36 -36
- package/tasks/CreateElasticsearchIndexTask.d.ts +14 -0
- package/tasks/CreateElasticsearchIndexTask.js +40 -0
- package/tasks/CreateElasticsearchIndexTask.js.map +1 -0
- package/types.d.ts +24 -135
- package/types.js +7 -39
- package/types.js.map +1 -1
- package/values/NoValueContainer.js +7 -16
- package/values/NoValueContainer.js.map +1 -1
- package/definitions/entryElasticsearch.d.ts +0 -9
- package/definitions/entryElasticsearch.js +0 -41
- package/definitions/entryElasticsearch.js.map +0 -1
- package/definitions/system.d.ts +0 -9
- package/definitions/system.js +0 -42
- package/definitions/system.js.map +0 -1
- package/definitions/table.d.ts +0 -8
- package/definitions/table.js +0 -25
- package/definitions/table.js.map +0 -1
- package/definitions/tableElasticsearch.d.ts +0 -8
- package/definitions/tableElasticsearch.js +0 -25
- package/definitions/tableElasticsearch.js.map +0 -1
- package/dynamoDb/index.d.ts +0 -3
- package/dynamoDb/index.js +0 -16
- package/dynamoDb/index.js.map +0 -1
- package/dynamoDb/storage/longText.d.ts +0 -10
- package/dynamoDb/storage/longText.js +0 -96
- package/dynamoDb/storage/longText.js.map +0 -1
- package/dynamoDb/storage/richText.d.ts +0 -2
- package/dynamoDb/storage/richText.js +0 -59
- package/dynamoDb/storage/richText.js.map +0 -1
- package/elasticsearch/index.d.ts +0 -2
- package/elasticsearch/index.js +0 -13
- package/elasticsearch/index.js.map +0 -1
- package/elasticsearch/indexing/dateTimeIndexing.d.ts +0 -3
- package/elasticsearch/indexing/dateTimeIndexing.js +0 -88
- package/elasticsearch/indexing/dateTimeIndexing.js.map +0 -1
- package/elasticsearch/indexing/defaultFieldIndexing.d.ts +0 -3
- package/elasticsearch/indexing/defaultFieldIndexing.js +0 -54
- package/elasticsearch/indexing/defaultFieldIndexing.js.map +0 -1
- package/elasticsearch/indexing/index.d.ts +0 -2
- package/elasticsearch/indexing/index.js +0 -18
- package/elasticsearch/indexing/index.js.map +0 -1
- package/elasticsearch/indexing/jsonIndexing.d.ts +0 -2
- package/elasticsearch/indexing/jsonIndexing.js +0 -28
- package/elasticsearch/indexing/jsonIndexing.js.map +0 -1
- package/elasticsearch/indexing/longTextIndexing.d.ts +0 -7
- package/elasticsearch/indexing/longTextIndexing.js +0 -42
- package/elasticsearch/indexing/longTextIndexing.js.map +0 -1
- package/elasticsearch/indexing/numberIndexing.d.ts +0 -3
- package/elasticsearch/indexing/numberIndexing.js +0 -41
- package/elasticsearch/indexing/numberIndexing.js.map +0 -1
- package/elasticsearch/indexing/objectIndexing.d.ts +0 -12
- package/elasticsearch/indexing/objectIndexing.js +0 -201
- package/elasticsearch/indexing/objectIndexing.js.map +0 -1
- package/elasticsearch/indexing/richTextIndexing.d.ts +0 -3
- package/elasticsearch/indexing/richTextIndexing.js +0 -31
- package/elasticsearch/indexing/richTextIndexing.js.map +0 -1
- package/elasticsearch/indices/base.d.ts +0 -2
- package/elasticsearch/indices/base.js +0 -13
- package/elasticsearch/indices/base.js.map +0 -1
- package/elasticsearch/indices/index.d.ts +0 -1
- package/elasticsearch/indices/index.js +0 -14
- package/elasticsearch/indices/index.js.map +0 -1
- package/elasticsearch/indices/japanese.d.ts +0 -2
- package/elasticsearch/indices/japanese.js +0 -14
- package/elasticsearch/indices/japanese.js.map +0 -1
- package/elasticsearch/search/index.d.ts +0 -3
- package/elasticsearch/search/index.js +0 -13
- package/elasticsearch/search/index.js.map +0 -1
- package/elasticsearch/search/refSearch.d.ts +0 -2
- package/elasticsearch/search/refSearch.js +0 -31
- package/elasticsearch/search/refSearch.js.map +0 -1
- package/elasticsearch/search/searchableJson.d.ts +0 -2
- package/elasticsearch/search/searchableJson.js +0 -60
- package/elasticsearch/search/searchableJson.js.map +0 -1
- package/elasticsearch/search/timeSearch.d.ts +0 -2
- package/elasticsearch/search/timeSearch.js +0 -27
- package/elasticsearch/search/timeSearch.js.map +0 -1
- package/helpers/index.js.map +0 -1
- package/index.js.map +0 -1
- package/operations/entry/dataLoader/types.js.map +0 -1
- package/operations/entry/elasticsearch/filtering/index.js.map +0 -1
- package/operations/entry/elasticsearch/filtering/plugins/defaultFilterPlugin.d.ts +0 -2
- package/operations/entry/elasticsearch/filtering/plugins/defaultFilterPlugin.js +0 -30
- package/operations/entry/elasticsearch/filtering/plugins/defaultFilterPlugin.js.map +0 -1
- package/operations/entry/elasticsearch/filtering/plugins/index.d.ts +0 -1
- package/operations/entry/elasticsearch/filtering/plugins/index.js +0 -15
- package/operations/entry/elasticsearch/filtering/plugins/index.js.map +0 -1
- package/operations/entry/elasticsearch/filtering/plugins/objectFilterPlugin.d.ts +0 -2
- package/operations/entry/elasticsearch/filtering/plugins/objectFilterPlugin.js +0 -69
- package/operations/entry/elasticsearch/filtering/plugins/objectFilterPlugin.js.map +0 -1
- package/operations/entry/elasticsearch/filtering/plugins/refFilterPlugin.d.ts +0 -2
- package/operations/entry/elasticsearch/filtering/plugins/refFilterPlugin.js +0 -57
- package/operations/entry/elasticsearch/filtering/plugins/refFilterPlugin.js.map +0 -1
- package/operations/entry/elasticsearch/logIgnoredEsResponseError.d.ts +0 -9
- package/operations/entry/elasticsearch/logIgnoredEsResponseError.js +0 -26
- package/operations/entry/elasticsearch/logIgnoredEsResponseError.js.map +0 -1
- package/operations/entry/elasticsearch/plugins/bodyModifier.d.ts +0 -9
- package/operations/entry/elasticsearch/plugins/bodyModifier.js +0 -18
- package/operations/entry/elasticsearch/plugins/bodyModifier.js.map +0 -1
- package/operations/entry/elasticsearch/plugins/queryModifier.d.ts +0 -9
- package/operations/entry/elasticsearch/plugins/queryModifier.js +0 -18
- package/operations/entry/elasticsearch/plugins/queryModifier.js.map +0 -1
- package/operations/entry/elasticsearch/plugins/search.d.ts +0 -7
- package/operations/entry/elasticsearch/plugins/search.js +0 -26
- package/operations/entry/elasticsearch/plugins/search.js.map +0 -1
- package/operations/entry/elasticsearch/plugins/sortModifier.d.ts +0 -9
- package/operations/entry/elasticsearch/plugins/sortModifier.js +0 -18
- package/operations/entry/elasticsearch/plugins/sortModifier.js.map +0 -1
- package/operations/entry/elasticsearch/types.js.map +0 -1
- package/operations/system/index.d.ts +0 -6
- package/operations/system/index.js +0 -94
- package/operations/system/index.js.map +0 -1
- package/operations/system/indexes.d.ts +0 -10
- package/operations/system/indexes.js +0 -41
- package/operations/system/indexes.js.map +0 -1
- package/plugins/CmsElasticsearchModelFieldPlugin.d.ts +0 -69
- package/plugins/CmsElasticsearchModelFieldPlugin.js +0 -52
- package/plugins/CmsElasticsearchModelFieldPlugin.js.map +0 -1
- package/plugins/CmsEntryElasticsearchBodyModifierPlugin.d.ts +0 -22
- package/plugins/CmsEntryElasticsearchBodyModifierPlugin.js +0 -21
- package/plugins/CmsEntryElasticsearchBodyModifierPlugin.js.map +0 -1
- package/plugins/CmsEntryElasticsearchFullTextSearchPlugin.d.ts +0 -23
- package/plugins/CmsEntryElasticsearchFullTextSearchPlugin.js +0 -27
- package/plugins/CmsEntryElasticsearchFullTextSearchPlugin.js.map +0 -1
- package/plugins/CmsEntryElasticsearchIndexPlugin.d.ts +0 -4
- package/plugins/CmsEntryElasticsearchIndexPlugin.js +0 -13
- package/plugins/CmsEntryElasticsearchIndexPlugin.js.map +0 -1
- package/plugins/CmsEntryElasticsearchQueryBuilderValueSearchPlugin.d.ts +0 -32
- package/plugins/CmsEntryElasticsearchQueryBuilderValueSearchPlugin.js +0 -40
- package/plugins/CmsEntryElasticsearchQueryBuilderValueSearchPlugin.js.map +0 -1
- package/plugins/CmsEntryElasticsearchQueryModifierPlugin.d.ts +0 -19
- package/plugins/CmsEntryElasticsearchQueryModifierPlugin.js +0 -21
- package/plugins/CmsEntryElasticsearchQueryModifierPlugin.js.map +0 -1
- package/plugins/CmsEntryElasticsearchSortModifierPlugin.d.ts +0 -19
- package/plugins/CmsEntryElasticsearchSortModifierPlugin.js +0 -21
- package/plugins/CmsEntryElasticsearchSortModifierPlugin.js.map +0 -1
- package/plugins/CmsEntryElasticsearchValuesModifier.d.ts +0 -33
- package/plugins/CmsEntryElasticsearchValuesModifier.js +0 -50
- package/plugins/CmsEntryElasticsearchValuesModifier.js.map +0 -1
- package/plugins/CmsEntryFilterPlugin.d.ts +0 -49
- package/plugins/CmsEntryFilterPlugin.js +0 -22
- package/plugins/CmsEntryFilterPlugin.js.map +0 -1
- package/plugins/index.d.ts +0 -8
- package/plugins/index.js +0 -95
- package/plugins/index.js.map +0 -1
- package/tasks/createIndexTaskPlugin.d.ts +0 -2
- package/tasks/createIndexTaskPlugin.js +0 -67
- package/tasks/createIndexTaskPlugin.js.map +0 -1
package/README.md
CHANGED
|
@@ -1,35 +1,11 @@
|
|
|
1
1
|
# @webiny/api-headless-cms-ddb-es
|
|
2
2
|
|
|
3
|
-
[!
|
|
4
|
-
[
|
|
5
|
-
|
|
6
|
-
[](http://makeapullrequest.com)
|
|
3
|
+
> [!NOTE]
|
|
4
|
+
> This package is part of the [Webiny](https://www.webiny.com) monorepo.
|
|
5
|
+
> It’s **included in every Webiny project by default** and is not meant to be used as a standalone package.
|
|
7
6
|
|
|
8
|
-
|
|
7
|
+
📘 **Documentation:** [https://www.webiny.com/docs](https://www.webiny.com/docs)
|
|
9
8
|
|
|
10
|
-
|
|
11
|
-
npm install --save @webiny/api-headless-cms-ddb-es
|
|
12
|
-
```
|
|
9
|
+
---
|
|
13
10
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
```
|
|
17
|
-
yarn add @webiny/api-headless-cms-ddb-es
|
|
18
|
-
```
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
## Testing
|
|
22
|
-
To run the tests only for this package you must filter it with keywords.
|
|
23
|
-
|
|
24
|
-
### Env variables
|
|
25
|
-
|
|
26
|
-
###### LOCAL_ELASTICSEARCH
|
|
27
|
-
If set, does not run Elasticsearch when starting the tests, use local one. You must install it and run if, of course.
|
|
28
|
-
|
|
29
|
-
###### ELASTICSEARCH_PORT
|
|
30
|
-
Custom port for local elasticsearch.
|
|
31
|
-
|
|
32
|
-
### Command
|
|
33
|
-
````
|
|
34
|
-
ELASTICSEARCH_PORT=9200 LOCAL_ELASTICSEARCH=true yarn test packages/api-headless-cms --keyword=cms:ddb-es --keyword=cms:base
|
|
35
|
-
````
|
|
11
|
+
_This README file is automatically generated during the publish process._
|
package/configurations.d.ts
CHANGED
|
@@ -1,19 +1,22 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
import type {
|
|
3
|
-
import type { ElasticsearchIndexRequestBody } from "@webiny/api-elasticsearch/types";
|
|
4
|
-
interface ConfigurationsElasticsearch {
|
|
5
|
-
index: string;
|
|
6
|
-
}
|
|
1
|
+
import type { StorageCmsModel } from "@webiny/api-headless-cms/types/index.js";
|
|
2
|
+
import type { CmsModelOpenSearchIndexProvider, ICmsModelOpenSearchIndexProviderResult } from "./features/CmsModelOpenSearchIndex/index.js";
|
|
7
3
|
export interface CmsElasticsearchParams {
|
|
8
|
-
model:
|
|
9
|
-
}
|
|
10
|
-
export interface ConfigurationsIndexSettingsParams {
|
|
11
|
-
context: CmsContext;
|
|
12
|
-
model: Pick<CmsModel, "locale">;
|
|
4
|
+
model: StorageCmsModel;
|
|
13
5
|
}
|
|
14
6
|
export interface Configurations {
|
|
15
|
-
es: (params: CmsElasticsearchParams) =>
|
|
16
|
-
indexSettings: (params: ConfigurationsIndexSettingsParams) => Partial<ElasticsearchIndexRequestBody>;
|
|
7
|
+
es: (params: CmsElasticsearchParams) => Promise<ICmsModelOpenSearchIndexProviderResult>;
|
|
17
8
|
}
|
|
18
|
-
export declare const
|
|
19
|
-
|
|
9
|
+
export declare const createConfigurations: (provider: CmsModelOpenSearchIndexProvider.Interface) => Configurations;
|
|
10
|
+
/**
|
|
11
|
+
* Static configurations using the default index name formula.
|
|
12
|
+
* Used by tests and code that does not need DI-based customization.
|
|
13
|
+
*/
|
|
14
|
+
export declare const configurations: {
|
|
15
|
+
es(params: {
|
|
16
|
+
model: StorageCmsModel;
|
|
17
|
+
}): {
|
|
18
|
+
index: string;
|
|
19
|
+
settings: import("@opensearch-project/opensearch/api/index.js").Indices_Create_RequestBody;
|
|
20
|
+
shared: boolean;
|
|
21
|
+
};
|
|
22
|
+
};
|
package/configurations.js
CHANGED
|
@@ -1,49 +1,37 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
const {
|
|
16
|
-
tenant,
|
|
17
|
-
locale
|
|
18
|
-
} = model;
|
|
19
|
-
if (!tenant) {
|
|
20
|
-
throw new _error.default(`Missing "tenant" parameter when trying to create Elasticsearch index name.`, "TENANT_ERROR");
|
|
21
|
-
} else if (!locale) {
|
|
22
|
-
throw new _error.default(`Missing "locale" parameter when trying to create Elasticsearch index name.`, "LOCALE_ERROR");
|
|
23
|
-
}
|
|
24
|
-
const sharedIndex = (0, _apiElasticsearch.isSharedElasticsearchIndex)();
|
|
25
|
-
const index = [sharedIndex ? "root" : tenant, "headless-cms", locale, model.modelId].join("-").toLowerCase();
|
|
26
|
-
const prefix = (0, _apiElasticsearch.getElasticsearchIndexPrefix)();
|
|
27
|
-
if (!prefix) {
|
|
28
|
-
return {
|
|
29
|
-
index
|
|
30
|
-
};
|
|
31
|
-
}
|
|
32
|
-
return {
|
|
33
|
-
index: prefix + index
|
|
34
|
-
};
|
|
35
|
-
},
|
|
36
|
-
indexSettings: ({
|
|
37
|
-
context,
|
|
38
|
-
model
|
|
39
|
-
}) => {
|
|
40
|
-
const plugin = (0, _apiElasticsearch.getLastAddedIndexPlugin)({
|
|
41
|
-
container: context.plugins,
|
|
42
|
-
type: _plugins.CmsEntryElasticsearchIndexPlugin.type,
|
|
43
|
-
locale: model.locale
|
|
1
|
+
import error from "@webiny/error";
|
|
2
|
+
import { getBaseConfiguration, getOpenSearchIndexPrefix, isSharedOpenSearchIndex } from "@webiny/api-opensearch";
|
|
3
|
+
const createConfigurations = (provider)=>({
|
|
4
|
+
async es ({ model }) {
|
|
5
|
+
const result = await provider.execute({
|
|
6
|
+
model
|
|
7
|
+
});
|
|
8
|
+
const prefix = getOpenSearchIndexPrefix();
|
|
9
|
+
if (!prefix) return result;
|
|
10
|
+
return {
|
|
11
|
+
...result,
|
|
12
|
+
index: prefix + result.index
|
|
13
|
+
};
|
|
14
|
+
}
|
|
44
15
|
});
|
|
45
|
-
|
|
46
|
-
|
|
16
|
+
const configurations = {
|
|
17
|
+
es (params) {
|
|
18
|
+
const { model } = params;
|
|
19
|
+
const { tenant } = model;
|
|
20
|
+
if (!tenant) throw new error('Missing "tenant" parameter when trying to create Elasticsearch index name.', "TENANT_ERROR");
|
|
21
|
+
const shared = isSharedOpenSearchIndex();
|
|
22
|
+
const index = [
|
|
23
|
+
shared ? "root" : tenant,
|
|
24
|
+
"headless-cms",
|
|
25
|
+
model.modelId
|
|
26
|
+
].join("-").toLowerCase();
|
|
27
|
+
const prefix = getOpenSearchIndexPrefix();
|
|
28
|
+
return {
|
|
29
|
+
index: prefix ? prefix + index : index,
|
|
30
|
+
settings: getBaseConfiguration(),
|
|
31
|
+
shared
|
|
32
|
+
};
|
|
33
|
+
}
|
|
47
34
|
};
|
|
35
|
+
export { configurations, createConfigurations };
|
|
48
36
|
|
|
49
37
|
//# sourceMappingURL=configurations.js.map
|
package/configurations.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"configurations.js","sources":["../src/configurations.ts"],"sourcesContent":["import WebinyError from \"@webiny/error\";\nimport {\n getBaseConfiguration,\n getOpenSearchIndexPrefix,\n isSharedOpenSearchIndex\n} from \"@webiny/api-opensearch\";\nimport type { StorageCmsModel } from \"@webiny/api-headless-cms/types/index.js\";\nimport type {\n CmsModelOpenSearchIndexProvider,\n ICmsModelOpenSearchIndexProviderResult\n} from \"~/features/CmsModelOpenSearchIndex/index.js\";\n\nexport interface CmsElasticsearchParams {\n model: StorageCmsModel;\n}\n\nexport interface Configurations {\n es: (params: CmsElasticsearchParams) => Promise<ICmsModelOpenSearchIndexProviderResult>;\n}\n\nexport const createConfigurations = (\n provider: CmsModelOpenSearchIndexProvider.Interface\n): Configurations => ({\n async es({ model }) {\n const result = await provider.execute({ model });\n\n const prefix = getOpenSearchIndexPrefix();\n\n if (!prefix) {\n return result;\n }\n return {\n ...result,\n index: prefix + result.index\n };\n }\n});\n\n/**\n * Static configurations using the default index name formula.\n * Used by tests and code that does not need DI-based customization.\n */\nexport const configurations = {\n es(params: { model: StorageCmsModel }) {\n const { model } = params;\n const { tenant } = model;\n\n if (!tenant) {\n throw new WebinyError(\n `Missing \"tenant\" parameter when trying to create Elasticsearch index name.`,\n \"TENANT_ERROR\"\n );\n }\n\n const shared = isSharedOpenSearchIndex();\n const index = [shared ? \"root\" : tenant, \"headless-cms\", model.modelId]\n .join(\"-\")\n .toLowerCase();\n\n const prefix = getOpenSearchIndexPrefix();\n\n return {\n index: prefix ? prefix + index : index,\n settings: getBaseConfiguration(),\n shared\n };\n }\n};\n"],"names":["createConfigurations","provider","model","result","prefix","getOpenSearchIndexPrefix","configurations","params","tenant","WebinyError","shared","isSharedOpenSearchIndex","index","getBaseConfiguration"],"mappings":";;AAoBO,MAAMA,uBAAuB,CAChCC,WACkB;QAClB,MAAM,IAAG,EAAEC,KAAK,EAAE;YACd,MAAMC,SAAS,MAAMF,SAAS,OAAO,CAAC;gBAAEC;YAAM;YAE9C,MAAME,SAASC;YAEf,IAAI,CAACD,QACD,OAAOD;YAEX,OAAO;gBACH,GAAGA,MAAM;gBACT,OAAOC,SAASD,OAAO,KAAK;YAChC;QACJ;IACJ;AAMO,MAAMG,iBAAiB;IAC1B,IAAGC,MAAkC;QACjC,MAAM,EAAEL,KAAK,EAAE,GAAGK;QAClB,MAAM,EAAEC,MAAM,EAAE,GAAGN;QAEnB,IAAI,CAACM,QACD,MAAM,IAAIC,MACN,8EACA;QAIR,MAAMC,SAASC;QACf,MAAMC,QAAQ;YAACF,SAAS,SAASF;YAAQ;YAAgBN,MAAM,OAAO;SAAC,CAClE,IAAI,CAAC,KACL,WAAW;QAEhB,MAAME,SAASC;QAEf,OAAO;YACH,OAAOD,SAASA,SAASQ,QAAQA;YACjC,UAAUC;YACVH;QACJ;IACJ;AACJ"}
|
package/definitions/entry.d.ts
CHANGED
|
@@ -1,9 +1,7 @@
|
|
|
1
|
-
import type
|
|
2
|
-
import {
|
|
3
|
-
import type { Attributes } from "../types";
|
|
1
|
+
import { type ITable } from "@webiny/db-dynamodb";
|
|
2
|
+
import type { IEntryEntity } from "../definitions/types.js";
|
|
4
3
|
export interface CreateEntryEntityParams {
|
|
5
|
-
table:
|
|
4
|
+
table: ITable;
|
|
6
5
|
entityName: string;
|
|
7
|
-
attributes: Attributes;
|
|
8
6
|
}
|
|
9
|
-
export declare const createEntryEntity: (params: CreateEntryEntityParams) =>
|
|
7
|
+
export declare const createEntryEntity: (params: CreateEntryEntityParams) => IEntryEntity;
|
package/definitions/entry.js
CHANGED
|
@@ -1,182 +1,11 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
const createEntryEntity = params => {
|
|
9
|
-
const {
|
|
10
|
-
table,
|
|
11
|
-
entityName,
|
|
12
|
-
attributes
|
|
13
|
-
} = params;
|
|
14
|
-
return new _toolbox.Entity({
|
|
15
|
-
name: entityName,
|
|
16
|
-
table,
|
|
17
|
-
attributes: {
|
|
18
|
-
PK: {
|
|
19
|
-
type: "string",
|
|
20
|
-
partitionKey: true
|
|
21
|
-
},
|
|
22
|
-
SK: {
|
|
23
|
-
type: "string",
|
|
24
|
-
sortKey: true
|
|
25
|
-
},
|
|
26
|
-
TYPE: {
|
|
27
|
-
type: "string"
|
|
28
|
-
},
|
|
29
|
-
__type: {
|
|
30
|
-
type: "string"
|
|
31
|
-
},
|
|
32
|
-
webinyVersion: {
|
|
33
|
-
type: "string"
|
|
34
|
-
},
|
|
35
|
-
tenant: {
|
|
36
|
-
type: "string"
|
|
37
|
-
},
|
|
38
|
-
entryId: {
|
|
39
|
-
type: "string"
|
|
40
|
-
},
|
|
41
|
-
id: {
|
|
42
|
-
type: "string"
|
|
43
|
-
},
|
|
44
|
-
/**
|
|
45
|
-
* Revision-level meta fields. 👇
|
|
46
|
-
*/
|
|
47
|
-
revisionCreatedOn: {
|
|
48
|
-
type: "string"
|
|
49
|
-
},
|
|
50
|
-
revisionSavedOn: {
|
|
51
|
-
type: "string"
|
|
52
|
-
},
|
|
53
|
-
revisionModifiedOn: {
|
|
54
|
-
type: "string"
|
|
55
|
-
},
|
|
56
|
-
revisionDeletedOn: {
|
|
57
|
-
type: "string"
|
|
58
|
-
},
|
|
59
|
-
revisionRestoredOn: {
|
|
60
|
-
type: "string"
|
|
61
|
-
},
|
|
62
|
-
revisionFirstPublishedOn: {
|
|
63
|
-
type: "string"
|
|
64
|
-
},
|
|
65
|
-
revisionLastPublishedOn: {
|
|
66
|
-
type: "string"
|
|
67
|
-
},
|
|
68
|
-
revisionCreatedBy: {
|
|
69
|
-
type: "map"
|
|
70
|
-
},
|
|
71
|
-
revisionSavedBy: {
|
|
72
|
-
type: "map"
|
|
73
|
-
},
|
|
74
|
-
revisionModifiedBy: {
|
|
75
|
-
type: "map"
|
|
76
|
-
},
|
|
77
|
-
revisionDeletedBy: {
|
|
78
|
-
type: "map"
|
|
79
|
-
},
|
|
80
|
-
revisionRestoredBy: {
|
|
81
|
-
type: "map"
|
|
82
|
-
},
|
|
83
|
-
revisionFirstPublishedBy: {
|
|
84
|
-
type: "map"
|
|
85
|
-
},
|
|
86
|
-
revisionLastPublishedBy: {
|
|
87
|
-
type: "map"
|
|
88
|
-
},
|
|
89
|
-
/**
|
|
90
|
-
* Entry-level meta fields. 👇
|
|
91
|
-
*/
|
|
92
|
-
createdOn: {
|
|
93
|
-
type: "string"
|
|
94
|
-
},
|
|
95
|
-
savedOn: {
|
|
96
|
-
type: "string"
|
|
97
|
-
},
|
|
98
|
-
modifiedOn: {
|
|
99
|
-
type: "string"
|
|
100
|
-
},
|
|
101
|
-
deletedOn: {
|
|
102
|
-
type: "string"
|
|
103
|
-
},
|
|
104
|
-
restoredOn: {
|
|
105
|
-
type: "string"
|
|
106
|
-
},
|
|
107
|
-
firstPublishedOn: {
|
|
108
|
-
type: "string"
|
|
109
|
-
},
|
|
110
|
-
lastPublishedOn: {
|
|
111
|
-
type: "string"
|
|
112
|
-
},
|
|
113
|
-
createdBy: {
|
|
114
|
-
type: "map"
|
|
115
|
-
},
|
|
116
|
-
savedBy: {
|
|
117
|
-
type: "map"
|
|
118
|
-
},
|
|
119
|
-
modifiedBy: {
|
|
120
|
-
type: "map"
|
|
121
|
-
},
|
|
122
|
-
deletedBy: {
|
|
123
|
-
type: "map"
|
|
124
|
-
},
|
|
125
|
-
restoredBy: {
|
|
126
|
-
type: "map"
|
|
127
|
-
},
|
|
128
|
-
firstPublishedBy: {
|
|
129
|
-
type: "map"
|
|
130
|
-
},
|
|
131
|
-
lastPublishedBy: {
|
|
132
|
-
type: "map"
|
|
133
|
-
},
|
|
134
|
-
/**
|
|
135
|
-
* Deprecated fields. 👇
|
|
136
|
-
*/
|
|
137
|
-
ownedBy: {
|
|
138
|
-
type: "map"
|
|
139
|
-
},
|
|
140
|
-
publishedOn: {
|
|
141
|
-
type: "string"
|
|
142
|
-
},
|
|
143
|
-
/**
|
|
144
|
-
* The rest. 👇
|
|
145
|
-
*/
|
|
146
|
-
modelId: {
|
|
147
|
-
type: "string"
|
|
148
|
-
},
|
|
149
|
-
locale: {
|
|
150
|
-
type: "string"
|
|
151
|
-
},
|
|
152
|
-
version: {
|
|
153
|
-
type: "number"
|
|
154
|
-
},
|
|
155
|
-
locked: {
|
|
156
|
-
type: "boolean"
|
|
157
|
-
},
|
|
158
|
-
status: {
|
|
159
|
-
type: "string"
|
|
160
|
-
},
|
|
161
|
-
location: {
|
|
162
|
-
type: "map"
|
|
163
|
-
},
|
|
164
|
-
wbyDeleted: {
|
|
165
|
-
type: "boolean"
|
|
166
|
-
},
|
|
167
|
-
binOriginalFolderId: {
|
|
168
|
-
type: "string"
|
|
169
|
-
},
|
|
170
|
-
values: {
|
|
171
|
-
type: "map"
|
|
172
|
-
},
|
|
173
|
-
meta: {
|
|
174
|
-
type: "map"
|
|
175
|
-
},
|
|
176
|
-
...(attributes || {})
|
|
177
|
-
}
|
|
178
|
-
});
|
|
1
|
+
import { createStandardEntity } from "@webiny/db-dynamodb";
|
|
2
|
+
const createEntryEntity = (params)=>{
|
|
3
|
+
const { table, entityName } = params;
|
|
4
|
+
return createStandardEntity({
|
|
5
|
+
name: entityName,
|
|
6
|
+
table: table.table
|
|
7
|
+
});
|
|
179
8
|
};
|
|
180
|
-
|
|
9
|
+
export { createEntryEntity };
|
|
181
10
|
|
|
182
11
|
//# sourceMappingURL=entry.js.map
|
package/definitions/entry.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"definitions/entry.js","sources":["../../src/definitions/entry.ts"],"sourcesContent":["import { createStandardEntity, type ITable } from \"@webiny/db-dynamodb\";\nimport type { IEntryEntity, IEntryEntityAttributesData } from \"~/definitions/types.js\";\n\nexport interface CreateEntryEntityParams {\n table: ITable;\n entityName: string;\n}\nexport const createEntryEntity = (params: CreateEntryEntityParams): IEntryEntity => {\n const { table, entityName } = params;\n return createStandardEntity<IEntryEntityAttributesData>({\n name: entityName,\n table: table.table\n });\n};\n"],"names":["createEntryEntity","params","table","entityName","createStandardEntity"],"mappings":";AAOO,MAAMA,oBAAoB,CAACC;IAC9B,MAAM,EAAEC,KAAK,EAAEC,UAAU,EAAE,GAAGF;IAC9B,OAAOG,qBAAiD;QACpD,MAAMD;QACN,OAAOD,MAAM,KAAK;IACtB;AACJ"}
|
package/definitions/group.d.ts
CHANGED
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
import type
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
table: Table<string, string, string>;
|
|
1
|
+
import { type ITable } from "@webiny/db-dynamodb";
|
|
2
|
+
import type { IGroupEntity } from "../definitions/types.js";
|
|
3
|
+
interface Params {
|
|
4
|
+
table: ITable;
|
|
6
5
|
entityName: string;
|
|
7
|
-
attributes: Attributes;
|
|
8
6
|
}
|
|
9
|
-
export declare const createGroupEntity: (params:
|
|
7
|
+
export declare const createGroupEntity: (params: Params) => IGroupEntity;
|
|
8
|
+
export {};
|
package/definitions/group.js
CHANGED
|
@@ -1,66 +1,11 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
const createGroupEntity = params => {
|
|
9
|
-
const {
|
|
10
|
-
table,
|
|
11
|
-
attributes,
|
|
12
|
-
entityName
|
|
13
|
-
} = params;
|
|
14
|
-
return new _toolbox.Entity({
|
|
15
|
-
name: entityName,
|
|
16
|
-
table,
|
|
17
|
-
attributes: {
|
|
18
|
-
PK: {
|
|
19
|
-
partitionKey: true
|
|
20
|
-
},
|
|
21
|
-
SK: {
|
|
22
|
-
sortKey: true
|
|
23
|
-
},
|
|
24
|
-
TYPE: {
|
|
25
|
-
type: "string"
|
|
26
|
-
},
|
|
27
|
-
webinyVersion: {
|
|
28
|
-
type: "string"
|
|
29
|
-
},
|
|
30
|
-
id: {
|
|
31
|
-
type: "string"
|
|
32
|
-
},
|
|
33
|
-
name: {
|
|
34
|
-
type: "string"
|
|
35
|
-
},
|
|
36
|
-
slug: {
|
|
37
|
-
type: "string"
|
|
38
|
-
},
|
|
39
|
-
locale: {
|
|
40
|
-
type: "string"
|
|
41
|
-
},
|
|
42
|
-
description: {
|
|
43
|
-
type: "string"
|
|
44
|
-
},
|
|
45
|
-
icon: {
|
|
46
|
-
type: "string"
|
|
47
|
-
},
|
|
48
|
-
createdBy: {
|
|
49
|
-
type: "map"
|
|
50
|
-
},
|
|
51
|
-
createdOn: {
|
|
52
|
-
type: "string"
|
|
53
|
-
},
|
|
54
|
-
savedOn: {
|
|
55
|
-
type: "string"
|
|
56
|
-
},
|
|
57
|
-
tenant: {
|
|
58
|
-
type: "string"
|
|
59
|
-
},
|
|
60
|
-
...(attributes || {})
|
|
61
|
-
}
|
|
62
|
-
});
|
|
1
|
+
import { createStandardEntity } from "@webiny/db-dynamodb";
|
|
2
|
+
const createGroupEntity = (params)=>{
|
|
3
|
+
const { table, entityName } = params;
|
|
4
|
+
return createStandardEntity({
|
|
5
|
+
table: table.table,
|
|
6
|
+
name: entityName
|
|
7
|
+
});
|
|
63
8
|
};
|
|
64
|
-
|
|
9
|
+
export { createGroupEntity };
|
|
65
10
|
|
|
66
11
|
//# sourceMappingURL=group.js.map
|
package/definitions/group.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"definitions/group.js","sources":["../../src/definitions/group.ts"],"sourcesContent":["import { createStandardEntity, type ITable } from \"@webiny/db-dynamodb\";\nimport type { IGroupEntity } from \"~/definitions/types.js\";\nimport type { CmsGroup } from \"@webiny/api-headless-cms/types/index.js\";\n\ninterface Params {\n table: ITable;\n entityName: string;\n}\nexport const createGroupEntity = (params: Params): IGroupEntity => {\n const { table, entityName } = params;\n return createStandardEntity<CmsGroup>({\n table: table.table,\n name: entityName\n });\n};\n"],"names":["createGroupEntity","params","table","entityName","createStandardEntity"],"mappings":";AAQO,MAAMA,oBAAoB,CAACC;IAC9B,MAAM,EAAEC,KAAK,EAAEC,UAAU,EAAE,GAAGF;IAC9B,OAAOG,qBAA+B;QAClC,OAAOF,MAAM,KAAK;QAClB,MAAMC;IACV;AACJ"}
|
package/definitions/model.d.ts
CHANGED
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
import type
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
table: Table<string, string, string>;
|
|
1
|
+
import { type ITable } from "@webiny/db-dynamodb";
|
|
2
|
+
import type { IModelEntity } from "../definitions/types.js";
|
|
3
|
+
interface Params {
|
|
4
|
+
table: ITable;
|
|
6
5
|
entityName: string;
|
|
7
|
-
attributes: Attributes;
|
|
8
6
|
}
|
|
9
|
-
export declare const createModelEntity: (params:
|
|
7
|
+
export declare const createModelEntity: (params: Params) => IModelEntity;
|
|
8
|
+
export {};
|
package/definitions/model.js
CHANGED
|
@@ -1,110 +1,11 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
const createModelEntity = params => {
|
|
9
|
-
const {
|
|
10
|
-
table,
|
|
11
|
-
attributes,
|
|
12
|
-
entityName
|
|
13
|
-
} = params;
|
|
14
|
-
return new _toolbox.Entity({
|
|
15
|
-
name: entityName,
|
|
16
|
-
table,
|
|
17
|
-
attributes: {
|
|
18
|
-
PK: {
|
|
19
|
-
partitionKey: true
|
|
20
|
-
},
|
|
21
|
-
SK: {
|
|
22
|
-
sortKey: true
|
|
23
|
-
},
|
|
24
|
-
TYPE: {
|
|
25
|
-
type: "string",
|
|
26
|
-
required: true
|
|
27
|
-
},
|
|
28
|
-
webinyVersion: {
|
|
29
|
-
type: "string",
|
|
30
|
-
required: true
|
|
31
|
-
},
|
|
32
|
-
name: {
|
|
33
|
-
type: "string",
|
|
34
|
-
required: true
|
|
35
|
-
},
|
|
36
|
-
modelId: {
|
|
37
|
-
type: "string",
|
|
38
|
-
required: true
|
|
39
|
-
},
|
|
40
|
-
singularApiName: {
|
|
41
|
-
type: "string",
|
|
42
|
-
required: true
|
|
43
|
-
},
|
|
44
|
-
pluralApiName: {
|
|
45
|
-
type: "string",
|
|
46
|
-
required: true
|
|
47
|
-
},
|
|
48
|
-
locale: {
|
|
49
|
-
type: "string",
|
|
50
|
-
required: true
|
|
51
|
-
},
|
|
52
|
-
group: {
|
|
53
|
-
type: "map",
|
|
54
|
-
required: true
|
|
55
|
-
},
|
|
56
|
-
icon: {
|
|
57
|
-
type: "string"
|
|
58
|
-
},
|
|
59
|
-
description: {
|
|
60
|
-
type: "string"
|
|
61
|
-
},
|
|
62
|
-
createdOn: {
|
|
63
|
-
type: "string",
|
|
64
|
-
required: true
|
|
65
|
-
},
|
|
66
|
-
savedOn: {
|
|
67
|
-
type: "string",
|
|
68
|
-
required: true
|
|
69
|
-
},
|
|
70
|
-
createdBy: {
|
|
71
|
-
type: "map",
|
|
72
|
-
required: true
|
|
73
|
-
},
|
|
74
|
-
fields: {
|
|
75
|
-
type: "list",
|
|
76
|
-
required: true
|
|
77
|
-
},
|
|
78
|
-
layout: {
|
|
79
|
-
type: "list",
|
|
80
|
-
required: true
|
|
81
|
-
},
|
|
82
|
-
tags: {
|
|
83
|
-
type: "list",
|
|
84
|
-
required: false,
|
|
85
|
-
default: []
|
|
86
|
-
},
|
|
87
|
-
lockedFields: {
|
|
88
|
-
type: "list",
|
|
89
|
-
required: true
|
|
90
|
-
},
|
|
91
|
-
titleFieldId: {
|
|
92
|
-
type: "string"
|
|
93
|
-
},
|
|
94
|
-
descriptionFieldId: {
|
|
95
|
-
type: "string"
|
|
96
|
-
},
|
|
97
|
-
imageFieldId: {
|
|
98
|
-
type: "string"
|
|
99
|
-
},
|
|
100
|
-
tenant: {
|
|
101
|
-
type: "string",
|
|
102
|
-
required: true
|
|
103
|
-
},
|
|
104
|
-
...(attributes || {})
|
|
105
|
-
}
|
|
106
|
-
});
|
|
1
|
+
import { createStandardEntity } from "@webiny/db-dynamodb";
|
|
2
|
+
const createModelEntity = (params)=>{
|
|
3
|
+
const { table, entityName } = params;
|
|
4
|
+
return createStandardEntity({
|
|
5
|
+
table: table.table,
|
|
6
|
+
name: entityName
|
|
7
|
+
});
|
|
107
8
|
};
|
|
108
|
-
|
|
9
|
+
export { createModelEntity };
|
|
109
10
|
|
|
110
11
|
//# sourceMappingURL=model.js.map
|