@digital8/lighting-illusions-ts-sdk 0.0.992 → 0.0.994
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/.openapi-generator/FILES +6 -0
- package/README.md +8 -3
- package/dist/apis/AttributeApi.d.ts +16 -1
- package/dist/apis/AttributeApi.js +58 -0
- package/dist/apis/ProductCategoryApi.d.ts +23 -4
- package/dist/apis/ProductCategoryApi.js +71 -7
- package/dist/models/CategoryAutomationRuleResource.d.ts +3 -3
- package/dist/models/CategoryAutomationRuleResource.js +3 -5
- package/dist/models/GetAllProductChildRequest.d.ts +6 -0
- package/dist/models/GetAllProductChildRequest.js +2 -0
- package/dist/models/GetHierarchyProductCategoryRequest.d.ts +32 -0
- package/dist/models/GetHierarchyProductCategoryRequest.js +51 -0
- package/dist/models/IndexAttributeValueRequest.d.ts +105 -0
- package/dist/models/IndexAttributeValueRequest.js +88 -0
- package/dist/models/IndexProductCategoryRequest.d.ts +2 -0
- package/dist/models/IndexProductCategoryRequest.js +3 -1
- package/dist/models/IndexProductChildRequest.d.ts +6 -0
- package/dist/models/IndexProductChildRequest.js +2 -0
- package/dist/models/PaginatedAttributeValueResourceResponse.d.ts +40 -0
- package/dist/models/PaginatedAttributeValueResourceResponse.js +57 -0
- package/dist/models/PreviewAutomationRulesResource.d.ts +0 -6
- package/dist/models/PreviewAutomationRulesResource.js +0 -2
- package/dist/models/ProductAggregationResource.d.ts +2 -2
- package/dist/models/ProductCategoryResource.d.ts +6 -0
- package/dist/models/ProductCategoryResource.js +4 -0
- package/dist/models/ProductChildResource.d.ts +6 -0
- package/dist/models/ProductChildResource.js +4 -0
- package/dist/models/ProductChildSiteDetailResource.d.ts +18 -0
- package/dist/models/ProductChildSiteDetailResource.js +12 -0
- package/dist/models/StoreProductCategoryRequestAutomationRulesInner.d.ts +3 -3
- package/dist/models/StoreProductCategoryRequestAutomationRulesInner.js +3 -5
- package/dist/models/StoreProductChildRequest.d.ts +7 -1
- package/dist/models/StoreProductChildRequest.js +6 -4
- package/dist/models/StoreProductChildRequestSitesInner.d.ts +18 -0
- package/dist/models/StoreProductChildRequestSitesInner.js +12 -0
- package/dist/models/UpdateProductChildRequest.d.ts +12 -0
- package/dist/models/UpdateProductChildRequest.js +6 -0
- package/dist/models/index.d.ts +3 -0
- package/dist/models/index.js +3 -0
- package/docs/AttributeApi.md +66 -0
- package/docs/CategoryAutomationRuleResource.md +3 -3
- package/docs/GetAllProductChildRequest.md +2 -0
- package/docs/GetHierarchyProductCategoryRequest.md +34 -0
- package/docs/IndexAttributeValueRequest.md +50 -0
- package/docs/IndexProductChildRequest.md +2 -0
- package/docs/PaginatedAttributeValueResourceResponse.md +36 -0
- package/docs/PreviewAutomationRulesResource.md +0 -2
- package/docs/ProductAggregationResource.md +1 -1
- package/docs/ProductCategoryApi.md +83 -6
- package/docs/ProductCategoryResource.md +2 -0
- package/docs/ProductChildResource.md +2 -0
- package/docs/ProductChildSiteDetailResource.md +6 -0
- package/docs/StoreProductCategoryRequestAutomationRulesInner.md +2 -2
- package/docs/StoreProductChildRequest.md +2 -0
- package/docs/StoreProductChildRequestSitesInner.md +6 -0
- package/docs/UpdateProductChildRequest.md +4 -0
- package/package.json +1 -1
- package/src/apis/AttributeApi.ts +50 -0
- package/src/apis/ProductCategoryApi.ts +72 -6
- package/src/models/CategoryAutomationRuleResource.ts +6 -7
- package/src/models/GetAllProductChildRequest.ts +8 -0
- package/src/models/GetHierarchyProductCategoryRequest.ts +66 -0
- package/src/models/IndexAttributeValueRequest.ts +159 -0
- package/src/models/IndexProductCategoryRequest.ts +3 -1
- package/src/models/IndexProductChildRequest.ts +8 -0
- package/src/models/PaginatedAttributeValueResourceResponse.ts +90 -0
- package/src/models/PreviewAutomationRulesResource.ts +0 -8
- package/src/models/ProductAggregationResource.ts +2 -2
- package/src/models/ProductCategoryResource.ts +9 -0
- package/src/models/ProductChildResource.ts +9 -0
- package/src/models/ProductChildSiteDetailResource.ts +27 -0
- package/src/models/StoreProductCategoryRequestAutomationRulesInner.ts +6 -7
- package/src/models/StoreProductChildRequest.ts +12 -4
- package/src/models/StoreProductChildRequestSitesInner.ts +27 -0
- package/src/models/UpdateProductChildRequest.ts +17 -0
- package/src/models/index.ts +3 -0
package/.openapi-generator/FILES
CHANGED
|
@@ -83,6 +83,7 @@ docs/GetAllProductChildRequest.md
|
|
|
83
83
|
docs/GetAllProductRequest.md
|
|
84
84
|
docs/GetAllProductTypeRequest.md
|
|
85
85
|
docs/GetAllSupplierRequest.md
|
|
86
|
+
docs/GetHierarchyProductCategoryRequest.md
|
|
86
87
|
docs/GlobalSearchCategoryResource.md
|
|
87
88
|
docs/GlobalSearchCategoryResourceArrayResponse.md
|
|
88
89
|
docs/GlobalSearchProductResource.md
|
|
@@ -95,6 +96,7 @@ docs/GoogleCategoryApi.md
|
|
|
95
96
|
docs/GoogleCategoryResource.md
|
|
96
97
|
docs/GoogleCategoryResourceArrayResponse.md
|
|
97
98
|
docs/IndexAttributeRequest.md
|
|
99
|
+
docs/IndexAttributeValueRequest.md
|
|
98
100
|
docs/IndexDefinitionRequest.md
|
|
99
101
|
docs/IndexDocumentRequest.md
|
|
100
102
|
docs/IndexExternalApiLogRequest.md
|
|
@@ -125,6 +127,7 @@ docs/PaginatedAttributeListResourceResponse.md
|
|
|
125
127
|
docs/PaginatedAttributeLiteResourceResponse.md
|
|
126
128
|
docs/PaginatedAttributeProductTypeRelationResourceResponse.md
|
|
127
129
|
docs/PaginatedAttributeResourceResponse.md
|
|
130
|
+
docs/PaginatedAttributeValueResourceResponse.md
|
|
128
131
|
docs/PaginatedCategoryFrontendResourceResponse.md
|
|
129
132
|
docs/PaginatedDefinitionListResourceResponse.md
|
|
130
133
|
docs/PaginatedDefinitionResourceResponse.md
|
|
@@ -390,6 +393,7 @@ src/models/GetAllProductChildRequest.ts
|
|
|
390
393
|
src/models/GetAllProductRequest.ts
|
|
391
394
|
src/models/GetAllProductTypeRequest.ts
|
|
392
395
|
src/models/GetAllSupplierRequest.ts
|
|
396
|
+
src/models/GetHierarchyProductCategoryRequest.ts
|
|
393
397
|
src/models/GlobalSearchCategoryResource.ts
|
|
394
398
|
src/models/GlobalSearchCategoryResourceArrayResponse.ts
|
|
395
399
|
src/models/GlobalSearchProductResource.ts
|
|
@@ -401,6 +405,7 @@ src/models/GlobalSearchResponseResourceArrayResponse.ts
|
|
|
401
405
|
src/models/GoogleCategoryResource.ts
|
|
402
406
|
src/models/GoogleCategoryResourceArrayResponse.ts
|
|
403
407
|
src/models/IndexAttributeRequest.ts
|
|
408
|
+
src/models/IndexAttributeValueRequest.ts
|
|
404
409
|
src/models/IndexDefinitionRequest.ts
|
|
405
410
|
src/models/IndexDocumentRequest.ts
|
|
406
411
|
src/models/IndexExternalApiLogRequest.ts
|
|
@@ -430,6 +435,7 @@ src/models/PaginatedAttributeListResourceResponse.ts
|
|
|
430
435
|
src/models/PaginatedAttributeLiteResourceResponse.ts
|
|
431
436
|
src/models/PaginatedAttributeProductTypeRelationResourceResponse.ts
|
|
432
437
|
src/models/PaginatedAttributeResourceResponse.ts
|
|
438
|
+
src/models/PaginatedAttributeValueResourceResponse.ts
|
|
433
439
|
src/models/PaginatedCategoryFrontendResourceResponse.ts
|
|
434
440
|
src/models/PaginatedDefinitionListResourceResponse.ts
|
|
435
441
|
src/models/PaginatedDefinitionResourceResponse.ts
|
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# @digital8/lighting-illusions-ts-sdk@0.0.
|
|
1
|
+
# @digital8/lighting-illusions-ts-sdk@0.0.994
|
|
2
2
|
|
|
3
3
|
A TypeScript SDK client for the localhost API.
|
|
4
4
|
|
|
@@ -60,6 +60,7 @@ All URIs are relative to *http://localhost/api*
|
|
|
60
60
|
*AttributeApi* | [**detachProductTypeAttribute**](docs/AttributeApi.md#detachproducttypeattribute) | **POST** /admin-api/attribute/{attribute}/detach-product-type/{productType} | Auto-generated: detachProductTypeAttribute
|
|
61
61
|
*AttributeApi* | [**getAllAttribute**](docs/AttributeApi.md#getallattributeoperation) | **POST** /admin-api/attribute/all | Auto-generated: getAllAttribute
|
|
62
62
|
*AttributeApi* | [**indexAttribute**](docs/AttributeApi.md#indexattributeoperation) | **POST** /admin-api/attribute/list | Auto-generated: indexAttribute
|
|
63
|
+
*AttributeApi* | [**indexAttributeValue**](docs/AttributeApi.md#indexattributevalueoperation) | **POST** /admin-api/attribute/value/list | Auto-generated: indexAttributeValue
|
|
63
64
|
*AttributeApi* | [**showAttribute**](docs/AttributeApi.md#showattribute) | **GET** /admin-api/attribute/{attribute} | Auto-generated: showAttribute
|
|
64
65
|
*AttributeApi* | [**storeAttribute**](docs/AttributeApi.md#storeattributeoperation) | **POST** /admin-api/attribute/create | Auto-generated: storeAttribute
|
|
65
66
|
*AttributeApi* | [**storeAttributeValue**](docs/AttributeApi.md#storeattributevalueoperation) | **POST** /admin-api/attribute/value/create | Auto-generated: storeAttributeValue
|
|
@@ -122,9 +123,10 @@ All URIs are relative to *http://localhost/api*
|
|
|
122
123
|
*ProductCategoryApi* | [**bulkDetachProductsProductCategory**](docs/ProductCategoryApi.md#bulkdetachproductsproductcategory) | **DELETE** /admin-api/product-category/{productCategory}/bulk-detach-products | Auto-generated: bulkDetachProductsProductCategory
|
|
123
124
|
*ProductCategoryApi* | [**destroyProductCategory**](docs/ProductCategoryApi.md#destroyproductcategory) | **DELETE** /admin-api/product-category/{productCategory}/delete | Auto-generated: destroyProductCategory
|
|
124
125
|
*ProductCategoryApi* | [**detachProductsProductCategory**](docs/ProductCategoryApi.md#detachproductsproductcategoryoperation) | **POST** /admin-api/product-category/{productCategory}/detach-products | Auto-generated: detachProductsProductCategory
|
|
126
|
+
*ProductCategoryApi* | [**getAllChildrenProductCategory**](docs/ProductCategoryApi.md#getallchildrenproductcategory) | **POST** /admin-api/product-category/{productCategory}/children/all | Auto-generated: getAllChildrenProductCategory
|
|
125
127
|
*ProductCategoryApi* | [**getAllProductCategory**](docs/ProductCategoryApi.md#getallproductcategoryoperation) | **POST** /admin-api/product-category/all | Auto-generated: getAllProductCategory
|
|
126
128
|
*ProductCategoryApi* | [**getChildrenProductCategory**](docs/ProductCategoryApi.md#getchildrenproductcategory) | **GET** /admin-api/product-category/{productCategory}/children | Auto-generated: getChildrenProductCategory
|
|
127
|
-
*ProductCategoryApi* | [**getHierarchyProductCategory**](docs/ProductCategoryApi.md#
|
|
129
|
+
*ProductCategoryApi* | [**getHierarchyProductCategory**](docs/ProductCategoryApi.md#gethierarchyproductcategoryoperation) | **POST** /admin-api/product-category/hierarchy | Auto-generated: getHierarchyProductCategory
|
|
128
130
|
*ProductCategoryApi* | [**indexProductCategory**](docs/ProductCategoryApi.md#indexproductcategoryoperation) | **POST** /admin-api/product-category/list | Auto-generated: indexProductCategory
|
|
129
131
|
*ProductCategoryApi* | [**previewAutomationRulesProductCategory**](docs/ProductCategoryApi.md#previewautomationrulesproductcategoryoperation) | **POST** /admin-api/product-category/preview-automation-rules | Auto-generated: previewAutomationRulesProductCategory
|
|
130
132
|
*ProductCategoryApi* | [**showProductCategory**](docs/ProductCategoryApi.md#showproductcategory) | **GET** /admin-api/product-category/{productCategory} | Auto-generated: showProductCategory
|
|
@@ -243,6 +245,7 @@ All URIs are relative to *http://localhost/api*
|
|
|
243
245
|
- [GetAllProductRequest](docs/GetAllProductRequest.md)
|
|
244
246
|
- [GetAllProductTypeRequest](docs/GetAllProductTypeRequest.md)
|
|
245
247
|
- [GetAllSupplierRequest](docs/GetAllSupplierRequest.md)
|
|
248
|
+
- [GetHierarchyProductCategoryRequest](docs/GetHierarchyProductCategoryRequest.md)
|
|
246
249
|
- [GlobalSearchCategoryResource](docs/GlobalSearchCategoryResource.md)
|
|
247
250
|
- [GlobalSearchCategoryResourceArrayResponse](docs/GlobalSearchCategoryResourceArrayResponse.md)
|
|
248
251
|
- [GlobalSearchProductResource](docs/GlobalSearchProductResource.md)
|
|
@@ -254,6 +257,7 @@ All URIs are relative to *http://localhost/api*
|
|
|
254
257
|
- [GoogleCategoryResource](docs/GoogleCategoryResource.md)
|
|
255
258
|
- [GoogleCategoryResourceArrayResponse](docs/GoogleCategoryResourceArrayResponse.md)
|
|
256
259
|
- [IndexAttributeRequest](docs/IndexAttributeRequest.md)
|
|
260
|
+
- [IndexAttributeValueRequest](docs/IndexAttributeValueRequest.md)
|
|
257
261
|
- [IndexDefinitionRequest](docs/IndexDefinitionRequest.md)
|
|
258
262
|
- [IndexDocumentRequest](docs/IndexDocumentRequest.md)
|
|
259
263
|
- [IndexExternalApiLogRequest](docs/IndexExternalApiLogRequest.md)
|
|
@@ -283,6 +287,7 @@ All URIs are relative to *http://localhost/api*
|
|
|
283
287
|
- [PaginatedAttributeLiteResourceResponse](docs/PaginatedAttributeLiteResourceResponse.md)
|
|
284
288
|
- [PaginatedAttributeProductTypeRelationResourceResponse](docs/PaginatedAttributeProductTypeRelationResourceResponse.md)
|
|
285
289
|
- [PaginatedAttributeResourceResponse](docs/PaginatedAttributeResourceResponse.md)
|
|
290
|
+
- [PaginatedAttributeValueResourceResponse](docs/PaginatedAttributeValueResourceResponse.md)
|
|
286
291
|
- [PaginatedCategoryFrontendResourceResponse](docs/PaginatedCategoryFrontendResourceResponse.md)
|
|
287
292
|
- [PaginatedDefinitionListResourceResponse](docs/PaginatedDefinitionListResourceResponse.md)
|
|
288
293
|
- [PaginatedDefinitionResourceResponse](docs/PaginatedDefinitionResourceResponse.md)
|
|
@@ -463,7 +468,7 @@ and is automatically generated by the
|
|
|
463
468
|
[OpenAPI Generator](https://openapi-generator.tech) project:
|
|
464
469
|
|
|
465
470
|
- API version: `1.0.0`
|
|
466
|
-
- Package version: `0.0.
|
|
471
|
+
- Package version: `0.0.994`
|
|
467
472
|
- Generator version: `7.20.0`
|
|
468
473
|
- Build package: `org.openapitools.codegen.languages.TypeScriptFetchClientCodegen`
|
|
469
474
|
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime';
|
|
13
|
-
import type { AttachProductTypeAttributeRequest, AttributeLiteResourceArrayResponse, AttributeResource, AttributeResourceArrayResponse, DestroyAttributeValueRequest, GenericResponse, GetAllAttributeRequest, IndexAttributeRequest, ModelAttributeResourceArrayResponse, PaginatedAttributeListResourceResponse, StoreAttributeRequest, StoreAttributeValueRequest, UpdateAttributeRequest, UpdateAttributeValueRequest, UpdateFilterOrderAttributeRequest, UpdateModelAttributeRequest } from '../models/index';
|
|
13
|
+
import type { AttachProductTypeAttributeRequest, AttributeLiteResourceArrayResponse, AttributeResource, AttributeResourceArrayResponse, DestroyAttributeValueRequest, GenericResponse, GetAllAttributeRequest, IndexAttributeRequest, IndexAttributeValueRequest, ModelAttributeResourceArrayResponse, PaginatedAttributeListResourceResponse, PaginatedAttributeValueResourceResponse, StoreAttributeRequest, StoreAttributeValueRequest, UpdateAttributeRequest, UpdateAttributeValueRequest, UpdateFilterOrderAttributeRequest, UpdateModelAttributeRequest } from '../models/index';
|
|
14
14
|
export interface AttachProductTypeAttributeOperationRequest {
|
|
15
15
|
attribute: number;
|
|
16
16
|
attachProductTypeAttributeRequest?: AttachProductTypeAttributeRequest;
|
|
@@ -32,6 +32,9 @@ export interface GetAllAttributeOperationRequest {
|
|
|
32
32
|
export interface IndexAttributeOperationRequest {
|
|
33
33
|
indexAttributeRequest?: IndexAttributeRequest;
|
|
34
34
|
}
|
|
35
|
+
export interface IndexAttributeValueOperationRequest {
|
|
36
|
+
indexAttributeValueRequest?: IndexAttributeValueRequest;
|
|
37
|
+
}
|
|
35
38
|
export interface ShowAttributeRequest {
|
|
36
39
|
attribute: number;
|
|
37
40
|
}
|
|
@@ -136,6 +139,18 @@ export declare class AttributeApi extends runtime.BaseAPI {
|
|
|
136
139
|
* Auto-generated: indexAttribute
|
|
137
140
|
*/
|
|
138
141
|
indexAttribute(requestParameters?: IndexAttributeOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaginatedAttributeListResourceResponse>;
|
|
142
|
+
/**
|
|
143
|
+
* Creates request options for indexAttributeValue without sending the request
|
|
144
|
+
*/
|
|
145
|
+
indexAttributeValueRequestOpts(requestParameters: IndexAttributeValueOperationRequest): Promise<runtime.RequestOpts>;
|
|
146
|
+
/**
|
|
147
|
+
* Auto-generated: indexAttributeValue
|
|
148
|
+
*/
|
|
149
|
+
indexAttributeValueRaw(requestParameters: IndexAttributeValueOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PaginatedAttributeValueResourceResponse>>;
|
|
150
|
+
/**
|
|
151
|
+
* Auto-generated: indexAttributeValue
|
|
152
|
+
*/
|
|
153
|
+
indexAttributeValue(requestParameters?: IndexAttributeValueOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaginatedAttributeValueResourceResponse>;
|
|
139
154
|
/**
|
|
140
155
|
* Creates request options for showAttribute without sending the request
|
|
141
156
|
*/
|
|
@@ -435,6 +435,64 @@ var AttributeApi = /** @class */ (function (_super) {
|
|
|
435
435
|
});
|
|
436
436
|
});
|
|
437
437
|
};
|
|
438
|
+
/**
|
|
439
|
+
* Creates request options for indexAttributeValue without sending the request
|
|
440
|
+
*/
|
|
441
|
+
AttributeApi.prototype.indexAttributeValueRequestOpts = function (requestParameters) {
|
|
442
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
443
|
+
var queryParameters, headerParameters, urlPath;
|
|
444
|
+
return __generator(this, function (_a) {
|
|
445
|
+
queryParameters = {};
|
|
446
|
+
headerParameters = {};
|
|
447
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
448
|
+
urlPath = "/admin-api/attribute/value/list";
|
|
449
|
+
return [2 /*return*/, {
|
|
450
|
+
path: urlPath,
|
|
451
|
+
method: 'POST',
|
|
452
|
+
headers: headerParameters,
|
|
453
|
+
query: queryParameters,
|
|
454
|
+
body: (0, index_1.IndexAttributeValueRequestToJSON)(requestParameters['indexAttributeValueRequest']),
|
|
455
|
+
}];
|
|
456
|
+
});
|
|
457
|
+
});
|
|
458
|
+
};
|
|
459
|
+
/**
|
|
460
|
+
* Auto-generated: indexAttributeValue
|
|
461
|
+
*/
|
|
462
|
+
AttributeApi.prototype.indexAttributeValueRaw = function (requestParameters, initOverrides) {
|
|
463
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
464
|
+
var requestOptions, response;
|
|
465
|
+
return __generator(this, function (_a) {
|
|
466
|
+
switch (_a.label) {
|
|
467
|
+
case 0: return [4 /*yield*/, this.indexAttributeValueRequestOpts(requestParameters)];
|
|
468
|
+
case 1:
|
|
469
|
+
requestOptions = _a.sent();
|
|
470
|
+
return [4 /*yield*/, this.request(requestOptions, initOverrides)];
|
|
471
|
+
case 2:
|
|
472
|
+
response = _a.sent();
|
|
473
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.PaginatedAttributeValueResourceResponseFromJSON)(jsonValue); })];
|
|
474
|
+
}
|
|
475
|
+
});
|
|
476
|
+
});
|
|
477
|
+
};
|
|
478
|
+
/**
|
|
479
|
+
* Auto-generated: indexAttributeValue
|
|
480
|
+
*/
|
|
481
|
+
AttributeApi.prototype.indexAttributeValue = function () {
|
|
482
|
+
return __awaiter(this, arguments, void 0, function (requestParameters, initOverrides) {
|
|
483
|
+
var response;
|
|
484
|
+
if (requestParameters === void 0) { requestParameters = {}; }
|
|
485
|
+
return __generator(this, function (_a) {
|
|
486
|
+
switch (_a.label) {
|
|
487
|
+
case 0: return [4 /*yield*/, this.indexAttributeValueRaw(requestParameters, initOverrides)];
|
|
488
|
+
case 1:
|
|
489
|
+
response = _a.sent();
|
|
490
|
+
return [4 /*yield*/, response.value()];
|
|
491
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
492
|
+
}
|
|
493
|
+
});
|
|
494
|
+
});
|
|
495
|
+
};
|
|
438
496
|
/**
|
|
439
497
|
* Creates request options for showAttribute without sending the request
|
|
440
498
|
*/
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime';
|
|
13
|
-
import type { AttachProductsProductCategoryRequest, DetachProductsProductCategoryRequest, GenericResponse, GetAllProductCategoryRequest, IndexProductCategoryRequest, PaginatedProductCategoryListResourceResponse, PreviewAutomationRulesProductCategoryRequest, PreviewAutomationRulesResource, ProductCategoryHierarchyResourceArrayResponse, ProductCategoryLiteResourceArrayResponse, ProductCategoryResource, StoreProductCategoryRequest, UpdateProductCategoryRequest } from '../models/index';
|
|
13
|
+
import type { AttachProductsProductCategoryRequest, DetachProductsProductCategoryRequest, GenericResponse, GetAllProductCategoryRequest, GetHierarchyProductCategoryRequest, IndexProductCategoryRequest, PaginatedProductCategoryListResourceResponse, PreviewAutomationRulesProductCategoryRequest, PreviewAutomationRulesResource, ProductCategoryHierarchyResourceArrayResponse, ProductCategoryListResourceArrayResponse, ProductCategoryLiteResourceArrayResponse, ProductCategoryResource, StoreProductCategoryRequest, UpdateProductCategoryRequest } from '../models/index';
|
|
14
14
|
export interface AttachProductsProductCategoryOperationRequest {
|
|
15
15
|
productCategory: number;
|
|
16
16
|
attachProductsProductCategoryRequest?: AttachProductsProductCategoryRequest;
|
|
@@ -25,6 +25,10 @@ export interface DetachProductsProductCategoryOperationRequest {
|
|
|
25
25
|
productCategory: number;
|
|
26
26
|
detachProductsProductCategoryRequest?: DetachProductsProductCategoryRequest;
|
|
27
27
|
}
|
|
28
|
+
export interface GetAllChildrenProductCategoryRequest {
|
|
29
|
+
productCategory: number;
|
|
30
|
+
getAllProductCategoryRequest?: GetAllProductCategoryRequest;
|
|
31
|
+
}
|
|
28
32
|
export interface GetAllProductCategoryOperationRequest {
|
|
29
33
|
getAllProductCategoryRequest?: GetAllProductCategoryRequest;
|
|
30
34
|
}
|
|
@@ -32,6 +36,9 @@ export interface GetChildrenProductCategoryRequest {
|
|
|
32
36
|
productCategory: number;
|
|
33
37
|
indexProductCategoryRequest?: IndexProductCategoryRequest;
|
|
34
38
|
}
|
|
39
|
+
export interface GetHierarchyProductCategoryOperationRequest {
|
|
40
|
+
getHierarchyProductCategoryRequest?: GetHierarchyProductCategoryRequest;
|
|
41
|
+
}
|
|
35
42
|
export interface IndexProductCategoryOperationRequest {
|
|
36
43
|
indexProductCategoryRequest?: IndexProductCategoryRequest;
|
|
37
44
|
}
|
|
@@ -100,6 +107,18 @@ export declare class ProductCategoryApi extends runtime.BaseAPI {
|
|
|
100
107
|
* Auto-generated: detachProductsProductCategory
|
|
101
108
|
*/
|
|
102
109
|
detachProductsProductCategory(requestParameters: DetachProductsProductCategoryOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ProductCategoryResource>;
|
|
110
|
+
/**
|
|
111
|
+
* Creates request options for getAllChildrenProductCategory without sending the request
|
|
112
|
+
*/
|
|
113
|
+
getAllChildrenProductCategoryRequestOpts(requestParameters: GetAllChildrenProductCategoryRequest): Promise<runtime.RequestOpts>;
|
|
114
|
+
/**
|
|
115
|
+
* Auto-generated: getAllChildrenProductCategory
|
|
116
|
+
*/
|
|
117
|
+
getAllChildrenProductCategoryRaw(requestParameters: GetAllChildrenProductCategoryRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ProductCategoryListResourceArrayResponse>>;
|
|
118
|
+
/**
|
|
119
|
+
* Auto-generated: getAllChildrenProductCategory
|
|
120
|
+
*/
|
|
121
|
+
getAllChildrenProductCategory(requestParameters: GetAllChildrenProductCategoryRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ProductCategoryListResourceArrayResponse>;
|
|
103
122
|
/**
|
|
104
123
|
* Creates request options for getAllProductCategory without sending the request
|
|
105
124
|
*/
|
|
@@ -127,15 +146,15 @@ export declare class ProductCategoryApi extends runtime.BaseAPI {
|
|
|
127
146
|
/**
|
|
128
147
|
* Creates request options for getHierarchyProductCategory without sending the request
|
|
129
148
|
*/
|
|
130
|
-
getHierarchyProductCategoryRequestOpts(): Promise<runtime.RequestOpts>;
|
|
149
|
+
getHierarchyProductCategoryRequestOpts(requestParameters: GetHierarchyProductCategoryOperationRequest): Promise<runtime.RequestOpts>;
|
|
131
150
|
/**
|
|
132
151
|
* Auto-generated: getHierarchyProductCategory
|
|
133
152
|
*/
|
|
134
|
-
getHierarchyProductCategoryRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ProductCategoryHierarchyResourceArrayResponse>>;
|
|
153
|
+
getHierarchyProductCategoryRaw(requestParameters: GetHierarchyProductCategoryOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ProductCategoryHierarchyResourceArrayResponse>>;
|
|
135
154
|
/**
|
|
136
155
|
* Auto-generated: getHierarchyProductCategory
|
|
137
156
|
*/
|
|
138
|
-
getHierarchyProductCategory(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ProductCategoryHierarchyResourceArrayResponse>;
|
|
157
|
+
getHierarchyProductCategory(requestParameters?: GetHierarchyProductCategoryOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ProductCategoryHierarchyResourceArrayResponse>;
|
|
139
158
|
/**
|
|
140
159
|
* Creates request options for indexProductCategory without sending the request
|
|
141
160
|
*/
|
|
@@ -315,6 +315,67 @@ var ProductCategoryApi = /** @class */ (function (_super) {
|
|
|
315
315
|
});
|
|
316
316
|
});
|
|
317
317
|
};
|
|
318
|
+
/**
|
|
319
|
+
* Creates request options for getAllChildrenProductCategory without sending the request
|
|
320
|
+
*/
|
|
321
|
+
ProductCategoryApi.prototype.getAllChildrenProductCategoryRequestOpts = function (requestParameters) {
|
|
322
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
323
|
+
var queryParameters, headerParameters, urlPath;
|
|
324
|
+
return __generator(this, function (_a) {
|
|
325
|
+
if (requestParameters['productCategory'] == null) {
|
|
326
|
+
throw new runtime.RequiredError('productCategory', 'Required parameter "productCategory" was null or undefined when calling getAllChildrenProductCategory().');
|
|
327
|
+
}
|
|
328
|
+
queryParameters = {};
|
|
329
|
+
headerParameters = {};
|
|
330
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
331
|
+
urlPath = "/admin-api/product-category/{productCategory}/children/all";
|
|
332
|
+
urlPath = urlPath.replace("{".concat("productCategory", "}"), encodeURIComponent(String(requestParameters['productCategory'])));
|
|
333
|
+
return [2 /*return*/, {
|
|
334
|
+
path: urlPath,
|
|
335
|
+
method: 'POST',
|
|
336
|
+
headers: headerParameters,
|
|
337
|
+
query: queryParameters,
|
|
338
|
+
body: (0, index_1.GetAllProductCategoryRequestToJSON)(requestParameters['getAllProductCategoryRequest']),
|
|
339
|
+
}];
|
|
340
|
+
});
|
|
341
|
+
});
|
|
342
|
+
};
|
|
343
|
+
/**
|
|
344
|
+
* Auto-generated: getAllChildrenProductCategory
|
|
345
|
+
*/
|
|
346
|
+
ProductCategoryApi.prototype.getAllChildrenProductCategoryRaw = function (requestParameters, initOverrides) {
|
|
347
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
348
|
+
var requestOptions, response;
|
|
349
|
+
return __generator(this, function (_a) {
|
|
350
|
+
switch (_a.label) {
|
|
351
|
+
case 0: return [4 /*yield*/, this.getAllChildrenProductCategoryRequestOpts(requestParameters)];
|
|
352
|
+
case 1:
|
|
353
|
+
requestOptions = _a.sent();
|
|
354
|
+
return [4 /*yield*/, this.request(requestOptions, initOverrides)];
|
|
355
|
+
case 2:
|
|
356
|
+
response = _a.sent();
|
|
357
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.ProductCategoryListResourceArrayResponseFromJSON)(jsonValue); })];
|
|
358
|
+
}
|
|
359
|
+
});
|
|
360
|
+
});
|
|
361
|
+
};
|
|
362
|
+
/**
|
|
363
|
+
* Auto-generated: getAllChildrenProductCategory
|
|
364
|
+
*/
|
|
365
|
+
ProductCategoryApi.prototype.getAllChildrenProductCategory = function (requestParameters, initOverrides) {
|
|
366
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
367
|
+
var response;
|
|
368
|
+
return __generator(this, function (_a) {
|
|
369
|
+
switch (_a.label) {
|
|
370
|
+
case 0: return [4 /*yield*/, this.getAllChildrenProductCategoryRaw(requestParameters, initOverrides)];
|
|
371
|
+
case 1:
|
|
372
|
+
response = _a.sent();
|
|
373
|
+
return [4 /*yield*/, response.value()];
|
|
374
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
375
|
+
}
|
|
376
|
+
});
|
|
377
|
+
});
|
|
378
|
+
};
|
|
318
379
|
/**
|
|
319
380
|
* Creates request options for getAllProductCategory without sending the request
|
|
320
381
|
*/
|
|
@@ -437,18 +498,20 @@ var ProductCategoryApi = /** @class */ (function (_super) {
|
|
|
437
498
|
/**
|
|
438
499
|
* Creates request options for getHierarchyProductCategory without sending the request
|
|
439
500
|
*/
|
|
440
|
-
ProductCategoryApi.prototype.getHierarchyProductCategoryRequestOpts = function () {
|
|
501
|
+
ProductCategoryApi.prototype.getHierarchyProductCategoryRequestOpts = function (requestParameters) {
|
|
441
502
|
return __awaiter(this, void 0, void 0, function () {
|
|
442
503
|
var queryParameters, headerParameters, urlPath;
|
|
443
504
|
return __generator(this, function (_a) {
|
|
444
505
|
queryParameters = {};
|
|
445
506
|
headerParameters = {};
|
|
507
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
446
508
|
urlPath = "/admin-api/product-category/hierarchy";
|
|
447
509
|
return [2 /*return*/, {
|
|
448
510
|
path: urlPath,
|
|
449
|
-
method: '
|
|
511
|
+
method: 'POST',
|
|
450
512
|
headers: headerParameters,
|
|
451
513
|
query: queryParameters,
|
|
514
|
+
body: (0, index_1.GetHierarchyProductCategoryRequestToJSON)(requestParameters['getHierarchyProductCategoryRequest']),
|
|
452
515
|
}];
|
|
453
516
|
});
|
|
454
517
|
});
|
|
@@ -456,12 +519,12 @@ var ProductCategoryApi = /** @class */ (function (_super) {
|
|
|
456
519
|
/**
|
|
457
520
|
* Auto-generated: getHierarchyProductCategory
|
|
458
521
|
*/
|
|
459
|
-
ProductCategoryApi.prototype.getHierarchyProductCategoryRaw = function (initOverrides) {
|
|
522
|
+
ProductCategoryApi.prototype.getHierarchyProductCategoryRaw = function (requestParameters, initOverrides) {
|
|
460
523
|
return __awaiter(this, void 0, void 0, function () {
|
|
461
524
|
var requestOptions, response;
|
|
462
525
|
return __generator(this, function (_a) {
|
|
463
526
|
switch (_a.label) {
|
|
464
|
-
case 0: return [4 /*yield*/, this.getHierarchyProductCategoryRequestOpts()];
|
|
527
|
+
case 0: return [4 /*yield*/, this.getHierarchyProductCategoryRequestOpts(requestParameters)];
|
|
465
528
|
case 1:
|
|
466
529
|
requestOptions = _a.sent();
|
|
467
530
|
return [4 /*yield*/, this.request(requestOptions, initOverrides)];
|
|
@@ -475,12 +538,13 @@ var ProductCategoryApi = /** @class */ (function (_super) {
|
|
|
475
538
|
/**
|
|
476
539
|
* Auto-generated: getHierarchyProductCategory
|
|
477
540
|
*/
|
|
478
|
-
ProductCategoryApi.prototype.getHierarchyProductCategory = function (
|
|
479
|
-
return __awaiter(this,
|
|
541
|
+
ProductCategoryApi.prototype.getHierarchyProductCategory = function () {
|
|
542
|
+
return __awaiter(this, arguments, void 0, function (requestParameters, initOverrides) {
|
|
480
543
|
var response;
|
|
544
|
+
if (requestParameters === void 0) { requestParameters = {}; }
|
|
481
545
|
return __generator(this, function (_a) {
|
|
482
546
|
switch (_a.label) {
|
|
483
|
-
case 0: return [4 /*yield*/, this.getHierarchyProductCategoryRaw(initOverrides)];
|
|
547
|
+
case 0: return [4 /*yield*/, this.getHierarchyProductCategoryRaw(requestParameters, initOverrides)];
|
|
484
548
|
case 1:
|
|
485
549
|
response = _a.sent();
|
|
486
550
|
return [4 /*yield*/, response.value()];
|
|
@@ -35,10 +35,10 @@ export interface CategoryAutomationRuleResource {
|
|
|
35
35
|
comparisonType: object;
|
|
36
36
|
/**
|
|
37
37
|
*
|
|
38
|
-
* @type {
|
|
38
|
+
* @type {string}
|
|
39
39
|
* @memberof CategoryAutomationRuleResource
|
|
40
40
|
*/
|
|
41
|
-
groupId
|
|
41
|
+
groupId?: string | null;
|
|
42
42
|
/**
|
|
43
43
|
*
|
|
44
44
|
* @type {string}
|
|
@@ -56,7 +56,7 @@ export interface CategoryAutomationRuleResource {
|
|
|
56
56
|
* @type {string}
|
|
57
57
|
* @memberof CategoryAutomationRuleResource
|
|
58
58
|
*/
|
|
59
|
-
|
|
59
|
+
valueId?: string | null;
|
|
60
60
|
}
|
|
61
61
|
/**
|
|
62
62
|
* Check if a given object implements the CategoryAutomationRuleResource interface.
|
|
@@ -26,8 +26,6 @@ function instanceOfCategoryAutomationRuleResource(value) {
|
|
|
26
26
|
return false;
|
|
27
27
|
if (!('comparisonType' in value) || value['comparisonType'] === undefined)
|
|
28
28
|
return false;
|
|
29
|
-
if (!('groupId' in value) || value['groupId'] === undefined)
|
|
30
|
-
return false;
|
|
31
29
|
if (!('value' in value) || value['value'] === undefined)
|
|
32
30
|
return false;
|
|
33
31
|
return true;
|
|
@@ -43,10 +41,10 @@ function CategoryAutomationRuleResourceFromJSONTyped(json, ignoreDiscriminator)
|
|
|
43
41
|
'id': json['id'] == null ? undefined : json['id'],
|
|
44
42
|
'fieldType': json['fieldType'],
|
|
45
43
|
'comparisonType': json['comparisonType'],
|
|
46
|
-
'groupId': json['groupId'],
|
|
44
|
+
'groupId': json['groupId'] == null ? undefined : json['groupId'],
|
|
47
45
|
'relatedId': json['relatedId'] == null ? undefined : json['relatedId'],
|
|
48
46
|
'value': json['value'],
|
|
49
|
-
'
|
|
47
|
+
'valueId': json['valueId'] == null ? undefined : json['valueId'],
|
|
50
48
|
};
|
|
51
49
|
}
|
|
52
50
|
function CategoryAutomationRuleResourceToJSON(json) {
|
|
@@ -64,6 +62,6 @@ function CategoryAutomationRuleResourceToJSONTyped(value, ignoreDiscriminator) {
|
|
|
64
62
|
'groupId': value['groupId'],
|
|
65
63
|
'relatedId': value['relatedId'],
|
|
66
64
|
'value': value['value'],
|
|
67
|
-
'
|
|
65
|
+
'valueId': value['valueId'],
|
|
68
66
|
};
|
|
69
67
|
}
|
|
@@ -87,6 +87,12 @@ export interface GetAllProductChildRequest {
|
|
|
87
87
|
* @memberof GetAllProductChildRequest
|
|
88
88
|
*/
|
|
89
89
|
productTypeId?: Array<string>;
|
|
90
|
+
/**
|
|
91
|
+
*
|
|
92
|
+
* @type {Array<string>}
|
|
93
|
+
* @memberof GetAllProductChildRequest
|
|
94
|
+
*/
|
|
95
|
+
parentIsAccessory?: Array<string>;
|
|
90
96
|
}
|
|
91
97
|
/**
|
|
92
98
|
* @export
|
|
@@ -78,6 +78,7 @@ function GetAllProductChildRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
78
78
|
'categoryId': json['category-id'] == null ? undefined : json['category-id'],
|
|
79
79
|
'supplierId': json['supplier-id'] == null ? undefined : json['supplier-id'],
|
|
80
80
|
'productTypeId': json['productType-id'] == null ? undefined : json['productType-id'],
|
|
81
|
+
'parentIsAccessory': json['parent-is_accessory'] == null ? undefined : json['parent-is_accessory'],
|
|
81
82
|
};
|
|
82
83
|
}
|
|
83
84
|
function GetAllProductChildRequestToJSON(json) {
|
|
@@ -101,5 +102,6 @@ function GetAllProductChildRequestToJSONTyped(value, ignoreDiscriminator) {
|
|
|
101
102
|
'category-id': value['categoryId'],
|
|
102
103
|
'supplier-id': value['supplierId'],
|
|
103
104
|
'productType-id': value['productTypeId'],
|
|
105
|
+
'parent-is_accessory': value['parentIsAccessory'],
|
|
104
106
|
};
|
|
105
107
|
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* My API
|
|
3
|
+
* API documentation for my Laravel app
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
*
|
|
14
|
+
* @export
|
|
15
|
+
* @interface GetHierarchyProductCategoryRequest
|
|
16
|
+
*/
|
|
17
|
+
export interface GetHierarchyProductCategoryRequest {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* @type {number}
|
|
21
|
+
* @memberof GetHierarchyProductCategoryRequest
|
|
22
|
+
*/
|
|
23
|
+
siteId: number;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Check if a given object implements the GetHierarchyProductCategoryRequest interface.
|
|
27
|
+
*/
|
|
28
|
+
export declare function instanceOfGetHierarchyProductCategoryRequest(value: object): value is GetHierarchyProductCategoryRequest;
|
|
29
|
+
export declare function GetHierarchyProductCategoryRequestFromJSON(json: any): GetHierarchyProductCategoryRequest;
|
|
30
|
+
export declare function GetHierarchyProductCategoryRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetHierarchyProductCategoryRequest;
|
|
31
|
+
export declare function GetHierarchyProductCategoryRequestToJSON(json: any): GetHierarchyProductCategoryRequest;
|
|
32
|
+
export declare function GetHierarchyProductCategoryRequestToJSONTyped(value?: GetHierarchyProductCategoryRequest | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* My API
|
|
6
|
+
* API documentation for my Laravel app
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0.0
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.instanceOfGetHierarchyProductCategoryRequest = instanceOfGetHierarchyProductCategoryRequest;
|
|
17
|
+
exports.GetHierarchyProductCategoryRequestFromJSON = GetHierarchyProductCategoryRequestFromJSON;
|
|
18
|
+
exports.GetHierarchyProductCategoryRequestFromJSONTyped = GetHierarchyProductCategoryRequestFromJSONTyped;
|
|
19
|
+
exports.GetHierarchyProductCategoryRequestToJSON = GetHierarchyProductCategoryRequestToJSON;
|
|
20
|
+
exports.GetHierarchyProductCategoryRequestToJSONTyped = GetHierarchyProductCategoryRequestToJSONTyped;
|
|
21
|
+
/**
|
|
22
|
+
* Check if a given object implements the GetHierarchyProductCategoryRequest interface.
|
|
23
|
+
*/
|
|
24
|
+
function instanceOfGetHierarchyProductCategoryRequest(value) {
|
|
25
|
+
if (!('siteId' in value) || value['siteId'] === undefined)
|
|
26
|
+
return false;
|
|
27
|
+
return true;
|
|
28
|
+
}
|
|
29
|
+
function GetHierarchyProductCategoryRequestFromJSON(json) {
|
|
30
|
+
return GetHierarchyProductCategoryRequestFromJSONTyped(json, false);
|
|
31
|
+
}
|
|
32
|
+
function GetHierarchyProductCategoryRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
33
|
+
if (json == null) {
|
|
34
|
+
return json;
|
|
35
|
+
}
|
|
36
|
+
return {
|
|
37
|
+
'siteId': json['site_id'],
|
|
38
|
+
};
|
|
39
|
+
}
|
|
40
|
+
function GetHierarchyProductCategoryRequestToJSON(json) {
|
|
41
|
+
return GetHierarchyProductCategoryRequestToJSONTyped(json, false);
|
|
42
|
+
}
|
|
43
|
+
function GetHierarchyProductCategoryRequestToJSONTyped(value, ignoreDiscriminator) {
|
|
44
|
+
if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
|
|
45
|
+
if (value == null) {
|
|
46
|
+
return value;
|
|
47
|
+
}
|
|
48
|
+
return {
|
|
49
|
+
'site_id': value['siteId'],
|
|
50
|
+
};
|
|
51
|
+
}
|