@digital8/lighting-illusions-ts-sdk 0.0.2016 → 0.0.2018
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 +14 -0
- package/README.md +9 -2
- package/dist/models/AddressFrontendResource.d.ts +2 -2
- package/dist/models/AddressFrontendResource.js +2 -6
- package/dist/models/AddressResource.d.ts +1 -1
- package/dist/models/AddressResource.js +1 -3
- package/dist/models/CartCouponLiteResource.d.ts +56 -0
- package/dist/models/CartCouponLiteResource.js +67 -0
- package/dist/models/CartCouponLiteResourceArrayResponse.d.ts +33 -0
- package/dist/models/CartCouponLiteResourceArrayResponse.js +50 -0
- package/dist/models/ExternalApiLogResource.d.ts +1 -1
- package/dist/models/ExternalApiLogResource.js +1 -3
- package/dist/models/FrontendCartResource.d.ts +138 -0
- package/dist/models/FrontendCartResource.js +119 -0
- package/dist/models/FrontendCartResourceArrayResponse.d.ts +33 -0
- package/dist/models/FrontendCartResourceArrayResponse.js +50 -0
- package/dist/models/FrontendCartResourceCouponsInner.d.ts +56 -0
- package/dist/models/FrontendCartResourceCouponsInner.js +57 -0
- package/dist/models/FrontendLineItemResource.d.ts +75 -0
- package/dist/models/FrontendLineItemResource.js +78 -0
- package/dist/models/FrontendLineItemResourceArrayResponse.d.ts +33 -0
- package/dist/models/FrontendLineItemResourceArrayResponse.js +50 -0
- package/dist/models/ProductChildCartLiteResource.d.ts +18 -0
- package/dist/models/ProductChildCartLiteResource.js +12 -0
- package/dist/models/StoreListResource.d.ts +1 -1
- package/dist/models/StoreListResource.js +3 -1
- package/dist/models/StoreSpecialDateResource.d.ts +2 -2
- package/dist/models/StoreSpecialDateResource.js +3 -1
- package/dist/models/index.d.ts +7 -0
- package/dist/models/index.js +7 -0
- package/docs/CartCouponLiteResource.md +42 -0
- package/docs/CartCouponLiteResourceArrayResponse.md +34 -0
- package/docs/FrontendCartResource.md +68 -0
- package/docs/FrontendCartResourceArrayResponse.md +34 -0
- package/docs/FrontendCartResourceCouponsInner.md +42 -0
- package/docs/FrontendLineItemResource.md +48 -0
- package/docs/FrontendLineItemResourceArrayResponse.md +34 -0
- package/docs/ProductChildCartLiteResource.md +6 -0
- package/docs/StoreSpecialDateResource.md +1 -1
- package/package.json +1 -1
- package/src/models/AddressFrontendResource.ts +4 -6
- package/src/models/AddressResource.ts +2 -3
- package/src/models/CartCouponLiteResource.ts +102 -0
- package/src/models/CartCouponLiteResourceArrayResponse.ts +73 -0
- package/src/models/ExternalApiLogResource.ts +2 -3
- package/src/models/FrontendCartResource.ts +246 -0
- package/src/models/FrontendCartResourceArrayResponse.ts +73 -0
- package/src/models/FrontendCartResourceCouponsInner.ts +97 -0
- package/src/models/FrontendLineItemResource.ts +136 -0
- package/src/models/FrontendLineItemResourceArrayResponse.ts +73 -0
- package/src/models/ProductChildCartLiteResource.ts +27 -0
- package/src/models/StoreListResource.ts +3 -2
- package/src/models/StoreSpecialDateResource.ts +4 -3
- package/src/models/index.ts +7 -0
|
@@ -0,0 +1,246 @@
|
|
|
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
|
+
import type { FrontendLineItemResource } from './FrontendLineItemResource';
|
|
17
|
+
import {
|
|
18
|
+
FrontendLineItemResourceFromJSON,
|
|
19
|
+
FrontendLineItemResourceFromJSONTyped,
|
|
20
|
+
FrontendLineItemResourceToJSON,
|
|
21
|
+
FrontendLineItemResourceToJSONTyped,
|
|
22
|
+
} from './FrontendLineItemResource';
|
|
23
|
+
import type { CustomerListResource } from './CustomerListResource';
|
|
24
|
+
import {
|
|
25
|
+
CustomerListResourceFromJSON,
|
|
26
|
+
CustomerListResourceFromJSONTyped,
|
|
27
|
+
CustomerListResourceToJSON,
|
|
28
|
+
CustomerListResourceToJSONTyped,
|
|
29
|
+
} from './CustomerListResource';
|
|
30
|
+
import type { FrontendCartResourceCouponsInner } from './FrontendCartResourceCouponsInner';
|
|
31
|
+
import {
|
|
32
|
+
FrontendCartResourceCouponsInnerFromJSON,
|
|
33
|
+
FrontendCartResourceCouponsInnerFromJSONTyped,
|
|
34
|
+
FrontendCartResourceCouponsInnerToJSON,
|
|
35
|
+
FrontendCartResourceCouponsInnerToJSONTyped,
|
|
36
|
+
} from './FrontendCartResourceCouponsInner';
|
|
37
|
+
import type { AddressResource } from './AddressResource';
|
|
38
|
+
import {
|
|
39
|
+
AddressResourceFromJSON,
|
|
40
|
+
AddressResourceFromJSONTyped,
|
|
41
|
+
AddressResourceToJSON,
|
|
42
|
+
AddressResourceToJSONTyped,
|
|
43
|
+
} from './AddressResource';
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
*
|
|
47
|
+
* @export
|
|
48
|
+
* @interface FrontendCartResource
|
|
49
|
+
*/
|
|
50
|
+
export interface FrontendCartResource {
|
|
51
|
+
/**
|
|
52
|
+
*
|
|
53
|
+
* @type {number}
|
|
54
|
+
* @memberof FrontendCartResource
|
|
55
|
+
*/
|
|
56
|
+
id?: number | null;
|
|
57
|
+
/**
|
|
58
|
+
*
|
|
59
|
+
* @type {string}
|
|
60
|
+
* @memberof FrontendCartResource
|
|
61
|
+
*/
|
|
62
|
+
lifecycleStatus: string;
|
|
63
|
+
/**
|
|
64
|
+
*
|
|
65
|
+
* @type {number}
|
|
66
|
+
* @memberof FrontendCartResource
|
|
67
|
+
*/
|
|
68
|
+
siteId: number;
|
|
69
|
+
/**
|
|
70
|
+
*
|
|
71
|
+
* @type {string}
|
|
72
|
+
* @memberof FrontendCartResource
|
|
73
|
+
*/
|
|
74
|
+
sessionToken?: string | null;
|
|
75
|
+
/**
|
|
76
|
+
*
|
|
77
|
+
* @type {CustomerListResource}
|
|
78
|
+
* @memberof FrontendCartResource
|
|
79
|
+
*/
|
|
80
|
+
customer: CustomerListResource | null;
|
|
81
|
+
/**
|
|
82
|
+
*
|
|
83
|
+
* @type {string}
|
|
84
|
+
* @memberof FrontendCartResource
|
|
85
|
+
*/
|
|
86
|
+
shippingType: string;
|
|
87
|
+
/**
|
|
88
|
+
*
|
|
89
|
+
* @type {AddressResource}
|
|
90
|
+
* @memberof FrontendCartResource
|
|
91
|
+
*/
|
|
92
|
+
shippingAddress: AddressResource | null;
|
|
93
|
+
/**
|
|
94
|
+
*
|
|
95
|
+
* @type {AddressResource}
|
|
96
|
+
* @memberof FrontendCartResource
|
|
97
|
+
*/
|
|
98
|
+
billingAddress: AddressResource | null;
|
|
99
|
+
/**
|
|
100
|
+
*
|
|
101
|
+
* @type {Array<FrontendLineItemResource>}
|
|
102
|
+
* @memberof FrontendCartResource
|
|
103
|
+
*/
|
|
104
|
+
lineItems: Array<FrontendLineItemResource> | null;
|
|
105
|
+
/**
|
|
106
|
+
*
|
|
107
|
+
* @type {Array<FrontendCartResourceCouponsInner>}
|
|
108
|
+
* @memberof FrontendCartResource
|
|
109
|
+
*/
|
|
110
|
+
coupons: Array<FrontendCartResourceCouponsInner>;
|
|
111
|
+
/**
|
|
112
|
+
*
|
|
113
|
+
* @type {number}
|
|
114
|
+
* @memberof FrontendCartResource
|
|
115
|
+
*/
|
|
116
|
+
subtotal: number;
|
|
117
|
+
/**
|
|
118
|
+
*
|
|
119
|
+
* @type {number}
|
|
120
|
+
* @memberof FrontendCartResource
|
|
121
|
+
*/
|
|
122
|
+
promotionalDiscount: number;
|
|
123
|
+
/**
|
|
124
|
+
*
|
|
125
|
+
* @type {number}
|
|
126
|
+
* @memberof FrontendCartResource
|
|
127
|
+
*/
|
|
128
|
+
couponSubtotalDiscount: number;
|
|
129
|
+
/**
|
|
130
|
+
*
|
|
131
|
+
* @type {number}
|
|
132
|
+
* @memberof FrontendCartResource
|
|
133
|
+
*/
|
|
134
|
+
couponShippingDiscount: number;
|
|
135
|
+
/**
|
|
136
|
+
*
|
|
137
|
+
* @type {number}
|
|
138
|
+
* @memberof FrontendCartResource
|
|
139
|
+
*/
|
|
140
|
+
shipping: number;
|
|
141
|
+
/**
|
|
142
|
+
*
|
|
143
|
+
* @type {number}
|
|
144
|
+
* @memberof FrontendCartResource
|
|
145
|
+
*/
|
|
146
|
+
transitInsurance: number;
|
|
147
|
+
/**
|
|
148
|
+
*
|
|
149
|
+
* @type {number}
|
|
150
|
+
* @memberof FrontendCartResource
|
|
151
|
+
*/
|
|
152
|
+
gst: number;
|
|
153
|
+
/**
|
|
154
|
+
*
|
|
155
|
+
* @type {number}
|
|
156
|
+
* @memberof FrontendCartResource
|
|
157
|
+
*/
|
|
158
|
+
grandTotal: number;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
/**
|
|
162
|
+
* Check if a given object implements the FrontendCartResource interface.
|
|
163
|
+
*/
|
|
164
|
+
export function instanceOfFrontendCartResource(value: object): value is FrontendCartResource {
|
|
165
|
+
if (!('lifecycleStatus' in value) || value['lifecycleStatus'] === undefined) return false;
|
|
166
|
+
if (!('siteId' in value) || value['siteId'] === undefined) return false;
|
|
167
|
+
if (!('customer' in value) || value['customer'] === undefined) return false;
|
|
168
|
+
if (!('shippingType' in value) || value['shippingType'] === undefined) return false;
|
|
169
|
+
if (!('shippingAddress' in value) || value['shippingAddress'] === undefined) return false;
|
|
170
|
+
if (!('billingAddress' in value) || value['billingAddress'] === undefined) return false;
|
|
171
|
+
if (!('lineItems' in value) || value['lineItems'] === undefined) return false;
|
|
172
|
+
if (!('coupons' in value) || value['coupons'] === undefined) return false;
|
|
173
|
+
if (!('subtotal' in value) || value['subtotal'] === undefined) return false;
|
|
174
|
+
if (!('promotionalDiscount' in value) || value['promotionalDiscount'] === undefined) return false;
|
|
175
|
+
if (!('couponSubtotalDiscount' in value) || value['couponSubtotalDiscount'] === undefined) return false;
|
|
176
|
+
if (!('couponShippingDiscount' in value) || value['couponShippingDiscount'] === undefined) return false;
|
|
177
|
+
if (!('shipping' in value) || value['shipping'] === undefined) return false;
|
|
178
|
+
if (!('transitInsurance' in value) || value['transitInsurance'] === undefined) return false;
|
|
179
|
+
if (!('gst' in value) || value['gst'] === undefined) return false;
|
|
180
|
+
if (!('grandTotal' in value) || value['grandTotal'] === undefined) return false;
|
|
181
|
+
return true;
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
export function FrontendCartResourceFromJSON(json: any): FrontendCartResource {
|
|
185
|
+
return FrontendCartResourceFromJSONTyped(json, false);
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
export function FrontendCartResourceFromJSONTyped(json: any, ignoreDiscriminator: boolean): FrontendCartResource {
|
|
189
|
+
if (json == null) {
|
|
190
|
+
return json;
|
|
191
|
+
}
|
|
192
|
+
return {
|
|
193
|
+
|
|
194
|
+
'id': json['id'] == null ? undefined : json['id'],
|
|
195
|
+
'lifecycleStatus': json['lifecycleStatus'],
|
|
196
|
+
'siteId': json['siteId'],
|
|
197
|
+
'sessionToken': json['sessionToken'] == null ? undefined : json['sessionToken'],
|
|
198
|
+
'customer': CustomerListResourceFromJSON(json['customer']),
|
|
199
|
+
'shippingType': json['shippingType'],
|
|
200
|
+
'shippingAddress': AddressResourceFromJSON(json['shippingAddress']),
|
|
201
|
+
'billingAddress': AddressResourceFromJSON(json['billingAddress']),
|
|
202
|
+
'lineItems': (json['lineItems'] == null ? null : (json['lineItems'] as Array<any>).map(FrontendLineItemResourceFromJSON)),
|
|
203
|
+
'coupons': ((json['coupons'] as Array<any>).map(FrontendCartResourceCouponsInnerFromJSON)),
|
|
204
|
+
'subtotal': json['subtotal'],
|
|
205
|
+
'promotionalDiscount': json['promotionalDiscount'],
|
|
206
|
+
'couponSubtotalDiscount': json['couponSubtotalDiscount'],
|
|
207
|
+
'couponShippingDiscount': json['couponShippingDiscount'],
|
|
208
|
+
'shipping': json['shipping'],
|
|
209
|
+
'transitInsurance': json['transitInsurance'],
|
|
210
|
+
'gst': json['gst'],
|
|
211
|
+
'grandTotal': json['grandTotal'],
|
|
212
|
+
};
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
export function FrontendCartResourceToJSON(json: any): FrontendCartResource {
|
|
216
|
+
return FrontendCartResourceToJSONTyped(json, false);
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
export function FrontendCartResourceToJSONTyped(value?: FrontendCartResource | null, ignoreDiscriminator: boolean = false): any {
|
|
220
|
+
if (value == null) {
|
|
221
|
+
return value;
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
return {
|
|
225
|
+
|
|
226
|
+
'id': value['id'],
|
|
227
|
+
'lifecycleStatus': value['lifecycleStatus'],
|
|
228
|
+
'siteId': value['siteId'],
|
|
229
|
+
'sessionToken': value['sessionToken'],
|
|
230
|
+
'customer': CustomerListResourceToJSON(value['customer']),
|
|
231
|
+
'shippingType': value['shippingType'],
|
|
232
|
+
'shippingAddress': AddressResourceToJSON(value['shippingAddress']),
|
|
233
|
+
'billingAddress': AddressResourceToJSON(value['billingAddress']),
|
|
234
|
+
'lineItems': (value['lineItems'] == null ? null : (value['lineItems'] as Array<any>).map(FrontendLineItemResourceToJSON)),
|
|
235
|
+
'coupons': ((value['coupons'] as Array<any>).map(FrontendCartResourceCouponsInnerToJSON)),
|
|
236
|
+
'subtotal': value['subtotal'],
|
|
237
|
+
'promotionalDiscount': value['promotionalDiscount'],
|
|
238
|
+
'couponSubtotalDiscount': value['couponSubtotalDiscount'],
|
|
239
|
+
'couponShippingDiscount': value['couponShippingDiscount'],
|
|
240
|
+
'shipping': value['shipping'],
|
|
241
|
+
'transitInsurance': value['transitInsurance'],
|
|
242
|
+
'gst': value['gst'],
|
|
243
|
+
'grandTotal': value['grandTotal'],
|
|
244
|
+
};
|
|
245
|
+
}
|
|
246
|
+
|
|
@@ -0,0 +1,73 @@
|
|
|
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
|
+
import type { FrontendCartResource } from './FrontendCartResource';
|
|
17
|
+
import {
|
|
18
|
+
FrontendCartResourceFromJSON,
|
|
19
|
+
FrontendCartResourceFromJSONTyped,
|
|
20
|
+
FrontendCartResourceToJSON,
|
|
21
|
+
FrontendCartResourceToJSONTyped,
|
|
22
|
+
} from './FrontendCartResource';
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @export
|
|
27
|
+
* @interface FrontendCartResourceArrayResponse
|
|
28
|
+
*/
|
|
29
|
+
export interface FrontendCartResourceArrayResponse {
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
* @type {Array<FrontendCartResource>}
|
|
33
|
+
* @memberof FrontendCartResourceArrayResponse
|
|
34
|
+
*/
|
|
35
|
+
data?: Array<FrontendCartResource>;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* Check if a given object implements the FrontendCartResourceArrayResponse interface.
|
|
40
|
+
*/
|
|
41
|
+
export function instanceOfFrontendCartResourceArrayResponse(value: object): value is FrontendCartResourceArrayResponse {
|
|
42
|
+
return true;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export function FrontendCartResourceArrayResponseFromJSON(json: any): FrontendCartResourceArrayResponse {
|
|
46
|
+
return FrontendCartResourceArrayResponseFromJSONTyped(json, false);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export function FrontendCartResourceArrayResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): FrontendCartResourceArrayResponse {
|
|
50
|
+
if (json == null) {
|
|
51
|
+
return json;
|
|
52
|
+
}
|
|
53
|
+
return {
|
|
54
|
+
|
|
55
|
+
'data': json['data'] == null ? undefined : ((json['data'] as Array<any>).map(FrontendCartResourceFromJSON)),
|
|
56
|
+
};
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
export function FrontendCartResourceArrayResponseToJSON(json: any): FrontendCartResourceArrayResponse {
|
|
60
|
+
return FrontendCartResourceArrayResponseToJSONTyped(json, false);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
export function FrontendCartResourceArrayResponseToJSONTyped(value?: FrontendCartResourceArrayResponse | null, ignoreDiscriminator: boolean = false): any {
|
|
64
|
+
if (value == null) {
|
|
65
|
+
return value;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
return {
|
|
69
|
+
|
|
70
|
+
'data': value['data'] == null ? undefined : ((value['data'] as Array<any>).map(FrontendCartResourceToJSON)),
|
|
71
|
+
};
|
|
72
|
+
}
|
|
73
|
+
|
|
@@ -0,0 +1,97 @@
|
|
|
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 FrontendCartResourceCouponsInner
|
|
20
|
+
*/
|
|
21
|
+
export interface FrontendCartResourceCouponsInner {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {number}
|
|
25
|
+
* @memberof FrontendCartResourceCouponsInner
|
|
26
|
+
*/
|
|
27
|
+
id?: number;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {string}
|
|
31
|
+
* @memberof FrontendCartResourceCouponsInner
|
|
32
|
+
*/
|
|
33
|
+
code?: string;
|
|
34
|
+
/**
|
|
35
|
+
*
|
|
36
|
+
* @type {string}
|
|
37
|
+
* @memberof FrontendCartResourceCouponsInner
|
|
38
|
+
*/
|
|
39
|
+
name?: string;
|
|
40
|
+
/**
|
|
41
|
+
*
|
|
42
|
+
* @type {number}
|
|
43
|
+
* @memberof FrontendCartResourceCouponsInner
|
|
44
|
+
*/
|
|
45
|
+
discount?: number;
|
|
46
|
+
/**
|
|
47
|
+
*
|
|
48
|
+
* @type {string}
|
|
49
|
+
* @memberof FrontendCartResourceCouponsInner
|
|
50
|
+
*/
|
|
51
|
+
appliesTo?: string;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
/**
|
|
55
|
+
* Check if a given object implements the FrontendCartResourceCouponsInner interface.
|
|
56
|
+
*/
|
|
57
|
+
export function instanceOfFrontendCartResourceCouponsInner(value: object): value is FrontendCartResourceCouponsInner {
|
|
58
|
+
return true;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
export function FrontendCartResourceCouponsInnerFromJSON(json: any): FrontendCartResourceCouponsInner {
|
|
62
|
+
return FrontendCartResourceCouponsInnerFromJSONTyped(json, false);
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
export function FrontendCartResourceCouponsInnerFromJSONTyped(json: any, ignoreDiscriminator: boolean): FrontendCartResourceCouponsInner {
|
|
66
|
+
if (json == null) {
|
|
67
|
+
return json;
|
|
68
|
+
}
|
|
69
|
+
return {
|
|
70
|
+
|
|
71
|
+
'id': json['id'] == null ? undefined : json['id'],
|
|
72
|
+
'code': json['code'] == null ? undefined : json['code'],
|
|
73
|
+
'name': json['name'] == null ? undefined : json['name'],
|
|
74
|
+
'discount': json['discount'] == null ? undefined : json['discount'],
|
|
75
|
+
'appliesTo': json['appliesTo'] == null ? undefined : json['appliesTo'],
|
|
76
|
+
};
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
export function FrontendCartResourceCouponsInnerToJSON(json: any): FrontendCartResourceCouponsInner {
|
|
80
|
+
return FrontendCartResourceCouponsInnerToJSONTyped(json, false);
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
export function FrontendCartResourceCouponsInnerToJSONTyped(value?: FrontendCartResourceCouponsInner | null, ignoreDiscriminator: boolean = false): any {
|
|
84
|
+
if (value == null) {
|
|
85
|
+
return value;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
return {
|
|
89
|
+
|
|
90
|
+
'id': value['id'],
|
|
91
|
+
'code': value['code'],
|
|
92
|
+
'name': value['name'],
|
|
93
|
+
'discount': value['discount'],
|
|
94
|
+
'appliesTo': value['appliesTo'],
|
|
95
|
+
};
|
|
96
|
+
}
|
|
97
|
+
|
|
@@ -0,0 +1,136 @@
|
|
|
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
|
+
import type { ProductChildCartLiteResource } from './ProductChildCartLiteResource';
|
|
17
|
+
import {
|
|
18
|
+
ProductChildCartLiteResourceFromJSON,
|
|
19
|
+
ProductChildCartLiteResourceFromJSONTyped,
|
|
20
|
+
ProductChildCartLiteResourceToJSON,
|
|
21
|
+
ProductChildCartLiteResourceToJSONTyped,
|
|
22
|
+
} from './ProductChildCartLiteResource';
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @export
|
|
27
|
+
* @interface FrontendLineItemResource
|
|
28
|
+
*/
|
|
29
|
+
export interface FrontendLineItemResource {
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
* @type {number}
|
|
33
|
+
* @memberof FrontendLineItemResource
|
|
34
|
+
*/
|
|
35
|
+
id?: number | null;
|
|
36
|
+
/**
|
|
37
|
+
*
|
|
38
|
+
* @type {number}
|
|
39
|
+
* @memberof FrontendLineItemResource
|
|
40
|
+
*/
|
|
41
|
+
quantity: number;
|
|
42
|
+
/**
|
|
43
|
+
*
|
|
44
|
+
* @type {number}
|
|
45
|
+
* @memberof FrontendLineItemResource
|
|
46
|
+
*/
|
|
47
|
+
productPrice: number;
|
|
48
|
+
/**
|
|
49
|
+
*
|
|
50
|
+
* @type {number}
|
|
51
|
+
* @memberof FrontendLineItemResource
|
|
52
|
+
*/
|
|
53
|
+
subtotalAmount: number;
|
|
54
|
+
/**
|
|
55
|
+
*
|
|
56
|
+
* @type {number}
|
|
57
|
+
* @memberof FrontendLineItemResource
|
|
58
|
+
*/
|
|
59
|
+
totalAmount: number;
|
|
60
|
+
/**
|
|
61
|
+
*
|
|
62
|
+
* @type {boolean}
|
|
63
|
+
* @memberof FrontendLineItemResource
|
|
64
|
+
*/
|
|
65
|
+
isAvailable: boolean;
|
|
66
|
+
/**
|
|
67
|
+
*
|
|
68
|
+
* @type {boolean}
|
|
69
|
+
* @memberof FrontendLineItemResource
|
|
70
|
+
*/
|
|
71
|
+
isInStock: boolean;
|
|
72
|
+
/**
|
|
73
|
+
*
|
|
74
|
+
* @type {ProductChildCartLiteResource}
|
|
75
|
+
* @memberof FrontendLineItemResource
|
|
76
|
+
*/
|
|
77
|
+
productChild: ProductChildCartLiteResource | null;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
/**
|
|
81
|
+
* Check if a given object implements the FrontendLineItemResource interface.
|
|
82
|
+
*/
|
|
83
|
+
export function instanceOfFrontendLineItemResource(value: object): value is FrontendLineItemResource {
|
|
84
|
+
if (!('quantity' in value) || value['quantity'] === undefined) return false;
|
|
85
|
+
if (!('productPrice' in value) || value['productPrice'] === undefined) return false;
|
|
86
|
+
if (!('subtotalAmount' in value) || value['subtotalAmount'] === undefined) return false;
|
|
87
|
+
if (!('totalAmount' in value) || value['totalAmount'] === undefined) return false;
|
|
88
|
+
if (!('isAvailable' in value) || value['isAvailable'] === undefined) return false;
|
|
89
|
+
if (!('isInStock' in value) || value['isInStock'] === undefined) return false;
|
|
90
|
+
if (!('productChild' in value) || value['productChild'] === undefined) return false;
|
|
91
|
+
return true;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
export function FrontendLineItemResourceFromJSON(json: any): FrontendLineItemResource {
|
|
95
|
+
return FrontendLineItemResourceFromJSONTyped(json, false);
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
export function FrontendLineItemResourceFromJSONTyped(json: any, ignoreDiscriminator: boolean): FrontendLineItemResource {
|
|
99
|
+
if (json == null) {
|
|
100
|
+
return json;
|
|
101
|
+
}
|
|
102
|
+
return {
|
|
103
|
+
|
|
104
|
+
'id': json['id'] == null ? undefined : json['id'],
|
|
105
|
+
'quantity': json['quantity'],
|
|
106
|
+
'productPrice': json['productPrice'],
|
|
107
|
+
'subtotalAmount': json['subtotalAmount'],
|
|
108
|
+
'totalAmount': json['totalAmount'],
|
|
109
|
+
'isAvailable': json['isAvailable'],
|
|
110
|
+
'isInStock': json['isInStock'],
|
|
111
|
+
'productChild': ProductChildCartLiteResourceFromJSON(json['productChild']),
|
|
112
|
+
};
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
export function FrontendLineItemResourceToJSON(json: any): FrontendLineItemResource {
|
|
116
|
+
return FrontendLineItemResourceToJSONTyped(json, false);
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
export function FrontendLineItemResourceToJSONTyped(value?: FrontendLineItemResource | null, ignoreDiscriminator: boolean = false): any {
|
|
120
|
+
if (value == null) {
|
|
121
|
+
return value;
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
return {
|
|
125
|
+
|
|
126
|
+
'id': value['id'],
|
|
127
|
+
'quantity': value['quantity'],
|
|
128
|
+
'productPrice': value['productPrice'],
|
|
129
|
+
'subtotalAmount': value['subtotalAmount'],
|
|
130
|
+
'totalAmount': value['totalAmount'],
|
|
131
|
+
'isAvailable': value['isAvailable'],
|
|
132
|
+
'isInStock': value['isInStock'],
|
|
133
|
+
'productChild': ProductChildCartLiteResourceToJSON(value['productChild']),
|
|
134
|
+
};
|
|
135
|
+
}
|
|
136
|
+
|
|
@@ -0,0 +1,73 @@
|
|
|
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
|
+
import type { FrontendLineItemResource } from './FrontendLineItemResource';
|
|
17
|
+
import {
|
|
18
|
+
FrontendLineItemResourceFromJSON,
|
|
19
|
+
FrontendLineItemResourceFromJSONTyped,
|
|
20
|
+
FrontendLineItemResourceToJSON,
|
|
21
|
+
FrontendLineItemResourceToJSONTyped,
|
|
22
|
+
} from './FrontendLineItemResource';
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @export
|
|
27
|
+
* @interface FrontendLineItemResourceArrayResponse
|
|
28
|
+
*/
|
|
29
|
+
export interface FrontendLineItemResourceArrayResponse {
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
* @type {Array<FrontendLineItemResource>}
|
|
33
|
+
* @memberof FrontendLineItemResourceArrayResponse
|
|
34
|
+
*/
|
|
35
|
+
data?: Array<FrontendLineItemResource>;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* Check if a given object implements the FrontendLineItemResourceArrayResponse interface.
|
|
40
|
+
*/
|
|
41
|
+
export function instanceOfFrontendLineItemResourceArrayResponse(value: object): value is FrontendLineItemResourceArrayResponse {
|
|
42
|
+
return true;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export function FrontendLineItemResourceArrayResponseFromJSON(json: any): FrontendLineItemResourceArrayResponse {
|
|
46
|
+
return FrontendLineItemResourceArrayResponseFromJSONTyped(json, false);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export function FrontendLineItemResourceArrayResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): FrontendLineItemResourceArrayResponse {
|
|
50
|
+
if (json == null) {
|
|
51
|
+
return json;
|
|
52
|
+
}
|
|
53
|
+
return {
|
|
54
|
+
|
|
55
|
+
'data': json['data'] == null ? undefined : ((json['data'] as Array<any>).map(FrontendLineItemResourceFromJSON)),
|
|
56
|
+
};
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
export function FrontendLineItemResourceArrayResponseToJSON(json: any): FrontendLineItemResourceArrayResponse {
|
|
60
|
+
return FrontendLineItemResourceArrayResponseToJSONTyped(json, false);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
export function FrontendLineItemResourceArrayResponseToJSONTyped(value?: FrontendLineItemResourceArrayResponse | null, ignoreDiscriminator: boolean = false): any {
|
|
64
|
+
if (value == null) {
|
|
65
|
+
return value;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
return {
|
|
69
|
+
|
|
70
|
+
'data': value['data'] == null ? undefined : ((value['data'] as Array<any>).map(FrontendLineItemResourceToJSON)),
|
|
71
|
+
};
|
|
72
|
+
}
|
|
73
|
+
|
|
@@ -70,6 +70,24 @@ export interface ProductChildCartLiteResource {
|
|
|
70
70
|
* @memberof ProductChildCartLiteResource
|
|
71
71
|
*/
|
|
72
72
|
name: string;
|
|
73
|
+
/**
|
|
74
|
+
*
|
|
75
|
+
* @type {string}
|
|
76
|
+
* @memberof ProductChildCartLiteResource
|
|
77
|
+
*/
|
|
78
|
+
parentName: string;
|
|
79
|
+
/**
|
|
80
|
+
*
|
|
81
|
+
* @type {string}
|
|
82
|
+
* @memberof ProductChildCartLiteResource
|
|
83
|
+
*/
|
|
84
|
+
variantName: string;
|
|
85
|
+
/**
|
|
86
|
+
*
|
|
87
|
+
* @type {string}
|
|
88
|
+
* @memberof ProductChildCartLiteResource
|
|
89
|
+
*/
|
|
90
|
+
slug: string;
|
|
73
91
|
/**
|
|
74
92
|
*
|
|
75
93
|
* @type {number}
|
|
@@ -106,6 +124,9 @@ export function instanceOfProductChildCartLiteResource(value: object): value is
|
|
|
106
124
|
if (!('model' in value) || value['model'] === undefined) return false;
|
|
107
125
|
if (!('modelNumber' in value) || value['modelNumber'] === undefined) return false;
|
|
108
126
|
if (!('name' in value) || value['name'] === undefined) return false;
|
|
127
|
+
if (!('parentName' in value) || value['parentName'] === undefined) return false;
|
|
128
|
+
if (!('variantName' in value) || value['variantName'] === undefined) return false;
|
|
129
|
+
if (!('slug' in value) || value['slug'] === undefined) return false;
|
|
109
130
|
if (!('stock' in value) || value['stock'] === undefined) return false;
|
|
110
131
|
if (!('salePrice' in value) || value['salePrice'] === undefined) return false;
|
|
111
132
|
if (!('thumbnail' in value) || value['thumbnail'] === undefined) return false;
|
|
@@ -129,6 +150,9 @@ export function ProductChildCartLiteResourceFromJSONTyped(json: any, ignoreDiscr
|
|
|
129
150
|
'model': json['model'],
|
|
130
151
|
'modelNumber': json['modelNumber'],
|
|
131
152
|
'name': json['name'],
|
|
153
|
+
'parentName': json['parentName'],
|
|
154
|
+
'variantName': json['variantName'],
|
|
155
|
+
'slug': json['slug'],
|
|
132
156
|
'stock': json['stock'],
|
|
133
157
|
'salePrice': json['salePrice'],
|
|
134
158
|
'thumbnail': AssetLiteResourceFromJSON(json['thumbnail']),
|
|
@@ -153,6 +177,9 @@ export function ProductChildCartLiteResourceToJSONTyped(value?: ProductChildCart
|
|
|
153
177
|
'model': value['model'],
|
|
154
178
|
'modelNumber': value['modelNumber'],
|
|
155
179
|
'name': value['name'],
|
|
180
|
+
'parentName': value['parentName'],
|
|
181
|
+
'variantName': value['variantName'],
|
|
182
|
+
'slug': value['slug'],
|
|
156
183
|
'stock': value['stock'],
|
|
157
184
|
'salePrice': value['salePrice'],
|
|
158
185
|
'thumbnail': AssetLiteResourceToJSON(value['thumbnail']),
|