oneentry 1.0.10 → 1.0.13
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 +91 -215
- package/dist/_cjs/admins/adminsApi.d.ts +14 -0
- package/dist/_cjs/admins/adminsApi.js +34 -0
- package/dist/_cjs/admins/adminsApi.js.map +1 -0
- package/dist/_cjs/admins/adminsInterfaces.d.ts +32 -0
- package/dist/_cjs/admins/adminsInterfaces.js +3 -0
- package/dist/_cjs/admins/adminsInterfaces.js.map +1 -0
- package/dist/_cjs/attribute-set/attributeSetApi.d.ts +24 -0
- package/dist/_cjs/attribute-set/attributeSetApi.js +49 -0
- package/dist/_cjs/attribute-set/attributeSetApi.js.map +1 -0
- package/dist/_cjs/attribute-set/attributeSetInterfaces.d.ts +23 -0
- package/dist/_cjs/attribute-set/attributeSetInterfaces.js +3 -0
- package/dist/_cjs/attribute-set/attributeSetInterfaces.js.map +1 -0
- package/dist/_cjs/base/oneEntry.d.ts +9 -0
- package/dist/_cjs/base/oneEntry.js +55 -0
- package/dist/_cjs/base/oneEntry.js.map +1 -0
- package/dist/_cjs/base/utils.d.ts +32 -0
- package/dist/_cjs/base/utils.js +32 -0
- package/dist/_cjs/base/utils.js.map +1 -0
- package/dist/_cjs/forms/formsApi.d.ts +26 -0
- package/dist/_cjs/forms/formsApi.js +56 -0
- package/dist/_cjs/forms/formsApi.js.map +1 -0
- package/dist/_cjs/forms/formsInterfaces.d.ts +28 -0
- package/dist/_cjs/forms/formsInterfaces.js +3 -0
- package/dist/_cjs/forms/formsInterfaces.js.map +1 -0
- package/dist/_cjs/formsData/formsDataApi.d.ts +41 -0
- package/dist/_cjs/formsData/formsDataApi.js +71 -0
- package/dist/_cjs/formsData/formsDataApi.js.map +1 -0
- package/dist/_cjs/formsData/formsDataInterfaces.d.ts +25 -0
- package/dist/_cjs/formsData/formsDataInterfaces.js +3 -0
- package/dist/_cjs/formsData/formsDataInterfaces.js.map +1 -0
- package/dist/_cjs/general-types/generalTypesApi.d.ts +14 -0
- package/dist/_cjs/general-types/generalTypesApi.js +34 -0
- package/dist/_cjs/general-types/generalTypesApi.js.map +1 -0
- package/dist/_cjs/general-types/generalTypesInterfaces.d.ts +9 -0
- package/dist/_cjs/general-types/generalTypesInterfaces.js +3 -0
- package/dist/_cjs/general-types/generalTypesInterfaces.js.map +1 -0
- package/dist/_cjs/index.d.ts +35 -0
- package/dist/_cjs/index.js +55 -0
- package/dist/_cjs/index.js.map +1 -0
- package/dist/_cjs/locales/localesApi.d.ts +14 -0
- package/dist/_cjs/locales/localesApi.js +34 -0
- package/dist/_cjs/locales/localesApi.js.map +1 -0
- package/dist/_cjs/locales/localesInterfaces.d.ts +15 -0
- package/dist/_cjs/locales/localesInterfaces.js +3 -0
- package/dist/_cjs/locales/localesInterfaces.js.map +1 -0
- package/dist/_cjs/markers/markersApi.d.ts +35 -0
- package/dist/_cjs/markers/markersApi.js +65 -0
- package/dist/_cjs/markers/markersApi.js.map +1 -0
- package/dist/_cjs/markers/markersInterfaces.d.ts +16 -0
- package/dist/_cjs/markers/markersInterfaces.js +3 -0
- package/dist/_cjs/markers/markersInterfaces.js.map +1 -0
- package/dist/_cjs/menus/menusApi.d.ts +16 -0
- package/dist/_cjs/menus/menusApi.js +36 -0
- package/dist/_cjs/menus/menusApi.js.map +1 -0
- package/dist/_cjs/menus/menusInterfaces.d.ts +18 -0
- package/dist/_cjs/menus/menusInterfaces.js +3 -0
- package/dist/_cjs/menus/menusInterfaces.js.map +1 -0
- package/dist/_cjs/modules/modulesApi.d.ts +14 -0
- package/dist/_cjs/modules/modulesApi.js +34 -0
- package/dist/_cjs/modules/modulesApi.js.map +1 -0
- package/dist/_cjs/modules/modulesInterfaces.d.ts +19 -0
- package/dist/_cjs/modules/modulesInterfaces.js +3 -0
- package/dist/_cjs/modules/modulesInterfaces.js.map +1 -0
- package/dist/_cjs/pages/pagesApi.d.ts +74 -0
- package/dist/_cjs/pages/pagesApi.js +137 -0
- package/dist/_cjs/pages/pagesApi.js.map +1 -0
- package/dist/_cjs/pages/pagesInterfaces.d.ts +39 -0
- package/dist/_cjs/pages/pagesInterfaces.js +3 -0
- package/dist/_cjs/pages/pagesInterfaces.js.map +1 -0
- package/dist/_cjs/product-statuses/productStatusesApi.d.ts +38 -0
- package/dist/_cjs/product-statuses/productStatusesApi.js +73 -0
- package/dist/_cjs/product-statuses/productStatusesApi.js.map +1 -0
- package/dist/_cjs/product-statuses/productStatusesInterfaces.d.ts +15 -0
- package/dist/_cjs/product-statuses/productStatusesInterfaces.js +3 -0
- package/dist/_cjs/product-statuses/productStatusesInterfaces.js.map +1 -0
- package/dist/_cjs/products/productsApi.d.ts +195 -0
- package/dist/_cjs/products/productsApi.js +295 -0
- package/dist/_cjs/products/productsApi.js.map +1 -0
- package/dist/_cjs/products/productsInterfaces.d.ts +83 -0
- package/dist/_cjs/products/productsInterfaces.js +3 -0
- package/dist/_cjs/products/productsInterfaces.js.map +1 -0
- package/dist/_cjs/templates/templatesApi.d.ts +32 -0
- package/dist/_cjs/templates/templatesApi.js +72 -0
- package/dist/_cjs/templates/templatesApi.js.map +1 -0
- package/dist/_cjs/templates/templatesInterfaces.d.ts +30 -0
- package/dist/_cjs/templates/templatesInterfaces.js +3 -0
- package/dist/_cjs/templates/templatesInterfaces.js.map +1 -0
- package/dist/_cjs/templates-preview/templatesPreviewApi.d.ts +30 -0
- package/dist/_cjs/templates-preview/templatesPreviewApi.js +60 -0
- package/dist/_cjs/templates-preview/templatesPreviewApi.js.map +1 -0
- package/dist/_cjs/templates-preview/templatesPreviewInterfaces.d.ts +27 -0
- package/dist/_cjs/templates-preview/templatesPreviewInterfaces.js +3 -0
- package/dist/_cjs/templates-preview/templatesPreviewInterfaces.js.map +1 -0
- package/dist/_esm/admins/adminsApi.d.ts +14 -0
- package/dist/_esm/admins/adminsApi.js +31 -0
- package/dist/_esm/admins/adminsApi.js.map +1 -0
- package/dist/_esm/admins/adminsInterfaces.d.ts +32 -0
- package/dist/_esm/admins/adminsInterfaces.js +2 -0
- package/dist/_esm/admins/adminsInterfaces.js.map +1 -0
- package/dist/_esm/attribute-set/attributeSetApi.d.ts +24 -0
- package/dist/_esm/attribute-set/attributeSetApi.js +46 -0
- package/dist/_esm/attribute-set/attributeSetApi.js.map +1 -0
- package/dist/_esm/attribute-set/attributeSetInterfaces.d.ts +23 -0
- package/dist/_esm/attribute-set/attributeSetInterfaces.js +2 -0
- package/dist/_esm/attribute-set/attributeSetInterfaces.js.map +1 -0
- package/dist/_esm/base/oneEntry.d.ts +9 -0
- package/dist/_esm/base/oneEntry.js +52 -0
- package/dist/_esm/base/oneEntry.js.map +1 -0
- package/dist/_esm/base/utils.d.ts +32 -0
- package/dist/_esm/base/utils.js +30 -0
- package/dist/_esm/base/utils.js.map +1 -0
- package/dist/_esm/forms/formsApi.d.ts +26 -0
- package/dist/_esm/forms/formsApi.js +53 -0
- package/dist/_esm/forms/formsApi.js.map +1 -0
- package/dist/_esm/forms/formsInterfaces.d.ts +28 -0
- package/dist/_esm/forms/formsInterfaces.js +2 -0
- package/dist/_esm/forms/formsInterfaces.js.map +1 -0
- package/dist/_esm/formsData/formsDataApi.d.ts +41 -0
- package/dist/_esm/formsData/formsDataApi.js +68 -0
- package/dist/_esm/formsData/formsDataApi.js.map +1 -0
- package/dist/_esm/formsData/formsDataInterfaces.d.ts +25 -0
- package/dist/_esm/formsData/formsDataInterfaces.js +2 -0
- package/dist/_esm/formsData/formsDataInterfaces.js.map +1 -0
- package/dist/_esm/general-types/generalTypesApi.d.ts +14 -0
- package/dist/_esm/general-types/generalTypesApi.js +31 -0
- package/dist/_esm/general-types/generalTypesApi.js.map +1 -0
- package/dist/_esm/general-types/generalTypesInterfaces.d.ts +9 -0
- package/dist/_esm/general-types/generalTypesInterfaces.js +2 -0
- package/dist/_esm/general-types/generalTypesInterfaces.js.map +1 -0
- package/dist/_esm/index.d.ts +35 -0
- package/dist/_esm/index.js +51 -0
- package/dist/_esm/index.js.map +1 -0
- package/dist/_esm/locales/localesApi.d.ts +14 -0
- package/dist/_esm/locales/localesApi.js +31 -0
- package/dist/_esm/locales/localesApi.js.map +1 -0
- package/dist/_esm/locales/localesInterfaces.d.ts +15 -0
- package/dist/_esm/locales/localesInterfaces.js +2 -0
- package/dist/_esm/locales/localesInterfaces.js.map +1 -0
- package/dist/_esm/markers/markersApi.d.ts +35 -0
- package/dist/_esm/markers/markersApi.js +62 -0
- package/dist/_esm/markers/markersApi.js.map +1 -0
- package/dist/_esm/markers/markersInterfaces.d.ts +16 -0
- package/dist/_esm/markers/markersInterfaces.js +2 -0
- package/dist/_esm/markers/markersInterfaces.js.map +1 -0
- package/dist/_esm/menus/menusApi.d.ts +16 -0
- package/dist/_esm/menus/menusApi.js +33 -0
- package/dist/_esm/menus/menusApi.js.map +1 -0
- package/dist/_esm/menus/menusInterfaces.d.ts +18 -0
- package/dist/_esm/menus/menusInterfaces.js +2 -0
- package/dist/_esm/menus/menusInterfaces.js.map +1 -0
- package/dist/_esm/modules/modulesApi.d.ts +14 -0
- package/dist/_esm/modules/modulesApi.js +31 -0
- package/dist/_esm/modules/modulesApi.js.map +1 -0
- package/dist/_esm/modules/modulesInterfaces.d.ts +19 -0
- package/dist/_esm/modules/modulesInterfaces.js +2 -0
- package/dist/_esm/modules/modulesInterfaces.js.map +1 -0
- package/dist/_esm/pages/pagesApi.d.ts +74 -0
- package/dist/_esm/pages/pagesApi.js +134 -0
- package/dist/_esm/pages/pagesApi.js.map +1 -0
- package/dist/_esm/pages/pagesInterfaces.d.ts +39 -0
- package/dist/_esm/pages/pagesInterfaces.js +2 -0
- package/dist/_esm/pages/pagesInterfaces.js.map +1 -0
- package/dist/_esm/product-statuses/productStatusesApi.d.ts +38 -0
- package/dist/_esm/product-statuses/productStatusesApi.js +70 -0
- package/dist/_esm/product-statuses/productStatusesApi.js.map +1 -0
- package/dist/_esm/product-statuses/productStatusesInterfaces.d.ts +15 -0
- package/dist/_esm/product-statuses/productStatusesInterfaces.js +2 -0
- package/dist/_esm/product-statuses/productStatusesInterfaces.js.map +1 -0
- package/dist/_esm/products/productsApi.d.ts +195 -0
- package/dist/_esm/products/productsApi.js +292 -0
- package/dist/_esm/products/productsApi.js.map +1 -0
- package/dist/_esm/products/productsInterfaces.d.ts +83 -0
- package/dist/_esm/products/productsInterfaces.js +2 -0
- package/dist/_esm/products/productsInterfaces.js.map +1 -0
- package/dist/_esm/templates/templatesApi.d.ts +32 -0
- package/dist/_esm/templates/templatesApi.js +69 -0
- package/dist/_esm/templates/templatesApi.js.map +1 -0
- package/dist/_esm/templates/templatesInterfaces.d.ts +30 -0
- package/dist/_esm/templates/templatesInterfaces.js +2 -0
- package/dist/_esm/templates/templatesInterfaces.js.map +1 -0
- package/dist/_esm/templates-preview/templatesPreviewApi.d.ts +30 -0
- package/dist/_esm/templates-preview/templatesPreviewApi.js +57 -0
- package/dist/_esm/templates-preview/templatesPreviewApi.js.map +1 -0
- package/dist/_esm/templates-preview/templatesPreviewInterfaces.d.ts +27 -0
- package/dist/_esm/templates-preview/templatesPreviewInterfaces.js +2 -0
- package/dist/_esm/templates-preview/templatesPreviewInterfaces.js.map +1 -0
- package/dist/_types/admins/adminsApi.d.ts +14 -0
- package/dist/_types/admins/adminsInterfaces.d.ts +32 -0
- package/dist/_types/attribute-set/attributeSetApi.d.ts +24 -0
- package/dist/_types/attribute-set/attributeSetInterfaces.d.ts +23 -0
- package/dist/_types/base/oneEntry.d.ts +9 -0
- package/dist/_types/base/utils.d.ts +32 -0
- package/dist/_types/forms/formsApi.d.ts +26 -0
- package/dist/_types/forms/formsInterfaces.d.ts +28 -0
- package/dist/_types/formsData/formsDataApi.d.ts +41 -0
- package/dist/_types/formsData/formsDataInterfaces.d.ts +25 -0
- package/dist/_types/general-types/generalTypesApi.d.ts +14 -0
- package/dist/_types/general-types/generalTypesInterfaces.d.ts +9 -0
- package/dist/_types/index.d.ts +35 -0
- package/dist/_types/locales/localesApi.d.ts +14 -0
- package/dist/_types/locales/localesInterfaces.d.ts +15 -0
- package/dist/_types/markers/markersApi.d.ts +35 -0
- package/dist/_types/markers/markersInterfaces.d.ts +16 -0
- package/dist/_types/menus/menusApi.d.ts +16 -0
- package/dist/_types/menus/menusInterfaces.d.ts +18 -0
- package/dist/_types/modules/modulesApi.d.ts +14 -0
- package/dist/_types/modules/modulesInterfaces.d.ts +19 -0
- package/dist/_types/pages/pagesApi.d.ts +74 -0
- package/dist/_types/pages/pagesInterfaces.d.ts +39 -0
- package/dist/_types/product-statuses/productStatusesApi.d.ts +38 -0
- package/dist/_types/product-statuses/productStatusesInterfaces.d.ts +15 -0
- package/dist/_types/products/productsApi.d.ts +195 -0
- package/dist/_types/products/productsInterfaces.d.ts +83 -0
- package/dist/_types/templates/templatesApi.d.ts +32 -0
- package/dist/_types/templates/templatesInterfaces.d.ts +30 -0
- package/dist/_types/templates-preview/templatesPreviewApi.d.ts +30 -0
- package/dist/_types/templates-preview/templatesPreviewInterfaces.d.ts +27 -0
- package/dist/index.d.ts +0 -4
- package/dist/index.js +0 -8
- package/dist/index.js.map +1 -1
- package/dist/products/productsApi.d.ts +6 -4
- package/dist/products/productsApi.js +34 -7
- package/dist/products/productsApi.js.map +1 -1
- package/dist/products/productsInterfaces.d.ts +14 -3
- package/package.json +3 -2
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"productsApi.js","sourceRoot":"","sources":["../../../src/products/productsApi.ts"],"names":[],"mappings":";;;;;;;;;;;AACA,+CAAuC;AAEvC;;GAEG;AACH,MAAqB,UAAW,SAAQ,kBAAQ;IAC5C,YAAY,GAAU;QAClB,KAAK,CAAC,GAAG,CAAC,CAAA;QAIN,kBAAa,GAAkB;YACnC,MAAM,EAAE,CAAC;YACT,KAAK,EAAE,EAAE;YACT,YAAY,EAAE,IAAI;YAClB,cAAc,EAAE,IAAI;YACpB,eAAe,EAAE,IAAI;YACrB,eAAe,EAAE,IAAI;YACrB,QAAQ,EAAE,OAAO;YACjB,SAAS,EAAE,MAAM;YACjB,O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AAC,eAAe,EAAE,GAAG,KAAK,CAAC,CAAA;aAC5D;YACD,OAAO,gBAAgB,CAAA;QAC3B,CAAC;KAAA;CAEJ;AAxRD,6BAwRC"}
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import { ILocalizeInfos } from "../base/utils";
|
|
2
|
+
interface IProductApi {
|
|
3
|
+
getProducts(userQuery?: IProductsQuery): Promise<Array<IProductsEntity>>;
|
|
4
|
+
getProductsEmptyPage(userQuery?: IProductsQuery): Promise<Array<IProductsEntity>>;
|
|
5
|
+
getProductsPageById(id: number, userQuery?: IProductsQuery): Promise<Array<IProductsEntity>>;
|
|
6
|
+
getProductsPageByUrl(url: string, userQuery?: IProductsQuery): Promise<Array<IProductsEntity>>;
|
|
7
|
+
getRelatedProductsById(id: number, userQuery?: IProductsQuery): Promise<IProductsEntity>;
|
|
8
|
+
getProductById(id: number, langCode: string): Promise<IProductsEntity>;
|
|
9
|
+
filterProduct(data: Array<IFilterParams>, userQuery?: IProductsQuery): Promise<Array<IProductsEntity>>;
|
|
10
|
+
searchProduct(name: string, langCode: string): Promise<Array<IProductsEntity>>;
|
|
11
|
+
getAttributesByProductId(id: number): Promise<any>;
|
|
12
|
+
}
|
|
13
|
+
interface IProduct {
|
|
14
|
+
attributeSetId: number | null;
|
|
15
|
+
attributeValues: object | null;
|
|
16
|
+
id: number;
|
|
17
|
+
isSync: number;
|
|
18
|
+
isVisible: boolean;
|
|
19
|
+
localizeInfos: object;
|
|
20
|
+
position: number;
|
|
21
|
+
price?: number;
|
|
22
|
+
relatedIds: number[];
|
|
23
|
+
shortDescTemplateIdentifier: string | number | null;
|
|
24
|
+
statusId: number | null;
|
|
25
|
+
templateIdentifier: string | number | null;
|
|
26
|
+
}
|
|
27
|
+
interface IProductsQuery {
|
|
28
|
+
offset?: number;
|
|
29
|
+
limit?: number;
|
|
30
|
+
statusMarker?: string | null;
|
|
31
|
+
conditionValue?: string | null;
|
|
32
|
+
/**
|
|
33
|
+
* 'in' - Contains,
|
|
34
|
+
* 'nin' - Does not contain,
|
|
35
|
+
* 'eq' - Equal,
|
|
36
|
+
* 'neq' - Not equal,
|
|
37
|
+
* 'mth' - Greater than,
|
|
38
|
+
* 'lth' - Less than,
|
|
39
|
+
* 'exs' - Exists,
|
|
40
|
+
* 'nexs' - Does not exist
|
|
41
|
+
*/
|
|
42
|
+
conditionMarker?: 'in' | 'nin' | 'eq' | 'neq' | 'mth' | 'lth' | 'exs' | 'nexs' | null;
|
|
43
|
+
attributeMarker?: string | null;
|
|
44
|
+
sortOrder?: 'DESC' | 'ASC';
|
|
45
|
+
langCode?: string;
|
|
46
|
+
sortKey?: string;
|
|
47
|
+
[key: string]: string | number | null;
|
|
48
|
+
}
|
|
49
|
+
interface IFilterParams {
|
|
50
|
+
attributeMarker: string;
|
|
51
|
+
conditionMarker: string;
|
|
52
|
+
conditionValue: number;
|
|
53
|
+
pageId?: number;
|
|
54
|
+
}
|
|
55
|
+
interface IProductsEntity {
|
|
56
|
+
id: number;
|
|
57
|
+
localizeInfos: ILocalizeInfos;
|
|
58
|
+
isVisible: boolean;
|
|
59
|
+
statusId: number;
|
|
60
|
+
relatedIds: number[];
|
|
61
|
+
productPages: {
|
|
62
|
+
id: number;
|
|
63
|
+
pageId: number;
|
|
64
|
+
productId: number;
|
|
65
|
+
}[];
|
|
66
|
+
attributeSetId: number;
|
|
67
|
+
version: number;
|
|
68
|
+
isSync: number | boolean;
|
|
69
|
+
price: number;
|
|
70
|
+
templateIdentifier: string;
|
|
71
|
+
shortDescTemplateIdentifier: string;
|
|
72
|
+
/**
|
|
73
|
+
* Language-specific attribute values.
|
|
74
|
+
* @example attributeValues['en_US']
|
|
75
|
+
*
|
|
76
|
+
* @property {langCode.<object>}
|
|
77
|
+
*/
|
|
78
|
+
attributeValues: {
|
|
79
|
+
[langCode: string]: object;
|
|
80
|
+
};
|
|
81
|
+
position: number;
|
|
82
|
+
}
|
|
83
|
+
export { IFilterParams, IProductsQuery, IProduct, IProductApi, IProductsEntity };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"productsInterfaces.js","sourceRoot":"","sources":["../../../src/products/productsInterfaces.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import OneEntry from '../base/oneEntry';
|
|
2
|
+
import { ITemplatesApi, ITemplateEntity } from './templatesInterfaces';
|
|
3
|
+
/**
|
|
4
|
+
* Controllers for working with template objects
|
|
5
|
+
*/
|
|
6
|
+
export default class TemplatesPreviewApi extends OneEntry implements ITemplatesApi {
|
|
7
|
+
constructor(url: string);
|
|
8
|
+
/**
|
|
9
|
+
* Get all template objects grouped by types.
|
|
10
|
+
*
|
|
11
|
+
* @param {number} [id] - Status id
|
|
12
|
+
*
|
|
13
|
+
* @returns Returns an object GroupedTemplatesObject, which contains an array of template objects TemplateEntity
|
|
14
|
+
*/
|
|
15
|
+
getAllTemplates(): Promise<Array<ITemplateEntity>>;
|
|
16
|
+
/**
|
|
17
|
+
* Get one template object by id.
|
|
18
|
+
*
|
|
19
|
+
* @param {number} [id] - Product marker
|
|
20
|
+
*
|
|
21
|
+
* @returns Returns a TemplateEntity object
|
|
22
|
+
*/
|
|
23
|
+
getTemplateById(id: number): Promise<ITemplateEntity>;
|
|
24
|
+
/**
|
|
25
|
+
* Get a single template object by marker.
|
|
26
|
+
*
|
|
27
|
+
* @param {string} [marker] - Product marker
|
|
28
|
+
*
|
|
29
|
+
* @returns Returns a TemplateEntity object
|
|
30
|
+
*/
|
|
31
|
+
getTemplateByMarker(marker: string): Promise<ITemplateEntity>;
|
|
32
|
+
}
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
const oneEntry_1 = require("../base/oneEntry");
|
|
13
|
+
/**
|
|
14
|
+
* Controllers for working with template objects
|
|
15
|
+
*/
|
|
16
|
+
class TemplatesPreviewApi extends oneEntry_1.default {
|
|
17
|
+
constructor(url) {
|
|
18
|
+
super(url);
|
|
19
|
+
this._url += '/api/content/templates';
|
|
20
|
+
}
|
|
21
|
+
// /**
|
|
22
|
+
// * Get all template objects of a specific type.
|
|
23
|
+
// *
|
|
24
|
+
// * @returns Returns an array of product status objects
|
|
25
|
+
// */
|
|
26
|
+
// public async getTemplatesByType(type:string):Promise<Array<ITemplateEntity>> {
|
|
27
|
+
// //TODO уточнить парметр type
|
|
28
|
+
// const result = await this._fetchGet(`?type=${type}`)
|
|
29
|
+
// return result
|
|
30
|
+
// }
|
|
31
|
+
/**
|
|
32
|
+
* Get all template objects grouped by types.
|
|
33
|
+
*
|
|
34
|
+
* @param {number} [id] - Status id
|
|
35
|
+
*
|
|
36
|
+
* @returns Returns an object GroupedTemplatesObject, which contains an array of template objects TemplateEntity
|
|
37
|
+
*/
|
|
38
|
+
getAllTemplates() {
|
|
39
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
40
|
+
const result = yield this._fetchGet('/all');
|
|
41
|
+
return result;
|
|
42
|
+
});
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* Get one template object by id.
|
|
46
|
+
*
|
|
47
|
+
* @param {number} [id] - Product marker
|
|
48
|
+
*
|
|
49
|
+
* @returns Returns a TemplateEntity object
|
|
50
|
+
*/
|
|
51
|
+
getTemplateById(id) {
|
|
52
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
53
|
+
const result = yield this._fetchGet(`/${id}`);
|
|
54
|
+
return result;
|
|
55
|
+
});
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* Get a single template object by marker.
|
|
59
|
+
*
|
|
60
|
+
* @param {string} [marker] - Product marker
|
|
61
|
+
*
|
|
62
|
+
* @returns Returns a TemplateEntity object
|
|
63
|
+
*/
|
|
64
|
+
getTemplateByMarker(marker) {
|
|
65
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
66
|
+
const result = yield this._fetchGet(`/marker/${marker}`);
|
|
67
|
+
return result;
|
|
68
|
+
});
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
exports.default = TemplatesPreviewApi;
|
|
72
|
+
//# sourceMappingURL=templatesApi.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"templatesApi.js","sourceRoot":"","sources":["../../../src/templates/templatesApi.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,+CAAuC;AAGvC;;GAEG;AACH,MAAqB,mBAAoB,SAAQ,kBAAQ;IACrD,YAAY,GAAW;QACnB,KAAK,CAAC,GAAG,CAAC,CAAA;QACV,IAAI,CAAC,IAAI,IAAI,wBAAwB,CAAA;IACzC,CAAC;IAED,MAAM;IACN,kDAAkD;IAClD,KAAK;IACL,yDAAyD;IACzD,MAAM;IACN,iFAAiF;IACjF,mCAAmC;IACnC,2DAA2D;IAC3D,oBAAoB;IACpB,IAAI;IAEJ;;;;;;OAMG;IACU,eAAe;;YACxB,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,CAAA;YAC3C,OAAO,MAAM,CAAA;QACjB,CAAC;KAAA;IAED;;;;;;OAMG;IACU,eAAe,CAAC,EAAS;;YAClC,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,SAAS,CAAC,IAAI,EAAE,EAAE,CAAC,CAAA;YAC7C,OAAO,MAAM,CAAA;QACjB,CAAC;KAAA;IAED;;;;;;OAMG;IACU,mBAAmB,CAAC,MAAa;;YAC1C,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,SAAS,CAAC,WAAW,MAAM,EAAE,CAAC,CAAA;YACxD,OAAO,MAAM,CAAA;QACjB,CAAC;KAAA;CACJ;AApDD,sCAoDC"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { IGeneralTypesEntity } from "../general-types/generalTypesInterfaces";
|
|
2
|
+
import { ILocalizeInfos } from "../base/utils";
|
|
3
|
+
interface ITemplatesApi {
|
|
4
|
+
getAllTemplates(): Promise<Array<ITemplateEntity>>;
|
|
5
|
+
getTemplateById(id: number): Promise<ITemplateEntity>;
|
|
6
|
+
getTemplateByMarker(marker: string): Promise<ITemplateEntity>;
|
|
7
|
+
}
|
|
8
|
+
interface ITemplateEntity {
|
|
9
|
+
id: number;
|
|
10
|
+
updatedDate: string;
|
|
11
|
+
version: number;
|
|
12
|
+
identifier: string;
|
|
13
|
+
attributesSets: {
|
|
14
|
+
[key: string]: string;
|
|
15
|
+
};
|
|
16
|
+
attributeSetId: number;
|
|
17
|
+
generalType: IGeneralTypesEntity;
|
|
18
|
+
generalTypeId: number;
|
|
19
|
+
localizeInfos: ILocalizeInfos;
|
|
20
|
+
position: {
|
|
21
|
+
id: number;
|
|
22
|
+
position: number | string;
|
|
23
|
+
objectId: number;
|
|
24
|
+
objectType: string;
|
|
25
|
+
isLocked: boolean;
|
|
26
|
+
objectCategoryId: number;
|
|
27
|
+
};
|
|
28
|
+
positionId: number | string;
|
|
29
|
+
}
|
|
30
|
+
export { ITemplatesApi, ITemplateEntity };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"templatesInterfaces.js","sourceRoot":"","sources":["../../../src/templates/templatesInterfaces.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import OneEntry from "../base/oneEntry";
|
|
2
|
+
import { ITemplatesPreview, ITemplatesPreviewEntity } from "./templatesPreviewInterfaces";
|
|
3
|
+
/**
|
|
4
|
+
* Controllers for working with template objects for preview
|
|
5
|
+
*/
|
|
6
|
+
export default class PageApi extends OneEntry implements ITemplatesPreview {
|
|
7
|
+
constructor(url: string);
|
|
8
|
+
/**
|
|
9
|
+
* Get all template objects.
|
|
10
|
+
*
|
|
11
|
+
* @returns Returns all TemplatePreviewsEntity template objects
|
|
12
|
+
*/
|
|
13
|
+
getTemplatesPreview(): Promise<Array<ITemplatesPreviewEntity>>;
|
|
14
|
+
/**
|
|
15
|
+
* Get one template object by id.
|
|
16
|
+
*
|
|
17
|
+
* @param {number} [id] - Product marker
|
|
18
|
+
*
|
|
19
|
+
* @returns Returns a TemplatePreviewsEntity object
|
|
20
|
+
*/
|
|
21
|
+
getTemplatesPreviewById(id: number): Promise<ITemplatesPreviewEntity>;
|
|
22
|
+
/**
|
|
23
|
+
* Get one template object by marker.
|
|
24
|
+
*
|
|
25
|
+
* @param {string} [marker] - Product marker
|
|
26
|
+
*
|
|
27
|
+
* @returns Returns a TemplatePreviewsEntity object
|
|
28
|
+
*/
|
|
29
|
+
getTemplatesPreviewByMarker(marker: string): Promise<ITemplatesPreviewEntity>;
|
|
30
|
+
}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
const oneEntry_1 = require("../base/oneEntry");
|
|
13
|
+
/**
|
|
14
|
+
* Controllers for working with template objects for preview
|
|
15
|
+
*/
|
|
16
|
+
class PageApi extends oneEntry_1.default {
|
|
17
|
+
constructor(url) {
|
|
18
|
+
super(url);
|
|
19
|
+
this._url += '/api/content/template-previews';
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* Get all template objects.
|
|
23
|
+
*
|
|
24
|
+
* @returns Returns all TemplatePreviewsEntity template objects
|
|
25
|
+
*/
|
|
26
|
+
getTemplatesPreview() {
|
|
27
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
28
|
+
const result = yield this._fetchGet('');
|
|
29
|
+
return result;
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Get one template object by id.
|
|
34
|
+
*
|
|
35
|
+
* @param {number} [id] - Product marker
|
|
36
|
+
*
|
|
37
|
+
* @returns Returns a TemplatePreviewsEntity object
|
|
38
|
+
*/
|
|
39
|
+
getTemplatesPreviewById(id) {
|
|
40
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
41
|
+
const result = yield this._fetchGet(`/${id}`);
|
|
42
|
+
return result;
|
|
43
|
+
});
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Get one template object by marker.
|
|
47
|
+
*
|
|
48
|
+
* @param {string} [marker] - Product marker
|
|
49
|
+
*
|
|
50
|
+
* @returns Returns a TemplatePreviewsEntity object
|
|
51
|
+
*/
|
|
52
|
+
getTemplatesPreviewByMarker(marker) {
|
|
53
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
54
|
+
const result = yield this._fetchGet(`/marker/${marker}`);
|
|
55
|
+
return result;
|
|
56
|
+
});
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
exports.default = PageApi;
|
|
60
|
+
//# sourceMappingURL=templatesPreviewApi.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"templatesPreviewApi.js","sourceRoot":"","sources":["../../../src/templates-preview/templatesPreviewApi.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,+CAAwC;AAGxC;;GAEG;AACH,MAAqB,OAAQ,SAAQ,kBAAQ;IACzC,YAAY,GAAW;QACnB,KAAK,CAAC,GAAG,CAAC,CAAA;QACV,IAAI,CAAC,IAAI,IAAI,gCAAgC,CAAA;IACjD,CAAC;IAED;;;;OAIG;IACU,mBAAmB;;YAC5B,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,SAAS,CAAC,EAAE,CAAC,CAAA;YACvC,OAAO,MAAM,CAAA;QACjB,CAAC;KAAA;IAED;;;;;;OAMG;IACU,uBAAuB,CAAC,EAAS;;YAC1C,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,SAAS,CAAC,IAAI,EAAE,EAAE,CAAC,CAAA;YAC7C,OAAO,MAAM,CAAA;QACjB,CAAC;KAAA;IAED;;;;;;OAMG;IACU,2BAA2B,CAAC,MAAa;;YAClD,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,SAAS,CAAC,WAAW,MAAM,EAAE,CAAC,CAAA;YACxD,OAAO,MAAM,CAAA;QACjB,CAAC;KAAA;CACJ;AAvCD,0BAuCC"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { ILocalizeInfos } from "../base/utils";
|
|
2
|
+
interface ITemplatesPreview {
|
|
3
|
+
getTemplatesPreview(): Promise<Array<ITemplatesPreviewEntity>>;
|
|
4
|
+
getTemplatesPreviewById(id: number): Promise<ITemplatesPreviewEntity>;
|
|
5
|
+
getTemplatesPreviewByMarker(marker: string): Promise<ITemplatesPreviewEntity>;
|
|
6
|
+
}
|
|
7
|
+
interface ITemplatesPreviewEntity {
|
|
8
|
+
id: number;
|
|
9
|
+
updatedDate: string;
|
|
10
|
+
version: number;
|
|
11
|
+
identifier: string;
|
|
12
|
+
attributesSets: {
|
|
13
|
+
[key: string]: string;
|
|
14
|
+
};
|
|
15
|
+
attributeSetId: number;
|
|
16
|
+
localizeInfos: ILocalizeInfos;
|
|
17
|
+
position: {
|
|
18
|
+
id: number;
|
|
19
|
+
position: number | string;
|
|
20
|
+
objectId: number;
|
|
21
|
+
objectType: string;
|
|
22
|
+
isLocked: boolean;
|
|
23
|
+
objectCategoryId: number | null;
|
|
24
|
+
};
|
|
25
|
+
positionId: number | string;
|
|
26
|
+
}
|
|
27
|
+
export { ITemplatesPreview, ITemplatesPreviewEntity };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"templatesPreviewInterfaces.js","sourceRoot":"","sources":["../../../src/templates-preview/templatesPreviewInterfaces.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import OneEntry from "../base/oneEntry";
|
|
2
|
+
import { IAdminEntity, IAdmins } from "./adminsInterfaces";
|
|
3
|
+
/**
|
|
4
|
+
* Controllers for working with users - admins
|
|
5
|
+
*/
|
|
6
|
+
export default class AdminsApi extends OneEntry implements IAdmins {
|
|
7
|
+
constructor(url: string);
|
|
8
|
+
/**
|
|
9
|
+
* Get all user objects - admins.
|
|
10
|
+
*
|
|
11
|
+
* @returns Returns all AdminEntity user objects
|
|
12
|
+
*/
|
|
13
|
+
getAdminsInfo(): Promise<IAdminEntity>;
|
|
14
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
import OneEntry from "../base/oneEntry";
|
|
11
|
+
/**
|
|
12
|
+
* Controllers for working with users - admins
|
|
13
|
+
*/
|
|
14
|
+
export default class AdminsApi extends OneEntry {
|
|
15
|
+
constructor(url) {
|
|
16
|
+
super(url);
|
|
17
|
+
this._url += '/api/content/admins';
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* Get all user objects - admins.
|
|
21
|
+
*
|
|
22
|
+
* @returns Returns all AdminEntity user objects
|
|
23
|
+
*/
|
|
24
|
+
getAdminsInfo() {
|
|
25
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
26
|
+
const result = yield this._fetchGet('');
|
|
27
|
+
return result;
|
|
28
|
+
});
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
//# sourceMappingURL=adminsApi.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"adminsApi.js","sourceRoot":"","sources":["../../../src/admins/adminsApi.ts"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,QAAQ,MAAM,kBAAkB,CAAC;AAGxC;;GAEG;AACH,MAAM,CAAC,OAAO,OAAO,SAAU,SAAQ,QAAQ;IAC3C,YAAY,GAAW;QACnB,KAAK,CAAC,GAAG,CAAC,CAAA;QACV,IAAI,CAAC,IAAI,IAAI,qBAAqB,CAAA;IACtC,CAAC;IAED;;;;OAIG;IACU,aAAa;;YACtB,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,SAAS,CAAC,EAAE,CAAC,CAAA;YACvC,OAAO,MAAM,CAAA;QACjB,CAAC;KAAA;CACJ"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
interface IAdmins {
|
|
2
|
+
getAdminsInfo(): Promise<IAdminEntity>;
|
|
3
|
+
}
|
|
4
|
+
interface IPosition {
|
|
5
|
+
id: number;
|
|
6
|
+
position: string;
|
|
7
|
+
objectId: number;
|
|
8
|
+
objectType: string;
|
|
9
|
+
isLocked: boolean;
|
|
10
|
+
objectCategoryId: number;
|
|
11
|
+
}
|
|
12
|
+
interface IAttributesSets {
|
|
13
|
+
[key: string]: string;
|
|
14
|
+
}
|
|
15
|
+
interface IAdminEntity {
|
|
16
|
+
id: number;
|
|
17
|
+
updatedDate: string;
|
|
18
|
+
version: number;
|
|
19
|
+
identifier: string;
|
|
20
|
+
attributesSets: IAttributesSets;
|
|
21
|
+
attributeSetId: number;
|
|
22
|
+
login: string;
|
|
23
|
+
email?: string;
|
|
24
|
+
restorePasswordCode: number;
|
|
25
|
+
position: IPosition;
|
|
26
|
+
positionId: number;
|
|
27
|
+
permissions: Record<string, boolean>;
|
|
28
|
+
selectedLanguage: string;
|
|
29
|
+
selectedContentLanguage: string;
|
|
30
|
+
selectedUITheme: string;
|
|
31
|
+
}
|
|
32
|
+
export { IAdmins, IAdminEntity };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"adminsInterfaces.js","sourceRoot":"","sources":["../../../src/admins/adminsInterfaces.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import OneEntry from "../base/oneEntry";
|
|
2
|
+
import { IAttributeSet, IAttributeSetEntity } from "./attributeSetInterfaces";
|
|
3
|
+
/**
|
|
4
|
+
* Controllers for working with attribute sets
|
|
5
|
+
*/
|
|
6
|
+
export default class AttributeSetApi extends OneEntry implements IAttributeSet {
|
|
7
|
+
constructor(url: string);
|
|
8
|
+
/**
|
|
9
|
+
* Get one attributes set object.
|
|
10
|
+
*
|
|
11
|
+
* @param {number} [id] - Identifier of the attributes set object
|
|
12
|
+
*
|
|
13
|
+
* @returns Returns one attributes set object
|
|
14
|
+
*/
|
|
15
|
+
getAttributeSetById(id: number): Promise<IAttributeSetEntity>;
|
|
16
|
+
/**
|
|
17
|
+
* Get one attributes set object by marker.
|
|
18
|
+
*
|
|
19
|
+
* @param {string} [marker] - Marker of the attributes set object
|
|
20
|
+
*
|
|
21
|
+
* @returns Returns one attributes set object
|
|
22
|
+
*/
|
|
23
|
+
getAttributeSetByMarker(marker: string): Promise<IAttributeSetEntity>;
|
|
24
|
+
}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
import OneEntry from "../base/oneEntry";
|
|
11
|
+
/**
|
|
12
|
+
* Controllers for working with attribute sets
|
|
13
|
+
*/
|
|
14
|
+
export default class AttributeSetApi extends OneEntry {
|
|
15
|
+
constructor(url) {
|
|
16
|
+
super(url);
|
|
17
|
+
this._url += '/api/content/attributes-sets';
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* Get one attributes set object.
|
|
21
|
+
*
|
|
22
|
+
* @param {number} [id] - Identifier of the attributes set object
|
|
23
|
+
*
|
|
24
|
+
* @returns Returns one attributes set object
|
|
25
|
+
*/
|
|
26
|
+
getAttributeSetById(id) {
|
|
27
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
28
|
+
const result = yield this._fetchGet(`/${id}`);
|
|
29
|
+
return result;
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Get one attributes set object by marker.
|
|
34
|
+
*
|
|
35
|
+
* @param {string} [marker] - Marker of the attributes set object
|
|
36
|
+
*
|
|
37
|
+
* @returns Returns one attributes set object
|
|
38
|
+
*/
|
|
39
|
+
getAttributeSetByMarker(marker) {
|
|
40
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
41
|
+
const result = yield this._fetchGet(`/marker/${marker}`);
|
|
42
|
+
return result;
|
|
43
|
+
});
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
//# sourceMappingURL=attributeSetApi.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"attributeSetApi.js","sourceRoot":"","sources":["../../../src/attribute-set/attributeSetApi.ts"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,QAAQ,MAAM,kBAAkB,CAAC;AAGxC;;GAEG;AACH,MAAM,CAAC,OAAO,OAAO,eAAgB,SAAQ,QAAQ;IACjD,YAAY,GAAW;QACnB,KAAK,CAAC,GAAG,CAAC,CAAA;QACV,IAAI,CAAC,IAAI,IAAI,8BAA8B,CAAA;IAC/C,CAAC;IAED;;;;;;OAMG;IACU,mBAAmB,CAAC,EAAS;;YACtC,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,SAAS,CAAC,IAAI,EAAE,EAAE,CAAC,CAAA;YAC7C,OAAO,MAAM,CAAA;QACjB,CAAC;KAAA;IAED;;;;;;OAMG;IACU,uBAAuB,CAAC,MAAa;;YAC9C,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,SAAS,CAAC,WAAW,MAAM,EAAE,CAAC,CAAA;YACxD,OAAO,MAAM,CAAA;QACjB,CAAC;KAAA;CACJ"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { ILocalizeInfos } from "../base/utils";
|
|
2
|
+
interface IAttributeSet {
|
|
3
|
+
getAttributeSetById(id: number): Promise<IAttributeSetEntity>;
|
|
4
|
+
getAttributeSetByMarker(url: string): Promise<IAttributeSetEntity>;
|
|
5
|
+
}
|
|
6
|
+
interface IAttributeSetEntity {
|
|
7
|
+
id: number;
|
|
8
|
+
updatedDate: string;
|
|
9
|
+
version: number;
|
|
10
|
+
identifier: string;
|
|
11
|
+
typeId: number;
|
|
12
|
+
localizeInfos: ILocalizeInfos;
|
|
13
|
+
schema: object;
|
|
14
|
+
position: {
|
|
15
|
+
id: number;
|
|
16
|
+
objectId: number;
|
|
17
|
+
objectType: string;
|
|
18
|
+
position: number | string;
|
|
19
|
+
};
|
|
20
|
+
positionId: number | string;
|
|
21
|
+
isVisible: boolean;
|
|
22
|
+
}
|
|
23
|
+
export { IAttributeSet, IAttributeSetEntity };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"attributeSetInterfaces.js","sourceRoot":"","sources":["../../../src/attribute-set/attributeSetInterfaces.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { IProductsQuery } from '../products/productsInterfaces';
|
|
2
|
+
export default abstract class OneEntry {
|
|
3
|
+
protected _url: string;
|
|
4
|
+
constructor(url: string);
|
|
5
|
+
protected _getFullPath(path: string): string;
|
|
6
|
+
protected _fetchGet(path: string): Promise<any>;
|
|
7
|
+
protected _fetchPost(path: string, data: object): Promise<any>;
|
|
8
|
+
protected _queryParamsToString(query: IProductsQuery): string;
|
|
9
|
+
}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
export default class OneEntry {
|
|
11
|
+
constructor(url) {
|
|
12
|
+
this._url = url;
|
|
13
|
+
}
|
|
14
|
+
_getFullPath(path) {
|
|
15
|
+
return (this._url + path);
|
|
16
|
+
}
|
|
17
|
+
_fetchGet(path) {
|
|
18
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
19
|
+
const response = yield fetch(this._getFullPath(path), {
|
|
20
|
+
method: 'GET',
|
|
21
|
+
headers: {
|
|
22
|
+
'Content-Type': 'application/json'
|
|
23
|
+
}
|
|
24
|
+
});
|
|
25
|
+
const result = yield response.json();
|
|
26
|
+
return result;
|
|
27
|
+
});
|
|
28
|
+
}
|
|
29
|
+
_fetchPost(path, data) {
|
|
30
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
31
|
+
const response = yield fetch(this._getFullPath(path), {
|
|
32
|
+
method: 'POST',
|
|
33
|
+
headers: {
|
|
34
|
+
'Content-Type': 'application/json'
|
|
35
|
+
},
|
|
36
|
+
body: JSON.stringify(data)
|
|
37
|
+
});
|
|
38
|
+
const result = yield response.json();
|
|
39
|
+
return result;
|
|
40
|
+
});
|
|
41
|
+
}
|
|
42
|
+
_queryParamsToString(query) {
|
|
43
|
+
let result = '';
|
|
44
|
+
for (let key in query) {
|
|
45
|
+
if (query[key] !== null) {
|
|
46
|
+
result += `${key}=${query[key]}&`;
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
return result.slice(0, (result.length - 1));
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
//# sourceMappingURL=oneEntry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"oneEntry.js","sourceRoot":"","sources":["../../../src/base/oneEntry.ts"],"names":[],"mappings":";;;;;;;;;AAEA,MAAM,CAAC,OAAO,OAAgB,QAAQ;IAGlC,YAAY,GAAU;QAClB,IAAI,CAAC,IAAI,GAAG,GAAG,CAAA;IACnB,CAAC;IAES,YAAY,CAAC,IAAW;QAC9B,OAAO,CAAC,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,CAAA;IAC7B,CAAC;IAEe,SAAS,CAAC,IAAW;;YACjC,MAAM,QAAQ,GAAG,MAAM,KAAK,CAAC,IAAI,CAAC,YAA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