@digital8/lighting-illusions-ts-sdk 0.0.2502 → 0.0.2504
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 +15 -4
- package/README.md +2 -2
- package/dist/apis/CartsApi.d.ts +11 -0
- package/dist/apis/CartsApi.js +46 -0
- package/dist/apis/CouponsApi.d.ts +85 -0
- package/dist/apis/CouponsApi.js +355 -0
- package/dist/apis/OrdersApi.d.ts +11 -0
- package/dist/apis/OrdersApi.js +46 -0
- package/dist/apis/index.d.ts +1 -1
- package/dist/apis/index.js +1 -1
- 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 +3 -1
- package/dist/models/AdminOrderResource.d.ts +0 -6
- package/dist/models/AdminOrderResource.js +0 -4
- package/dist/models/AppliedCouponResource.d.ts +30 -0
- package/dist/models/AppliedCouponResource.js +20 -0
- package/dist/models/CartResource.d.ts +6 -0
- package/dist/models/CartResource.js +4 -0
- package/dist/models/CouponListResource.d.ts +99 -0
- package/dist/models/CouponListResource.js +91 -0
- package/dist/models/CouponListResourceArrayResponse.d.ts +33 -0
- package/dist/models/CouponListResourceArrayResponse.js +50 -0
- package/dist/models/CouponLiteResource.d.ts +44 -0
- package/dist/models/CouponLiteResource.js +57 -0
- package/dist/models/CouponLiteResourceArrayResponse.d.ts +33 -0
- package/dist/models/CouponLiteResourceArrayResponse.js +50 -0
- package/dist/models/CouponResource.d.ts +163 -0
- package/dist/models/CouponResource.js +135 -0
- package/dist/models/CouponResourceArrayResponse.d.ts +33 -0
- package/dist/models/CouponResourceArrayResponse.js +50 -0
- package/dist/models/CouponType.d.ts +26 -0
- package/dist/models/CouponType.js +52 -0
- package/dist/models/CreateCouponRequest.d.ts +126 -0
- package/dist/models/CreateCouponRequest.js +107 -0
- package/dist/models/CreateCouponRequestCouponablesInner.d.ts +48 -0
- package/dist/models/CreateCouponRequestCouponablesInner.js +61 -0
- package/dist/models/FrontendCartResource.d.ts +6 -0
- package/dist/models/FrontendCartResource.js +2 -0
- package/dist/models/FrontendOrderResource.d.ts +0 -6
- package/dist/models/FrontendOrderResource.js +0 -4
- package/dist/models/OrderFulfillmentResource.d.ts +1 -1
- package/dist/models/OrderFulfillmentResource.js +1 -3
- package/dist/models/PaginatedCouponListResourceResponse.d.ts +40 -0
- package/dist/models/PaginatedCouponListResourceResponse.js +57 -0
- package/dist/models/PaginatedCouponResourceResponse.d.ts +40 -0
- package/dist/models/PaginatedCouponResourceResponse.js +57 -0
- package/dist/models/PaymentTotalsResource.d.ts +0 -6
- package/dist/models/PaymentTotalsResource.js +0 -4
- package/dist/models/ProductCategoryLiteResource.d.ts +6 -0
- package/dist/models/ProductCategoryLiteResource.js +4 -0
- package/dist/models/ProductChildListResource.d.ts +6 -0
- package/dist/models/ProductChildListResource.js +4 -0
- package/dist/models/SearchAllCouponsRequest.d.ts +101 -0
- package/dist/models/SearchAllCouponsRequest.js +85 -0
- package/dist/models/SearchCartsRequest.d.ts +6 -0
- package/dist/models/SearchCartsRequest.js +2 -0
- package/dist/models/SearchCouponsRequest.d.ts +137 -0
- package/dist/models/SearchCouponsRequest.js +97 -0
- package/dist/models/SearchOrdersRequest.d.ts +6 -0
- package/dist/models/SearchOrdersRequest.js +2 -0
- package/dist/models/StoreFrontendResource.d.ts +1 -1
- package/dist/models/StoreFrontendResource.js +3 -1
- package/dist/models/StoreListResource.d.ts +2 -2
- package/dist/models/StoreListResource.js +2 -6
- package/dist/models/StoreResource.d.ts +1 -1
- package/dist/models/StoreResource.js +3 -1
- package/dist/models/UpdateCouponRequest.d.ts +120 -0
- package/dist/models/UpdateCouponRequest.js +103 -0
- package/dist/models/index.d.ts +14 -3
- package/dist/models/index.js +14 -3
- package/package.json +1 -1
- package/src/apis/CartsApi.ts +41 -0
- package/src/apis/CouponsApi.ts +286 -0
- package/src/apis/OrdersApi.ts +41 -0
- package/src/apis/index.ts +1 -1
- package/src/models/AddressFrontendResource.ts +4 -6
- package/src/models/AddressResource.ts +3 -2
- package/src/models/AdminOrderResource.ts +0 -9
- package/src/models/AppliedCouponResource.ts +45 -0
- package/src/models/CartResource.ts +9 -0
- package/src/models/CouponListResource.ts +170 -0
- package/src/models/CouponListResourceArrayResponse.ts +73 -0
- package/src/models/CouponLiteResource.ts +83 -0
- package/src/models/CouponLiteResourceArrayResponse.ts +73 -0
- package/src/models/CouponResource.ts +288 -0
- package/src/models/CouponResourceArrayResponse.ts +73 -0
- package/src/models/CouponType.ts +54 -0
- package/src/models/CreateCouponRequest.ts +207 -0
- package/src/models/CreateCouponRequestCouponablesInner.ts +86 -0
- package/src/models/FrontendCartResource.ts +8 -0
- package/src/models/FrontendOrderResource.ts +0 -9
- package/src/models/OrderFulfillmentResource.ts +2 -3
- package/src/models/PaginatedCouponListResourceResponse.ts +90 -0
- package/src/models/PaginatedCouponResourceResponse.ts +90 -0
- package/src/models/PaymentTotalsResource.ts +0 -9
- package/src/models/ProductCategoryLiteResource.ts +9 -0
- package/src/models/ProductChildListResource.ts +9 -0
- package/src/models/SearchAllCouponsRequest.ts +154 -0
- package/src/models/SearchCartsRequest.ts +8 -0
- package/src/models/SearchCouponsRequest.ts +202 -0
- package/src/models/SearchOrdersRequest.ts +8 -0
- package/src/models/StoreFrontendResource.ts +3 -2
- package/src/models/StoreListResource.ts +4 -6
- package/src/models/StoreResource.ts +3 -2
- package/src/models/UpdateCouponRequest.ts +198 -0
- package/src/models/index.ts +14 -3
- package/dist/apis/AuspostApi.d.ts +0 -29
- package/dist/apis/AuspostApi.js +0 -125
- package/dist/models/SuburbValidationResource.d.ts +0 -32
- package/dist/models/SuburbValidationResource.js +0 -51
- package/dist/models/SuburbValidationResourceArrayResponse.d.ts +0 -33
- package/dist/models/SuburbValidationResourceArrayResponse.js +0 -50
- package/dist/models/ValidateSuburbRequest.d.ts +0 -50
- package/dist/models/ValidateSuburbRequest.js +0 -63
- package/src/apis/AuspostApi.ts +0 -69
- package/src/models/SuburbValidationResource.ts +0 -66
- package/src/models/SuburbValidationResourceArrayResponse.ts +0 -73
- package/src/models/ValidateSuburbRequest.ts +0 -93
|
@@ -67,12 +67,6 @@ export interface PaymentTotalsResource {
|
|
|
67
67
|
* @memberof PaymentTotalsResource
|
|
68
68
|
*/
|
|
69
69
|
amountPaid: number;
|
|
70
|
-
/**
|
|
71
|
-
*
|
|
72
|
-
* @type {number}
|
|
73
|
-
* @memberof PaymentTotalsResource
|
|
74
|
-
*/
|
|
75
|
-
surchargePaid: number;
|
|
76
70
|
/**
|
|
77
71
|
*
|
|
78
72
|
* @type {number}
|
|
@@ -141,7 +135,6 @@ export function instanceOfPaymentTotalsResource(value: object): value is Payment
|
|
|
141
135
|
if (!('gstAmount' in value) || value['gstAmount'] === undefined) return false;
|
|
142
136
|
if (!('finalTotal' in value) || value['finalTotal'] === undefined) return false;
|
|
143
137
|
if (!('amountPaid' in value) || value['amountPaid'] === undefined) return false;
|
|
144
|
-
if (!('surchargePaid' in value) || value['surchargePaid'] === undefined) return false;
|
|
145
138
|
if (!('amountDue' in value) || value['amountDue'] === undefined) return false;
|
|
146
139
|
if (!('appliedCoupons' in value) || value['appliedCoupons'] === undefined) return false;
|
|
147
140
|
if (!('noOfItems' in value) || value['noOfItems'] === undefined) return false;
|
|
@@ -171,7 +164,6 @@ export function PaymentTotalsResourceFromJSONTyped(json: any, ignoreDiscriminato
|
|
|
171
164
|
'gstAmount': json['gstAmount'],
|
|
172
165
|
'finalTotal': json['finalTotal'],
|
|
173
166
|
'amountPaid': json['amountPaid'],
|
|
174
|
-
'surchargePaid': json['surchargePaid'],
|
|
175
167
|
'amountDue': json['amountDue'],
|
|
176
168
|
'appliedCoupons': json['appliedCoupons'],
|
|
177
169
|
'noOfItems': json['noOfItems'],
|
|
@@ -203,7 +195,6 @@ export function PaymentTotalsResourceToJSONTyped(value?: PaymentTotalsResource |
|
|
|
203
195
|
'gstAmount': value['gstAmount'],
|
|
204
196
|
'finalTotal': value['finalTotal'],
|
|
205
197
|
'amountPaid': value['amountPaid'],
|
|
206
|
-
'surchargePaid': value['surchargePaid'],
|
|
207
198
|
'amountDue': value['amountDue'],
|
|
208
199
|
'appliedCoupons': value['appliedCoupons'],
|
|
209
200
|
'noOfItems': value['noOfItems'],
|
|
@@ -43,6 +43,12 @@ export interface ProductCategoryLiteResource {
|
|
|
43
43
|
* @memberof ProductCategoryLiteResource
|
|
44
44
|
*/
|
|
45
45
|
isAutomated: boolean;
|
|
46
|
+
/**
|
|
47
|
+
*
|
|
48
|
+
* @type {boolean}
|
|
49
|
+
* @memberof ProductCategoryLiteResource
|
|
50
|
+
*/
|
|
51
|
+
isParent: boolean;
|
|
46
52
|
}
|
|
47
53
|
|
|
48
54
|
/**
|
|
@@ -52,6 +58,7 @@ export function instanceOfProductCategoryLiteResource(value: object): value is P
|
|
|
52
58
|
if (!('name' in value) || value['name'] === undefined) return false;
|
|
53
59
|
if (!('siteId' in value) || value['siteId'] === undefined) return false;
|
|
54
60
|
if (!('isAutomated' in value) || value['isAutomated'] === undefined) return false;
|
|
61
|
+
if (!('isParent' in value) || value['isParent'] === undefined) return false;
|
|
55
62
|
return true;
|
|
56
63
|
}
|
|
57
64
|
|
|
@@ -69,6 +76,7 @@ export function ProductCategoryLiteResourceFromJSONTyped(json: any, ignoreDiscri
|
|
|
69
76
|
'name': json['name'],
|
|
70
77
|
'siteId': json['siteId'],
|
|
71
78
|
'isAutomated': json['isAutomated'],
|
|
79
|
+
'isParent': json['isParent'],
|
|
72
80
|
};
|
|
73
81
|
}
|
|
74
82
|
|
|
@@ -87,6 +95,7 @@ export function ProductCategoryLiteResourceToJSONTyped(value?: ProductCategoryLi
|
|
|
87
95
|
'name': value['name'],
|
|
88
96
|
'siteId': value['siteId'],
|
|
89
97
|
'isAutomated': value['isAutomated'],
|
|
98
|
+
'isParent': value['isParent'],
|
|
90
99
|
};
|
|
91
100
|
}
|
|
92
101
|
|
|
@@ -58,6 +58,12 @@ export interface ProductChildListResource {
|
|
|
58
58
|
* @memberof ProductChildListResource
|
|
59
59
|
*/
|
|
60
60
|
name: string;
|
|
61
|
+
/**
|
|
62
|
+
*
|
|
63
|
+
* @type {string}
|
|
64
|
+
* @memberof ProductChildListResource
|
|
65
|
+
*/
|
|
66
|
+
fullName: string;
|
|
61
67
|
/**
|
|
62
68
|
*
|
|
63
69
|
* @type {string}
|
|
@@ -115,6 +121,7 @@ export function instanceOfProductChildListResource(value: object): value is Prod
|
|
|
115
121
|
if (!('id' in value) || value['id'] === undefined) return false;
|
|
116
122
|
if (!('sku' in value) || value['sku'] === undefined) return false;
|
|
117
123
|
if (!('name' in value) || value['name'] === undefined) return false;
|
|
124
|
+
if (!('fullName' in value) || value['fullName'] === undefined) return false;
|
|
118
125
|
if (!('model' in value) || value['model'] === undefined) return false;
|
|
119
126
|
if (!('stock' in value) || value['stock'] === undefined) return false;
|
|
120
127
|
if (!('displayInSocialFeed' in value) || value['displayInSocialFeed'] === undefined) return false;
|
|
@@ -138,6 +145,7 @@ export function ProductChildListResourceFromJSONTyped(json: any, ignoreDiscrimin
|
|
|
138
145
|
'parentId': json['parentId'] == null ? undefined : json['parentId'],
|
|
139
146
|
'sku': json['sku'],
|
|
140
147
|
'name': json['name'],
|
|
148
|
+
'fullName': json['fullName'],
|
|
141
149
|
'model': json['model'],
|
|
142
150
|
'stock': json['stock'],
|
|
143
151
|
'isDisabled': json['isDisabled'] == null ? undefined : json['isDisabled'],
|
|
@@ -164,6 +172,7 @@ export function ProductChildListResourceToJSONTyped(value?: ProductChildListReso
|
|
|
164
172
|
'parentId': value['parentId'],
|
|
165
173
|
'sku': value['sku'],
|
|
166
174
|
'name': value['name'],
|
|
175
|
+
'fullName': value['fullName'],
|
|
167
176
|
'model': value['model'],
|
|
168
177
|
'stock': value['stock'],
|
|
169
178
|
'isDisabled': value['isDisabled'],
|
|
@@ -0,0 +1,154 @@
|
|
|
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 SearchAllCouponsRequest
|
|
20
|
+
*/
|
|
21
|
+
export interface SearchAllCouponsRequest {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof SearchAllCouponsRequest
|
|
26
|
+
*/
|
|
27
|
+
search?: string | null;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {string}
|
|
31
|
+
* @memberof SearchAllCouponsRequest
|
|
32
|
+
*/
|
|
33
|
+
sortBy?: SearchAllCouponsRequestSortByEnum;
|
|
34
|
+
/**
|
|
35
|
+
*
|
|
36
|
+
* @type {string}
|
|
37
|
+
* @memberof SearchAllCouponsRequest
|
|
38
|
+
*/
|
|
39
|
+
sortDirection?: SearchAllCouponsRequestSortDirectionEnum;
|
|
40
|
+
/**
|
|
41
|
+
*
|
|
42
|
+
* @type {number}
|
|
43
|
+
* @memberof SearchAllCouponsRequest
|
|
44
|
+
*/
|
|
45
|
+
relatedId?: number;
|
|
46
|
+
/**
|
|
47
|
+
*
|
|
48
|
+
* @type {string}
|
|
49
|
+
* @memberof SearchAllCouponsRequest
|
|
50
|
+
*/
|
|
51
|
+
relatedType?: string;
|
|
52
|
+
/**
|
|
53
|
+
*
|
|
54
|
+
* @type {boolean}
|
|
55
|
+
* @memberof SearchAllCouponsRequest
|
|
56
|
+
*/
|
|
57
|
+
includesRelations?: boolean;
|
|
58
|
+
/**
|
|
59
|
+
*
|
|
60
|
+
* @type {Array<string>}
|
|
61
|
+
* @memberof SearchAllCouponsRequest
|
|
62
|
+
*/
|
|
63
|
+
type?: Array<string>;
|
|
64
|
+
/**
|
|
65
|
+
*
|
|
66
|
+
* @type {Array<string>}
|
|
67
|
+
* @memberof SearchAllCouponsRequest
|
|
68
|
+
*/
|
|
69
|
+
siteId?: Array<string>;
|
|
70
|
+
/**
|
|
71
|
+
*
|
|
72
|
+
* @type {Array<string>}
|
|
73
|
+
* @memberof SearchAllCouponsRequest
|
|
74
|
+
*/
|
|
75
|
+
isAbandonedCart?: Array<string>;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
|
|
79
|
+
/**
|
|
80
|
+
* @export
|
|
81
|
+
*/
|
|
82
|
+
export const SearchAllCouponsRequestSortByEnum = {
|
|
83
|
+
Id: 'id',
|
|
84
|
+
Name: 'name',
|
|
85
|
+
Code: 'code',
|
|
86
|
+
Type: 'type',
|
|
87
|
+
StartDate: 'start_date',
|
|
88
|
+
EndDate: 'end_date',
|
|
89
|
+
CreatedAt: 'created_at'
|
|
90
|
+
} as const;
|
|
91
|
+
export type SearchAllCouponsRequestSortByEnum = typeof SearchAllCouponsRequestSortByEnum[keyof typeof SearchAllCouponsRequestSortByEnum];
|
|
92
|
+
|
|
93
|
+
/**
|
|
94
|
+
* @export
|
|
95
|
+
*/
|
|
96
|
+
export const SearchAllCouponsRequestSortDirectionEnum = {
|
|
97
|
+
Asc: 'asc',
|
|
98
|
+
Desc: 'desc'
|
|
99
|
+
} as const;
|
|
100
|
+
export type SearchAllCouponsRequestSortDirectionEnum = typeof SearchAllCouponsRequestSortDirectionEnum[keyof typeof SearchAllCouponsRequestSortDirectionEnum];
|
|
101
|
+
|
|
102
|
+
|
|
103
|
+
/**
|
|
104
|
+
* Check if a given object implements the SearchAllCouponsRequest interface.
|
|
105
|
+
*/
|
|
106
|
+
export function instanceOfSearchAllCouponsRequest(value: object): value is SearchAllCouponsRequest {
|
|
107
|
+
return true;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
export function SearchAllCouponsRequestFromJSON(json: any): SearchAllCouponsRequest {
|
|
111
|
+
return SearchAllCouponsRequestFromJSONTyped(json, false);
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
export function SearchAllCouponsRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): SearchAllCouponsRequest {
|
|
115
|
+
if (json == null) {
|
|
116
|
+
return json;
|
|
117
|
+
}
|
|
118
|
+
return {
|
|
119
|
+
|
|
120
|
+
'search': json['search'] == null ? undefined : json['search'],
|
|
121
|
+
'sortBy': json['sortBy'] == null ? undefined : json['sortBy'],
|
|
122
|
+
'sortDirection': json['sortDirection'] == null ? undefined : json['sortDirection'],
|
|
123
|
+
'relatedId': json['related_id'] == null ? undefined : json['related_id'],
|
|
124
|
+
'relatedType': json['related_type'] == null ? undefined : json['related_type'],
|
|
125
|
+
'includesRelations': json['includes_relations'] == null ? undefined : json['includes_relations'],
|
|
126
|
+
'type': json['type'] == null ? undefined : json['type'],
|
|
127
|
+
'siteId': json['site_id'] == null ? undefined : json['site_id'],
|
|
128
|
+
'isAbandonedCart': json['is_abandoned_cart'] == null ? undefined : json['is_abandoned_cart'],
|
|
129
|
+
};
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
export function SearchAllCouponsRequestToJSON(json: any): SearchAllCouponsRequest {
|
|
133
|
+
return SearchAllCouponsRequestToJSONTyped(json, false);
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
export function SearchAllCouponsRequestToJSONTyped(value?: SearchAllCouponsRequest | null, ignoreDiscriminator: boolean = false): any {
|
|
137
|
+
if (value == null) {
|
|
138
|
+
return value;
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
return {
|
|
142
|
+
|
|
143
|
+
'search': value['search'],
|
|
144
|
+
'sortBy': value['sortBy'],
|
|
145
|
+
'sortDirection': value['sortDirection'],
|
|
146
|
+
'related_id': value['relatedId'],
|
|
147
|
+
'related_type': value['relatedType'],
|
|
148
|
+
'includes_relations': value['includesRelations'],
|
|
149
|
+
'type': value['type'],
|
|
150
|
+
'site_id': value['siteId'],
|
|
151
|
+
'is_abandoned_cart': value['isAbandonedCart'],
|
|
152
|
+
};
|
|
153
|
+
}
|
|
154
|
+
|
|
@@ -121,6 +121,12 @@ export interface SearchCartsRequest {
|
|
|
121
121
|
* @memberof SearchCartsRequest
|
|
122
122
|
*/
|
|
123
123
|
includesRelations?: boolean;
|
|
124
|
+
/**
|
|
125
|
+
*
|
|
126
|
+
* @type {number}
|
|
127
|
+
* @memberof SearchCartsRequest
|
|
128
|
+
*/
|
|
129
|
+
couponId?: number | null;
|
|
124
130
|
}
|
|
125
131
|
|
|
126
132
|
|
|
@@ -179,6 +185,7 @@ export function SearchCartsRequestFromJSONTyped(json: any, ignoreDiscriminator:
|
|
|
179
185
|
'relatedId': json['related_id'] == null ? undefined : json['related_id'],
|
|
180
186
|
'relatedType': json['related_type'] == null ? undefined : json['related_type'],
|
|
181
187
|
'includesRelations': json['includes_relations'] == null ? undefined : json['includes_relations'],
|
|
188
|
+
'couponId': json['coupon_id'] == null ? undefined : json['coupon_id'],
|
|
182
189
|
};
|
|
183
190
|
}
|
|
184
191
|
|
|
@@ -210,6 +217,7 @@ export function SearchCartsRequestToJSONTyped(value?: SearchCartsRequest | null,
|
|
|
210
217
|
'related_id': value['relatedId'],
|
|
211
218
|
'related_type': value['relatedType'],
|
|
212
219
|
'includes_relations': value['includesRelations'],
|
|
220
|
+
'coupon_id': value['couponId'],
|
|
213
221
|
};
|
|
214
222
|
}
|
|
215
223
|
|
|
@@ -0,0 +1,202 @@
|
|
|
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 SearchCouponsRequest
|
|
20
|
+
*/
|
|
21
|
+
export interface SearchCouponsRequest {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof SearchCouponsRequest
|
|
26
|
+
*/
|
|
27
|
+
search?: string | null;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {string}
|
|
31
|
+
* @memberof SearchCouponsRequest
|
|
32
|
+
*/
|
|
33
|
+
sortBy?: SearchCouponsRequestSortByEnum;
|
|
34
|
+
/**
|
|
35
|
+
*
|
|
36
|
+
* @type {string}
|
|
37
|
+
* @memberof SearchCouponsRequest
|
|
38
|
+
*/
|
|
39
|
+
sortDirection?: SearchCouponsRequestSortDirectionEnum;
|
|
40
|
+
/**
|
|
41
|
+
*
|
|
42
|
+
* @type {number}
|
|
43
|
+
* @memberof SearchCouponsRequest
|
|
44
|
+
*/
|
|
45
|
+
perPage?: number;
|
|
46
|
+
/**
|
|
47
|
+
*
|
|
48
|
+
* @type {number}
|
|
49
|
+
* @memberof SearchCouponsRequest
|
|
50
|
+
*/
|
|
51
|
+
page?: number;
|
|
52
|
+
/**
|
|
53
|
+
*
|
|
54
|
+
* @type {Array<string>}
|
|
55
|
+
* @memberof SearchCouponsRequest
|
|
56
|
+
*/
|
|
57
|
+
type?: Array<string>;
|
|
58
|
+
/**
|
|
59
|
+
*
|
|
60
|
+
* @type {Array<string>}
|
|
61
|
+
* @memberof SearchCouponsRequest
|
|
62
|
+
*/
|
|
63
|
+
siteId?: Array<string>;
|
|
64
|
+
/**
|
|
65
|
+
*
|
|
66
|
+
* @type {Array<string>}
|
|
67
|
+
* @memberof SearchCouponsRequest
|
|
68
|
+
*/
|
|
69
|
+
isAbandonedCart?: Array<string>;
|
|
70
|
+
/**
|
|
71
|
+
*
|
|
72
|
+
* @type {Date}
|
|
73
|
+
* @memberof SearchCouponsRequest
|
|
74
|
+
*/
|
|
75
|
+
beforeStartDate?: Date;
|
|
76
|
+
/**
|
|
77
|
+
*
|
|
78
|
+
* @type {Date}
|
|
79
|
+
* @memberof SearchCouponsRequest
|
|
80
|
+
*/
|
|
81
|
+
afterStartDate?: Date;
|
|
82
|
+
/**
|
|
83
|
+
*
|
|
84
|
+
* @type {Date}
|
|
85
|
+
* @memberof SearchCouponsRequest
|
|
86
|
+
*/
|
|
87
|
+
beforeEndDate?: Date;
|
|
88
|
+
/**
|
|
89
|
+
*
|
|
90
|
+
* @type {Date}
|
|
91
|
+
* @memberof SearchCouponsRequest
|
|
92
|
+
*/
|
|
93
|
+
afterEndDate?: Date;
|
|
94
|
+
/**
|
|
95
|
+
*
|
|
96
|
+
* @type {number}
|
|
97
|
+
* @memberof SearchCouponsRequest
|
|
98
|
+
*/
|
|
99
|
+
relatedId?: number;
|
|
100
|
+
/**
|
|
101
|
+
*
|
|
102
|
+
* @type {string}
|
|
103
|
+
* @memberof SearchCouponsRequest
|
|
104
|
+
*/
|
|
105
|
+
relatedType?: string;
|
|
106
|
+
/**
|
|
107
|
+
*
|
|
108
|
+
* @type {boolean}
|
|
109
|
+
* @memberof SearchCouponsRequest
|
|
110
|
+
*/
|
|
111
|
+
includesRelations?: boolean;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
|
|
115
|
+
/**
|
|
116
|
+
* @export
|
|
117
|
+
*/
|
|
118
|
+
export const SearchCouponsRequestSortByEnum = {
|
|
119
|
+
Id: 'id',
|
|
120
|
+
Name: 'name',
|
|
121
|
+
Code: 'code',
|
|
122
|
+
Type: 'type',
|
|
123
|
+
StartDate: 'start_date',
|
|
124
|
+
EndDate: 'end_date',
|
|
125
|
+
CreatedAt: 'created_at'
|
|
126
|
+
} as const;
|
|
127
|
+
export type SearchCouponsRequestSortByEnum = typeof SearchCouponsRequestSortByEnum[keyof typeof SearchCouponsRequestSortByEnum];
|
|
128
|
+
|
|
129
|
+
/**
|
|
130
|
+
* @export
|
|
131
|
+
*/
|
|
132
|
+
export const SearchCouponsRequestSortDirectionEnum = {
|
|
133
|
+
Asc: 'asc',
|
|
134
|
+
Desc: 'desc'
|
|
135
|
+
} as const;
|
|
136
|
+
export type SearchCouponsRequestSortDirectionEnum = typeof SearchCouponsRequestSortDirectionEnum[keyof typeof SearchCouponsRequestSortDirectionEnum];
|
|
137
|
+
|
|
138
|
+
|
|
139
|
+
/**
|
|
140
|
+
* Check if a given object implements the SearchCouponsRequest interface.
|
|
141
|
+
*/
|
|
142
|
+
export function instanceOfSearchCouponsRequest(value: object): value is SearchCouponsRequest {
|
|
143
|
+
return true;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
export function SearchCouponsRequestFromJSON(json: any): SearchCouponsRequest {
|
|
147
|
+
return SearchCouponsRequestFromJSONTyped(json, false);
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
export function SearchCouponsRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): SearchCouponsRequest {
|
|
151
|
+
if (json == null) {
|
|
152
|
+
return json;
|
|
153
|
+
}
|
|
154
|
+
return {
|
|
155
|
+
|
|
156
|
+
'search': json['search'] == null ? undefined : json['search'],
|
|
157
|
+
'sortBy': json['sortBy'] == null ? undefined : json['sortBy'],
|
|
158
|
+
'sortDirection': json['sortDirection'] == null ? undefined : json['sortDirection'],
|
|
159
|
+
'perPage': json['per_page'] == null ? undefined : json['per_page'],
|
|
160
|
+
'page': json['page'] == null ? undefined : json['page'],
|
|
161
|
+
'type': json['type'] == null ? undefined : json['type'],
|
|
162
|
+
'siteId': json['site_id'] == null ? undefined : json['site_id'],
|
|
163
|
+
'isAbandonedCart': json['is_abandoned_cart'] == null ? undefined : json['is_abandoned_cart'],
|
|
164
|
+
'beforeStartDate': json['before_start_date'] == null ? undefined : (new Date(json['before_start_date'])),
|
|
165
|
+
'afterStartDate': json['after_start_date'] == null ? undefined : (new Date(json['after_start_date'])),
|
|
166
|
+
'beforeEndDate': json['before_end_date'] == null ? undefined : (new Date(json['before_end_date'])),
|
|
167
|
+
'afterEndDate': json['after_end_date'] == null ? undefined : (new Date(json['after_end_date'])),
|
|
168
|
+
'relatedId': json['related_id'] == null ? undefined : json['related_id'],
|
|
169
|
+
'relatedType': json['related_type'] == null ? undefined : json['related_type'],
|
|
170
|
+
'includesRelations': json['includes_relations'] == null ? undefined : json['includes_relations'],
|
|
171
|
+
};
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
export function SearchCouponsRequestToJSON(json: any): SearchCouponsRequest {
|
|
175
|
+
return SearchCouponsRequestToJSONTyped(json, false);
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
export function SearchCouponsRequestToJSONTyped(value?: SearchCouponsRequest | null, ignoreDiscriminator: boolean = false): any {
|
|
179
|
+
if (value == null) {
|
|
180
|
+
return value;
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
return {
|
|
184
|
+
|
|
185
|
+
'search': value['search'],
|
|
186
|
+
'sortBy': value['sortBy'],
|
|
187
|
+
'sortDirection': value['sortDirection'],
|
|
188
|
+
'per_page': value['perPage'],
|
|
189
|
+
'page': value['page'],
|
|
190
|
+
'type': value['type'],
|
|
191
|
+
'site_id': value['siteId'],
|
|
192
|
+
'is_abandoned_cart': value['isAbandonedCart'],
|
|
193
|
+
'before_start_date': value['beforeStartDate'] == null ? undefined : ((value['beforeStartDate']).toISOString()),
|
|
194
|
+
'after_start_date': value['afterStartDate'] == null ? undefined : ((value['afterStartDate']).toISOString()),
|
|
195
|
+
'before_end_date': value['beforeEndDate'] == null ? undefined : ((value['beforeEndDate']).toISOString()),
|
|
196
|
+
'after_end_date': value['afterEndDate'] == null ? undefined : ((value['afterEndDate']).toISOString()),
|
|
197
|
+
'related_id': value['relatedId'],
|
|
198
|
+
'related_type': value['relatedType'],
|
|
199
|
+
'includes_relations': value['includesRelations'],
|
|
200
|
+
};
|
|
201
|
+
}
|
|
202
|
+
|
|
@@ -133,6 +133,12 @@ export interface SearchOrdersRequest {
|
|
|
133
133
|
* @memberof SearchOrdersRequest
|
|
134
134
|
*/
|
|
135
135
|
includesRelations?: boolean;
|
|
136
|
+
/**
|
|
137
|
+
*
|
|
138
|
+
* @type {number}
|
|
139
|
+
* @memberof SearchOrdersRequest
|
|
140
|
+
*/
|
|
141
|
+
couponId?: number | null;
|
|
136
142
|
}
|
|
137
143
|
|
|
138
144
|
|
|
@@ -194,6 +200,7 @@ export function SearchOrdersRequestFromJSONTyped(json: any, ignoreDiscriminator:
|
|
|
194
200
|
'relatedId': json['related_id'] == null ? undefined : json['related_id'],
|
|
195
201
|
'relatedType': json['related_type'] == null ? undefined : json['related_type'],
|
|
196
202
|
'includesRelations': json['includes_relations'] == null ? undefined : json['includes_relations'],
|
|
203
|
+
'couponId': json['coupon_id'] == null ? undefined : json['coupon_id'],
|
|
197
204
|
};
|
|
198
205
|
}
|
|
199
206
|
|
|
@@ -227,6 +234,7 @@ export function SearchOrdersRequestToJSONTyped(value?: SearchOrdersRequest | nul
|
|
|
227
234
|
'related_id': value['relatedId'],
|
|
228
235
|
'related_type': value['relatedType'],
|
|
229
236
|
'includes_relations': value['includesRelations'],
|
|
237
|
+
'coupon_id': value['couponId'],
|
|
230
238
|
};
|
|
231
239
|
}
|
|
232
240
|
|
|
@@ -78,7 +78,7 @@ export interface StoreFrontendResource {
|
|
|
78
78
|
* @type {string}
|
|
79
79
|
* @memberof StoreFrontendResource
|
|
80
80
|
*/
|
|
81
|
-
tagLine
|
|
81
|
+
tagLine: string;
|
|
82
82
|
/**
|
|
83
83
|
*
|
|
84
84
|
* @type {string}
|
|
@@ -109,6 +109,7 @@ export function instanceOfStoreFrontendResource(value: object): value is StoreFr
|
|
|
109
109
|
if (!('phone' in value) || value['phone'] === undefined) return false;
|
|
110
110
|
if (!('latitude' in value) || value['latitude'] === undefined) return false;
|
|
111
111
|
if (!('longitude' in value) || value['longitude'] === undefined) return false;
|
|
112
|
+
if (!('tagLine' in value) || value['tagLine'] === undefined) return false;
|
|
112
113
|
if (!('specialDates' in value) || value['specialDates'] === undefined) return false;
|
|
113
114
|
if (!('suppliers' in value) || value['suppliers'] === undefined) return false;
|
|
114
115
|
return true;
|
|
@@ -133,7 +134,7 @@ export function StoreFrontendResourceFromJSONTyped(json: any, ignoreDiscriminato
|
|
|
133
134
|
'address': json['address'] == null ? undefined : json['address'],
|
|
134
135
|
'latitude': json['latitude'],
|
|
135
136
|
'longitude': json['longitude'],
|
|
136
|
-
'tagLine': json['tagLine']
|
|
137
|
+
'tagLine': json['tagLine'],
|
|
137
138
|
'openingHours': json['openingHours'] == null ? undefined : json['openingHours'],
|
|
138
139
|
'specialDates': json['specialDates'],
|
|
139
140
|
'suppliers': json['suppliers'],
|
|
@@ -68,7 +68,7 @@ export interface StoreListResource {
|
|
|
68
68
|
* @type {string}
|
|
69
69
|
* @memberof StoreListResource
|
|
70
70
|
*/
|
|
71
|
-
tagLine
|
|
71
|
+
tagLine?: string | null;
|
|
72
72
|
/**
|
|
73
73
|
*
|
|
74
74
|
* @type {string}
|
|
@@ -80,7 +80,7 @@ export interface StoreListResource {
|
|
|
80
80
|
* @type {string}
|
|
81
81
|
* @memberof StoreListResource
|
|
82
82
|
*/
|
|
83
|
-
website
|
|
83
|
+
website?: string | null;
|
|
84
84
|
/**
|
|
85
85
|
*
|
|
86
86
|
* @type {number}
|
|
@@ -110,9 +110,7 @@ export function instanceOfStoreListResource(value: object): value is StoreListRe
|
|
|
110
110
|
if (!('phone' in value) || value['phone'] === undefined) return false;
|
|
111
111
|
if (!('longitude' in value) || value['longitude'] === undefined) return false;
|
|
112
112
|
if (!('latitude' in value) || value['latitude'] === undefined) return false;
|
|
113
|
-
if (!('tagLine' in value) || value['tagLine'] === undefined) return false;
|
|
114
113
|
if (!('email' in value) || value['email'] === undefined) return false;
|
|
115
|
-
if (!('website' in value) || value['website'] === undefined) return false;
|
|
116
114
|
if (!('netsuiteId' in value) || value['netsuiteId'] === undefined) return false;
|
|
117
115
|
if (!('displayNetsuiteId' in value) || value['displayNetsuiteId'] === undefined) return false;
|
|
118
116
|
return true;
|
|
@@ -134,9 +132,9 @@ export function StoreListResourceFromJSONTyped(json: any, ignoreDiscriminator: b
|
|
|
134
132
|
'phone': json['phone'],
|
|
135
133
|
'longitude': json['longitude'],
|
|
136
134
|
'latitude': json['latitude'],
|
|
137
|
-
'tagLine': json['tagLine'],
|
|
135
|
+
'tagLine': json['tagLine'] == null ? undefined : json['tagLine'],
|
|
138
136
|
'email': json['email'],
|
|
139
|
-
'website': json['website'],
|
|
137
|
+
'website': json['website'] == null ? undefined : json['website'],
|
|
140
138
|
'netsuiteId': json['netsuiteId'],
|
|
141
139
|
'displayNetsuiteId': json['displayNetsuiteId'],
|
|
142
140
|
'openingHours': json['openingHours'] == null ? undefined : json['openingHours'],
|
|
@@ -89,7 +89,7 @@ export interface StoreResource {
|
|
|
89
89
|
* @type {string}
|
|
90
90
|
* @memberof StoreResource
|
|
91
91
|
*/
|
|
92
|
-
tagLine
|
|
92
|
+
tagLine: string;
|
|
93
93
|
/**
|
|
94
94
|
*
|
|
95
95
|
* @type {string}
|
|
@@ -149,6 +149,7 @@ export function instanceOfStoreResource(value: object): value is StoreResource {
|
|
|
149
149
|
if (!('phone' in value) || value['phone'] === undefined) return false;
|
|
150
150
|
if (!('longitude' in value) || value['longitude'] === undefined) return false;
|
|
151
151
|
if (!('latitude' in value) || value['latitude'] === undefined) return false;
|
|
152
|
+
if (!('tagLine' in value) || value['tagLine'] === undefined) return false;
|
|
152
153
|
if (!('email' in value) || value['email'] === undefined) return false;
|
|
153
154
|
if (!('website' in value) || value['website'] === undefined) return false;
|
|
154
155
|
if (!('netsuiteId' in value) || value['netsuiteId'] === undefined) return false;
|
|
@@ -175,7 +176,7 @@ export function StoreResourceFromJSONTyped(json: any, ignoreDiscriminator: boole
|
|
|
175
176
|
'phone': json['phone'],
|
|
176
177
|
'longitude': json['longitude'],
|
|
177
178
|
'latitude': json['latitude'],
|
|
178
|
-
'tagLine': json['tagLine']
|
|
179
|
+
'tagLine': json['tagLine'],
|
|
179
180
|
'email': json['email'],
|
|
180
181
|
'website': json['website'],
|
|
181
182
|
'netsuiteId': json['netsuiteId'],
|