@digital8/lighting-illusions-ts-sdk 0.0.484 → 0.0.485

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.
@@ -16,8 +16,7 @@ Name | Type
16
16
  `salePrice` | number
17
17
  `isDisabled` | boolean
18
18
  `seo` | [SEOResource](SEOResource.md)
19
- `omnisendId` | string
20
- `omnisendSyncStatus` | string
19
+ `documents` | object
21
20
 
22
21
  ## Example
23
22
 
@@ -36,8 +35,7 @@ const example = {
36
35
  "salePrice": null,
37
36
  "isDisabled": null,
38
37
  "seo": null,
39
- "omnisendId": null,
40
- "omnisendSyncStatus": null,
38
+ "documents": null,
41
39
  } satisfies ProductChildSiteDetailResource
42
40
 
43
41
  console.log(example)
@@ -1,20 +1,26 @@
1
1
 
2
- # ProductRating
2
+ # UpdateDocumentRequest
3
3
 
4
4
 
5
5
  ## Properties
6
6
 
7
7
  Name | Type
8
8
  ------------ | -------------
9
+ `name` | string
10
+ `documentFileId` | string
11
+ `siteIds` | Array<string>
9
12
 
10
13
  ## Example
11
14
 
12
15
  ```typescript
13
- import type { ProductRating } from '@digital8/lighting-illusions-ts-sdk'
16
+ import type { UpdateDocumentRequest } from '@digital8/lighting-illusions-ts-sdk'
14
17
 
15
18
  // TODO: Update the object below with actual values
16
19
  const example = {
17
- } satisfies ProductRating
20
+ "name": null,
21
+ "documentFileId": null,
22
+ "siteIds": null,
23
+ } satisfies UpdateDocumentRequest
18
24
 
19
25
  console.log(example)
20
26
 
@@ -23,7 +29,7 @@ const exampleJSON: string = JSON.stringify(example)
23
29
  console.log(exampleJSON)
24
30
 
25
31
  // Parse the JSON string back to an object
26
- const exampleParsed = JSON.parse(exampleJSON) as ProductRating
32
+ const exampleParsed = JSON.parse(exampleJSON) as UpdateDocumentRequest
27
33
  console.log(exampleParsed)
28
34
  ```
29
35
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@digital8/lighting-illusions-ts-sdk",
3
- "version": "0.0.484",
3
+ "version": "0.0.485",
4
4
  "description": "OpenAPI client for @digital8/lighting-illusions-ts-sdk",
5
5
  "author": "OpenAPI-Generator",
6
6
  "repository": {
@@ -26,6 +26,7 @@ import type {
26
26
  PaginatedDocumentResourceResponse,
27
27
  StoreDocumentFileRequest,
28
28
  StoreDocumentRequest,
29
+ UpdateDocumentRequest,
29
30
  } from '../models/index';
30
31
  import {
31
32
  AttachDocumentablesDocumentRequestFromJSON,
@@ -50,6 +51,8 @@ import {
50
51
  StoreDocumentFileRequestToJSON,
51
52
  StoreDocumentRequestFromJSON,
52
53
  StoreDocumentRequestToJSON,
54
+ UpdateDocumentRequestFromJSON,
55
+ UpdateDocumentRequestToJSON,
53
56
  } from '../models/index';
54
57
 
55
58
  export interface AttachDocumentablesDocumentOperationRequest {
@@ -74,6 +77,10 @@ export interface IndexDocumentOperationRequest {
74
77
  indexDocumentRequest?: IndexDocumentRequest;
75
78
  }
76
79
 
80
+ export interface ShowDocumentRequest {
81
+ document: number;
82
+ }
83
+
77
84
  export interface StoreDocumentOperationRequest {
78
85
  storeDocumentRequest?: StoreDocumentRequest;
79
86
  }
@@ -82,6 +89,11 @@ export interface StoreDocumentFileOperationRequest {
82
89
  storeDocumentFileRequest?: StoreDocumentFileRequest;
83
90
  }
84
91
 
92
+ export interface UpdateDocumentOperationRequest {
93
+ document: number;
94
+ updateDocumentRequest?: UpdateDocumentRequest;
95
+ }
96
+
85
97
  /**
86
98
  *
87
99
  */
@@ -143,7 +155,7 @@ export class DocumentApi extends runtime.BaseAPI {
143
155
  const headerParameters: runtime.HTTPHeaders = {};
144
156
 
145
157
 
146
- let urlPath = `/admin-api/document/{document}`;
158
+ let urlPath = `/admin-api/document/{document}/delete`;
147
159
  urlPath = urlPath.replace(`{${"document"}}`, encodeURIComponent(String(requestParameters['document'])));
148
160
 
149
161
  const response = await this.request({
@@ -268,6 +280,43 @@ export class DocumentApi extends runtime.BaseAPI {
268
280
  return await response.value();
269
281
  }
270
282
 
283
+ /**
284
+ * Auto-generated: showDocument
285
+ */
286
+ async showDocumentRaw(requestParameters: ShowDocumentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<DocumentResource>> {
287
+ if (requestParameters['document'] == null) {
288
+ throw new runtime.RequiredError(
289
+ 'document',
290
+ 'Required parameter "document" was null or undefined when calling showDocument().'
291
+ );
292
+ }
293
+
294
+ const queryParameters: any = {};
295
+
296
+ const headerParameters: runtime.HTTPHeaders = {};
297
+
298
+
299
+ let urlPath = `/admin-api/document/{document}`;
300
+ urlPath = urlPath.replace(`{${"document"}}`, encodeURIComponent(String(requestParameters['document'])));
301
+
302
+ const response = await this.request({
303
+ path: urlPath,
304
+ method: 'GET',
305
+ headers: headerParameters,
306
+ query: queryParameters,
307
+ }, initOverrides);
308
+
309
+ return new runtime.JSONApiResponse(response, (jsonValue) => DocumentResourceFromJSON(jsonValue));
310
+ }
311
+
312
+ /**
313
+ * Auto-generated: showDocument
314
+ */
315
+ async showDocument(requestParameters: ShowDocumentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<DocumentResource> {
316
+ const response = await this.showDocumentRaw(requestParameters, initOverrides);
317
+ return await response.value();
318
+ }
319
+
271
320
  /**
272
321
  * Auto-generated: storeDocument
273
322
  */
@@ -279,7 +328,7 @@ export class DocumentApi extends runtime.BaseAPI {
279
328
  headerParameters['Content-Type'] = 'application/json';
280
329
 
281
330
 
282
- let urlPath = `/admin-api/document`;
331
+ let urlPath = `/admin-api/document/create`;
283
332
 
284
333
  const response = await this.request({
285
334
  path: urlPath,
@@ -332,4 +381,44 @@ export class DocumentApi extends runtime.BaseAPI {
332
381
  return await response.value();
333
382
  }
334
383
 
384
+ /**
385
+ * Auto-generated: updateDocument
386
+ */
387
+ async updateDocumentRaw(requestParameters: UpdateDocumentOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<DocumentResource>> {
388
+ if (requestParameters['document'] == null) {
389
+ throw new runtime.RequiredError(
390
+ 'document',
391
+ 'Required parameter "document" was null or undefined when calling updateDocument().'
392
+ );
393
+ }
394
+
395
+ const queryParameters: any = {};
396
+
397
+ const headerParameters: runtime.HTTPHeaders = {};
398
+
399
+ headerParameters['Content-Type'] = 'application/json';
400
+
401
+
402
+ let urlPath = `/admin-api/document/{document}/update`;
403
+ urlPath = urlPath.replace(`{${"document"}}`, encodeURIComponent(String(requestParameters['document'])));
404
+
405
+ const response = await this.request({
406
+ path: urlPath,
407
+ method: 'PUT',
408
+ headers: headerParameters,
409
+ query: queryParameters,
410
+ body: UpdateDocumentRequestToJSON(requestParameters['updateDocumentRequest']),
411
+ }, initOverrides);
412
+
413
+ return new runtime.JSONApiResponse(response, (jsonValue) => DocumentResourceFromJSON(jsonValue));
414
+ }
415
+
416
+ /**
417
+ * Auto-generated: updateDocument
418
+ */
419
+ async updateDocument(requestParameters: UpdateDocumentOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<DocumentResource> {
420
+ const response = await this.updateDocumentRaw(requestParameters, initOverrides);
421
+ return await response.value();
422
+ }
423
+
335
424
  }
@@ -85,12 +85,6 @@ export interface IndexExternalApiLogRequest {
85
85
  * @memberof IndexExternalApiLogRequest
86
86
  */
87
87
  siteId?: Array<string>;
88
- /**
89
- *
90
- * @type {Array<string>}
91
- * @memberof IndexExternalApiLogRequest
92
- */
93
- productChildId?: Array<string>;
94
88
  /**
95
89
  *
96
90
  * @type {number}
@@ -164,7 +158,6 @@ export function IndexExternalApiLogRequestFromJSONTyped(json: any, ignoreDiscrim
164
158
  'externalApiLoggableType': json['external_api_loggable_type'] == null ? undefined : json['external_api_loggable_type'],
165
159
  'externalApiLoggableId': json['external_api_loggable_id'] == null ? undefined : json['external_api_loggable_id'],
166
160
  'siteId': json['site_id'] == null ? undefined : json['site_id'],
167
- 'productChildId': json['product_child_id'] == null ? undefined : json['product_child_id'],
168
161
  'relatedId': json['related_id'] == null ? undefined : json['related_id'],
169
162
  'relatedType': json['related_type'] == null ? undefined : json['related_type'],
170
163
  'includesRelations': json['includes_relations'] == null ? undefined : json['includes_relations'],
@@ -193,7 +186,6 @@ export function IndexExternalApiLogRequestToJSONTyped(value?: IndexExternalApiLo
193
186
  'external_api_loggable_type': value['externalApiLoggableType'],
194
187
  'external_api_loggable_id': value['externalApiLoggableId'],
195
188
  'site_id': value['siteId'],
196
- 'product_child_id': value['productChildId'],
197
189
  'related_id': value['relatedId'],
198
190
  'related_type': value['relatedType'],
199
191
  'includes_relations': value['includesRelations'],
@@ -96,16 +96,10 @@ export interface ProductChildSiteDetailResource {
96
96
  seo: SEOResource | null;
97
97
  /**
98
98
  *
99
- * @type {string}
100
- * @memberof ProductChildSiteDetailResource
101
- */
102
- omnisendId?: string | null;
103
- /**
104
- *
105
- * @type {string}
99
+ * @type {object}
106
100
  * @memberof ProductChildSiteDetailResource
107
101
  */
108
- omnisendSyncStatus?: string | null;
102
+ documents: object;
109
103
  }
110
104
 
111
105
  /**
@@ -122,6 +116,7 @@ export function instanceOfProductChildSiteDetailResource(value: object): value i
122
116
  if (!('salePrice' in value) || value['salePrice'] === undefined) return false;
123
117
  if (!('isDisabled' in value) || value['isDisabled'] === undefined) return false;
124
118
  if (!('seo' in value) || value['seo'] === undefined) return false;
119
+ if (!('documents' in value) || value['documents'] === undefined) return false;
125
120
  return true;
126
121
  }
127
122
 
@@ -145,8 +140,7 @@ export function ProductChildSiteDetailResourceFromJSONTyped(json: any, ignoreDis
145
140
  'salePrice': json['salePrice'],
146
141
  'isDisabled': json['isDisabled'],
147
142
  'seo': SEOResourceFromJSON(json['seo']),
148
- 'omnisendId': json['omnisendId'] == null ? undefined : json['omnisendId'],
149
- 'omnisendSyncStatus': json['omnisendSyncStatus'] == null ? undefined : json['omnisendSyncStatus'],
143
+ 'documents': json['documents'],
150
144
  };
151
145
  }
152
146
 
@@ -171,8 +165,7 @@ export function ProductChildSiteDetailResourceToJSONTyped(value?: ProductChildSi
171
165
  'salePrice': value['salePrice'],
172
166
  'isDisabled': value['isDisabled'],
173
167
  'seo': SEOResourceToJSON(value['seo']),
174
- 'omnisendId': value['omnisendId'],
175
- 'omnisendSyncStatus': value['omnisendSyncStatus'],
168
+ 'documents': value['documents'],
176
169
  };
177
170
  }
178
171
 
@@ -0,0 +1,83 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * My API
5
+ * API documentation for my Laravel app
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ import { mapValues } from '../runtime';
16
+ /**
17
+ *
18
+ * @export
19
+ * @interface UpdateDocumentRequest
20
+ */
21
+ export interface UpdateDocumentRequest {
22
+ /**
23
+ *
24
+ * @type {string}
25
+ * @memberof UpdateDocumentRequest
26
+ */
27
+ name: string;
28
+ /**
29
+ *
30
+ * @type {string}
31
+ * @memberof UpdateDocumentRequest
32
+ */
33
+ documentFileId: string;
34
+ /**
35
+ *
36
+ * @type {Array<string>}
37
+ * @memberof UpdateDocumentRequest
38
+ */
39
+ siteIds?: Array<string>;
40
+ }
41
+
42
+ /**
43
+ * Check if a given object implements the UpdateDocumentRequest interface.
44
+ */
45
+ export function instanceOfUpdateDocumentRequest(value: object): value is UpdateDocumentRequest {
46
+ if (!('name' in value) || value['name'] === undefined) return false;
47
+ if (!('documentFileId' in value) || value['documentFileId'] === undefined) return false;
48
+ return true;
49
+ }
50
+
51
+ export function UpdateDocumentRequestFromJSON(json: any): UpdateDocumentRequest {
52
+ return UpdateDocumentRequestFromJSONTyped(json, false);
53
+ }
54
+
55
+ export function UpdateDocumentRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): UpdateDocumentRequest {
56
+ if (json == null) {
57
+ return json;
58
+ }
59
+ return {
60
+
61
+ 'name': json['name'],
62
+ 'documentFileId': json['document_file_id'],
63
+ 'siteIds': json['site_ids'] == null ? undefined : json['site_ids'],
64
+ };
65
+ }
66
+
67
+ export function UpdateDocumentRequestToJSON(json: any): UpdateDocumentRequest {
68
+ return UpdateDocumentRequestToJSONTyped(json, false);
69
+ }
70
+
71
+ export function UpdateDocumentRequestToJSONTyped(value?: UpdateDocumentRequest | null, ignoreDiscriminator: boolean = false): any {
72
+ if (value == null) {
73
+ return value;
74
+ }
75
+
76
+ return {
77
+
78
+ 'name': value['name'],
79
+ 'document_file_id': value['documentFileId'],
80
+ 'site_ids': value['siteIds'],
81
+ };
82
+ }
83
+
@@ -126,10 +126,8 @@ export * from './ProductListResource';
126
126
  export * from './ProductListResourceArrayResponse';
127
127
  export * from './ProductLiteResource';
128
128
  export * from './ProductLiteResourceArrayResponse';
129
- export * from './ProductRating';
130
129
  export * from './ProductResource';
131
130
  export * from './ProductResourceArrayResponse';
132
- export * from './ProductSortBy';
133
131
  export * from './ProductTypeListResource';
134
132
  export * from './ProductTypeListResourceArrayResponse';
135
133
  export * from './ProductTypeLiteResource';
@@ -187,6 +185,7 @@ export * from './TagResourceArrayResponse';
187
185
  export * from './TagType';
188
186
  export * from './UpdateAttributeRequest';
189
187
  export * from './UpdateAttributeValueRequest';
188
+ export * from './UpdateDocumentRequest';
190
189
  export * from './UpdateFilterOrderAttributeRequest';
191
190
  export * from './UpdateFilterOrderAttributeRequestValuesInner';
192
191
  export * from './UpdateModelAttributeRequest';
@@ -1,26 +0,0 @@
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
- */
16
- export declare const ProductRating: {
17
- readonly _5: "5";
18
- readonly _4: "4";
19
- readonly _3: "3";
20
- };
21
- export type ProductRating = typeof ProductRating[keyof typeof ProductRating];
22
- export declare function instanceOfProductRating(value: any): boolean;
23
- export declare function ProductRatingFromJSON(json: any): ProductRating;
24
- export declare function ProductRatingFromJSONTyped(json: any, ignoreDiscriminator: boolean): ProductRating;
25
- export declare function ProductRatingToJSON(value?: ProductRating | null): any;
26
- export declare function ProductRatingToJSONTyped(value: any, ignoreDiscriminator: boolean): ProductRating;
@@ -1,52 +0,0 @@
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.ProductRating = void 0;
17
- exports.instanceOfProductRating = instanceOfProductRating;
18
- exports.ProductRatingFromJSON = ProductRatingFromJSON;
19
- exports.ProductRatingFromJSONTyped = ProductRatingFromJSONTyped;
20
- exports.ProductRatingToJSON = ProductRatingToJSON;
21
- exports.ProductRatingToJSONTyped = ProductRatingToJSONTyped;
22
- /**
23
- *
24
- * @export
25
- */
26
- exports.ProductRating = {
27
- _5: '5',
28
- _4: '4',
29
- _3: '3'
30
- };
31
- function instanceOfProductRating(value) {
32
- for (var key in exports.ProductRating) {
33
- if (Object.prototype.hasOwnProperty.call(exports.ProductRating, key)) {
34
- if (exports.ProductRating[key] === value) {
35
- return true;
36
- }
37
- }
38
- }
39
- return false;
40
- }
41
- function ProductRatingFromJSON(json) {
42
- return ProductRatingFromJSONTyped(json, false);
43
- }
44
- function ProductRatingFromJSONTyped(json, ignoreDiscriminator) {
45
- return json;
46
- }
47
- function ProductRatingToJSON(value) {
48
- return value;
49
- }
50
- function ProductRatingToJSONTyped(value, ignoreDiscriminator) {
51
- return value;
52
- }
@@ -1,32 +0,0 @@
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
- */
16
- export declare const ProductSortBy: {
17
- readonly Relevance: "relevance";
18
- readonly MostPopular: "mostPopular";
19
- readonly HighestRating: "highestRating";
20
- readonly LowestRating: "lowestRating";
21
- readonly DescendingPrice: "descendingPrice";
22
- readonly AscendingPrice: "ascendingPrice";
23
- readonly DescendingName: "descendingName";
24
- readonly AscendingName: "ascendingName";
25
- readonly RecentlyAdded: "recentlyAdded";
26
- };
27
- export type ProductSortBy = typeof ProductSortBy[keyof typeof ProductSortBy];
28
- export declare function instanceOfProductSortBy(value: any): boolean;
29
- export declare function ProductSortByFromJSON(json: any): ProductSortBy;
30
- export declare function ProductSortByFromJSONTyped(json: any, ignoreDiscriminator: boolean): ProductSortBy;
31
- export declare function ProductSortByToJSON(value?: ProductSortBy | null): any;
32
- export declare function ProductSortByToJSONTyped(value: any, ignoreDiscriminator: boolean): ProductSortBy;
@@ -1,58 +0,0 @@
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.ProductSortBy = void 0;
17
- exports.instanceOfProductSortBy = instanceOfProductSortBy;
18
- exports.ProductSortByFromJSON = ProductSortByFromJSON;
19
- exports.ProductSortByFromJSONTyped = ProductSortByFromJSONTyped;
20
- exports.ProductSortByToJSON = ProductSortByToJSON;
21
- exports.ProductSortByToJSONTyped = ProductSortByToJSONTyped;
22
- /**
23
- *
24
- * @export
25
- */
26
- exports.ProductSortBy = {
27
- Relevance: 'relevance',
28
- MostPopular: 'mostPopular',
29
- HighestRating: 'highestRating',
30
- LowestRating: 'lowestRating',
31
- DescendingPrice: 'descendingPrice',
32
- AscendingPrice: 'ascendingPrice',
33
- DescendingName: 'descendingName',
34
- AscendingName: 'ascendingName',
35
- RecentlyAdded: 'recentlyAdded'
36
- };
37
- function instanceOfProductSortBy(value) {
38
- for (var key in exports.ProductSortBy) {
39
- if (Object.prototype.hasOwnProperty.call(exports.ProductSortBy, key)) {
40
- if (exports.ProductSortBy[key] === value) {
41
- return true;
42
- }
43
- }
44
- }
45
- return false;
46
- }
47
- function ProductSortByFromJSON(json) {
48
- return ProductSortByFromJSONTyped(json, false);
49
- }
50
- function ProductSortByFromJSONTyped(json, ignoreDiscriminator) {
51
- return json;
52
- }
53
- function ProductSortByToJSON(value) {
54
- return value;
55
- }
56
- function ProductSortByToJSONTyped(value, ignoreDiscriminator) {
57
- return value;
58
- }
@@ -1,32 +0,0 @@
1
-
2
- # ProductSortBy
3
-
4
-
5
- ## Properties
6
-
7
- Name | Type
8
- ------------ | -------------
9
-
10
- ## Example
11
-
12
- ```typescript
13
- import type { ProductSortBy } from '@digital8/lighting-illusions-ts-sdk'
14
-
15
- // TODO: Update the object below with actual values
16
- const example = {
17
- } satisfies ProductSortBy
18
-
19
- console.log(example)
20
-
21
- // Convert the instance to a JSON string
22
- const exampleJSON: string = JSON.stringify(example)
23
- console.log(exampleJSON)
24
-
25
- // Parse the JSON string back to an object
26
- const exampleParsed = JSON.parse(exampleJSON) as ProductSortBy
27
- console.log(exampleParsed)
28
- ```
29
-
30
- [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
31
-
32
-
@@ -1,54 +0,0 @@
1
- /* tslint:disable */
2
- /* eslint-disable */
3
- /**
4
- * My API
5
- * API documentation for my Laravel app
6
- *
7
- * The version of the OpenAPI document: 1.0.0
8
- *
9
- *
10
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
- * https://openapi-generator.tech
12
- * Do not edit the class manually.
13
- */
14
-
15
-
16
- /**
17
- *
18
- * @export
19
- */
20
- export const ProductRating = {
21
- _5: '5',
22
- _4: '4',
23
- _3: '3'
24
- } as const;
25
- export type ProductRating = typeof ProductRating[keyof typeof ProductRating];
26
-
27
-
28
- export function instanceOfProductRating(value: any): boolean {
29
- for (const key in ProductRating) {
30
- if (Object.prototype.hasOwnProperty.call(ProductRating, key)) {
31
- if (ProductRating[key as keyof typeof ProductRating] === value) {
32
- return true;
33
- }
34
- }
35
- }
36
- return false;
37
- }
38
-
39
- export function ProductRatingFromJSON(json: any): ProductRating {
40
- return ProductRatingFromJSONTyped(json, false);
41
- }
42
-
43
- export function ProductRatingFromJSONTyped(json: any, ignoreDiscriminator: boolean): ProductRating {
44
- return json as ProductRating;
45
- }
46
-
47
- export function ProductRatingToJSON(value?: ProductRating | null): any {
48
- return value as any;
49
- }
50
-
51
- export function ProductRatingToJSONTyped(value: any, ignoreDiscriminator: boolean): ProductRating {
52
- return value as ProductRating;
53
- }
54
-