@digital8/lighting-illusions-ts-sdk 0.0.1122 → 0.0.1124
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 +40 -2
- package/README.md +39 -12
- package/dist/apis/StoreApi.d.ts +158 -0
- package/dist/apis/StoreApi.js +621 -0
- package/dist/apis/SupplierApi.d.ts +33 -1
- package/dist/apis/SupplierApi.js +122 -0
- package/dist/apis/index.d.ts +1 -1
- package/dist/apis/index.js +1 -1
- package/dist/models/AddressResource.d.ts +74 -0
- package/dist/models/AddressResource.js +79 -0
- package/dist/models/AddressResourceArrayResponse.d.ts +33 -0
- package/dist/models/AddressResourceArrayResponse.js +50 -0
- package/dist/models/AttachStoresSupplierRequest.d.ts +32 -0
- package/dist/models/AttachStoresSupplierRequest.js +51 -0
- package/dist/models/AttachSuppliersStoreRequest.d.ts +32 -0
- package/dist/models/AttachSuppliersStoreRequest.js +51 -0
- package/dist/models/DetachStoresSupplierRequest.d.ts +32 -0
- package/dist/models/DetachStoresSupplierRequest.js +51 -0
- package/dist/models/DetachSuppliersStoreRequest.d.ts +32 -0
- package/dist/models/DetachSuppliersStoreRequest.js +51 -0
- package/dist/models/ExternalApiLogResource.d.ts +1 -1
- package/dist/models/ExternalApiLogResource.js +3 -1
- package/dist/models/GetAllStoreRequest.d.ts +93 -0
- package/dist/models/GetAllStoreRequest.js +81 -0
- package/dist/models/StoreListResource.d.ts +93 -0
- package/dist/models/StoreListResource.js +84 -0
- package/dist/models/StoreListResourceArrayResponse.d.ts +33 -0
- package/dist/models/StoreListResourceArrayResponse.js +50 -0
- package/dist/models/StoreResource.d.ts +114 -0
- package/dist/models/StoreResource.js +97 -0
- package/dist/models/StoreResourceArrayResponse.d.ts +33 -0
- package/dist/models/StoreResourceArrayResponse.js +50 -0
- package/dist/models/StoreSpecialDateResource.d.ts +56 -0
- package/dist/models/StoreSpecialDateResource.js +65 -0
- package/dist/models/StoreSpecialDateResourceArrayResponse.d.ts +33 -0
- package/dist/models/StoreSpecialDateResourceArrayResponse.js +50 -0
- package/dist/models/StoreStoreRequest.d.ts +94 -0
- package/dist/models/StoreStoreRequest.js +85 -0
- package/dist/models/StoreStoreRequestAddress.d.ts +68 -0
- package/dist/models/StoreStoreRequestAddress.js +73 -0
- package/dist/models/StoreStoreRequestSpecialDatesInner.d.ts +50 -0
- package/dist/models/StoreStoreRequestSpecialDatesInner.js +57 -0
- package/dist/models/StoreStoreSpecialDateRequest.d.ts +50 -0
- package/dist/models/StoreStoreSpecialDateRequest.js +57 -0
- package/dist/models/SupplierResource.d.ts +6 -0
- package/dist/models/SupplierResource.js +4 -0
- package/dist/models/UpdateStoreRequest.d.ts +94 -0
- package/dist/models/UpdateStoreRequest.js +85 -0
- package/dist/models/UpdateStoreRequestSpecialDatesInner.d.ts +56 -0
- package/dist/models/UpdateStoreRequestSpecialDatesInner.js +57 -0
- package/dist/models/index.d.ts +19 -0
- package/dist/models/index.js +19 -0
- package/docs/AddressResource.md +48 -0
- package/docs/AddressResourceArrayResponse.md +34 -0
- package/docs/AttachStoresSupplierRequest.md +34 -0
- package/docs/AttachSuppliersStoreRequest.md +34 -0
- package/docs/DetachStoresSupplierRequest.md +34 -0
- package/docs/DetachSuppliersStoreRequest.md +34 -0
- package/docs/GetAllStoreRequest.md +48 -0
- package/docs/StoreApi.md +617 -0
- package/docs/StoreListResource.md +54 -0
- package/docs/StoreListResourceArrayResponse.md +34 -0
- package/docs/StoreResource.md +60 -0
- package/docs/StoreResourceArrayResponse.md +34 -0
- package/docs/StoreSpecialDateResource.md +42 -0
- package/docs/StoreSpecialDateResourceArrayResponse.md +34 -0
- package/docs/StoreStoreRequest.md +54 -0
- package/docs/StoreStoreRequestAddress.md +46 -0
- package/docs/StoreStoreRequestSpecialDatesInner.md +40 -0
- package/docs/StoreStoreSpecialDateRequest.md +40 -0
- package/docs/SupplierApi.md +138 -0
- package/docs/SupplierResource.md +2 -0
- package/docs/UpdateStoreRequest.md +54 -0
- package/docs/UpdateStoreRequestSpecialDatesInner.md +42 -0
- package/package.json +1 -1
- package/src/apis/StoreApi.ts +513 -0
- package/src/apis/SupplierApi.ts +112 -0
- package/src/apis/index.ts +1 -1
- package/src/models/AddressResource.ts +129 -0
- package/src/models/AddressResourceArrayResponse.ts +73 -0
- package/src/models/AttachStoresSupplierRequest.ts +66 -0
- package/src/models/AttachSuppliersStoreRequest.ts +66 -0
- package/src/models/DetachStoresSupplierRequest.ts +66 -0
- package/src/models/DetachSuppliersStoreRequest.ts +66 -0
- package/src/models/ExternalApiLogResource.ts +3 -2
- package/src/models/GetAllStoreRequest.ts +144 -0
- package/src/models/StoreListResource.ts +160 -0
- package/src/models/StoreListResourceArrayResponse.ts +73 -0
- package/src/models/StoreResource.ts +207 -0
- package/src/models/StoreResourceArrayResponse.ts +73 -0
- package/src/models/StoreSpecialDateResource.ts +101 -0
- package/src/models/StoreSpecialDateResourceArrayResponse.ts +73 -0
- package/src/models/StoreStoreRequest.ts +167 -0
- package/src/models/StoreStoreRequestAddress.ts +119 -0
- package/src/models/StoreStoreRequestSpecialDatesInner.ts +90 -0
- package/src/models/StoreStoreSpecialDateRequest.ts +90 -0
- package/src/models/SupplierResource.ts +9 -0
- package/src/models/UpdateStoreRequest.ts +167 -0
- package/src/models/UpdateStoreRequestSpecialDatesInner.ts +97 -0
- package/src/models/index.ts +19 -0
- package/dist/apis/AdminApi.d.ts +0 -63
- package/dist/apis/AdminApi.js +0 -254
- package/docs/AdminApi.md +0 -206
- package/src/apis/AdminApi.ts +0 -165
|
@@ -0,0 +1,621 @@
|
|
|
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
|
+
var __extends = (this && this.__extends) || (function () {
|
|
16
|
+
var extendStatics = function (d, b) {
|
|
17
|
+
extendStatics = Object.setPrototypeOf ||
|
|
18
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
19
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
20
|
+
return extendStatics(d, b);
|
|
21
|
+
};
|
|
22
|
+
return function (d, b) {
|
|
23
|
+
if (typeof b !== "function" && b !== null)
|
|
24
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
25
|
+
extendStatics(d, b);
|
|
26
|
+
function __() { this.constructor = d; }
|
|
27
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
28
|
+
};
|
|
29
|
+
})();
|
|
30
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
31
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
32
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
33
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
34
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
35
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
36
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
37
|
+
});
|
|
38
|
+
};
|
|
39
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
40
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
|
|
41
|
+
return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
42
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
43
|
+
function step(op) {
|
|
44
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
45
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
46
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
47
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
48
|
+
switch (op[0]) {
|
|
49
|
+
case 0: case 1: t = op; break;
|
|
50
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
51
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
52
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
53
|
+
default:
|
|
54
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
55
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
56
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
57
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
58
|
+
if (t[2]) _.ops.pop();
|
|
59
|
+
_.trys.pop(); continue;
|
|
60
|
+
}
|
|
61
|
+
op = body.call(thisArg, _);
|
|
62
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
63
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
64
|
+
}
|
|
65
|
+
};
|
|
66
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
67
|
+
exports.StoreApi = void 0;
|
|
68
|
+
var runtime = require("../runtime");
|
|
69
|
+
var index_1 = require("../models/index");
|
|
70
|
+
/**
|
|
71
|
+
*
|
|
72
|
+
*/
|
|
73
|
+
var StoreApi = /** @class */ (function (_super) {
|
|
74
|
+
__extends(StoreApi, _super);
|
|
75
|
+
function StoreApi() {
|
|
76
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* Creates request options for attachSuppliersStore without sending the request
|
|
80
|
+
*/
|
|
81
|
+
StoreApi.prototype.attachSuppliersStoreRequestOpts = function (requestParameters) {
|
|
82
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
83
|
+
var queryParameters, headerParameters, urlPath;
|
|
84
|
+
return __generator(this, function (_a) {
|
|
85
|
+
if (requestParameters['store'] == null) {
|
|
86
|
+
throw new runtime.RequiredError('store', 'Required parameter "store" was null or undefined when calling attachSuppliersStore().');
|
|
87
|
+
}
|
|
88
|
+
queryParameters = {};
|
|
89
|
+
headerParameters = {};
|
|
90
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
91
|
+
urlPath = "/admin-api/store/{store}/attach-suppliers";
|
|
92
|
+
urlPath = urlPath.replace("{".concat("store", "}"), encodeURIComponent(String(requestParameters['store'])));
|
|
93
|
+
return [2 /*return*/, {
|
|
94
|
+
path: urlPath,
|
|
95
|
+
method: 'POST',
|
|
96
|
+
headers: headerParameters,
|
|
97
|
+
query: queryParameters,
|
|
98
|
+
body: (0, index_1.AttachSuppliersStoreRequestToJSON)(requestParameters['attachSuppliersStoreRequest']),
|
|
99
|
+
}];
|
|
100
|
+
});
|
|
101
|
+
});
|
|
102
|
+
};
|
|
103
|
+
/**
|
|
104
|
+
* Auto-generated: attachSuppliersStore
|
|
105
|
+
*/
|
|
106
|
+
StoreApi.prototype.attachSuppliersStoreRaw = function (requestParameters, initOverrides) {
|
|
107
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
108
|
+
var requestOptions, response;
|
|
109
|
+
return __generator(this, function (_a) {
|
|
110
|
+
switch (_a.label) {
|
|
111
|
+
case 0: return [4 /*yield*/, this.attachSuppliersStoreRequestOpts(requestParameters)];
|
|
112
|
+
case 1:
|
|
113
|
+
requestOptions = _a.sent();
|
|
114
|
+
return [4 /*yield*/, this.request(requestOptions, initOverrides)];
|
|
115
|
+
case 2:
|
|
116
|
+
response = _a.sent();
|
|
117
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.StoreResourceFromJSON)(jsonValue); })];
|
|
118
|
+
}
|
|
119
|
+
});
|
|
120
|
+
});
|
|
121
|
+
};
|
|
122
|
+
/**
|
|
123
|
+
* Auto-generated: attachSuppliersStore
|
|
124
|
+
*/
|
|
125
|
+
StoreApi.prototype.attachSuppliersStore = function (requestParameters, initOverrides) {
|
|
126
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
127
|
+
var response;
|
|
128
|
+
return __generator(this, function (_a) {
|
|
129
|
+
switch (_a.label) {
|
|
130
|
+
case 0: return [4 /*yield*/, this.attachSuppliersStoreRaw(requestParameters, initOverrides)];
|
|
131
|
+
case 1:
|
|
132
|
+
response = _a.sent();
|
|
133
|
+
return [4 /*yield*/, response.value()];
|
|
134
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
135
|
+
}
|
|
136
|
+
});
|
|
137
|
+
});
|
|
138
|
+
};
|
|
139
|
+
/**
|
|
140
|
+
* Creates request options for destroyStore without sending the request
|
|
141
|
+
*/
|
|
142
|
+
StoreApi.prototype.destroyStoreRequestOpts = function (requestParameters) {
|
|
143
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
144
|
+
var queryParameters, headerParameters, urlPath;
|
|
145
|
+
return __generator(this, function (_a) {
|
|
146
|
+
if (requestParameters['store'] == null) {
|
|
147
|
+
throw new runtime.RequiredError('store', 'Required parameter "store" was null or undefined when calling destroyStore().');
|
|
148
|
+
}
|
|
149
|
+
queryParameters = {};
|
|
150
|
+
headerParameters = {};
|
|
151
|
+
urlPath = "/admin-api/store/{store}/delete";
|
|
152
|
+
urlPath = urlPath.replace("{".concat("store", "}"), encodeURIComponent(String(requestParameters['store'])));
|
|
153
|
+
return [2 /*return*/, {
|
|
154
|
+
path: urlPath,
|
|
155
|
+
method: 'DELETE',
|
|
156
|
+
headers: headerParameters,
|
|
157
|
+
query: queryParameters,
|
|
158
|
+
}];
|
|
159
|
+
});
|
|
160
|
+
});
|
|
161
|
+
};
|
|
162
|
+
/**
|
|
163
|
+
* Auto-generated: destroyStore
|
|
164
|
+
*/
|
|
165
|
+
StoreApi.prototype.destroyStoreRaw = function (requestParameters, initOverrides) {
|
|
166
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
167
|
+
var requestOptions, response;
|
|
168
|
+
return __generator(this, function (_a) {
|
|
169
|
+
switch (_a.label) {
|
|
170
|
+
case 0: return [4 /*yield*/, this.destroyStoreRequestOpts(requestParameters)];
|
|
171
|
+
case 1:
|
|
172
|
+
requestOptions = _a.sent();
|
|
173
|
+
return [4 /*yield*/, this.request(requestOptions, initOverrides)];
|
|
174
|
+
case 2:
|
|
175
|
+
response = _a.sent();
|
|
176
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.GenericResponseFromJSON)(jsonValue); })];
|
|
177
|
+
}
|
|
178
|
+
});
|
|
179
|
+
});
|
|
180
|
+
};
|
|
181
|
+
/**
|
|
182
|
+
* Auto-generated: destroyStore
|
|
183
|
+
*/
|
|
184
|
+
StoreApi.prototype.destroyStore = function (requestParameters, initOverrides) {
|
|
185
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
186
|
+
var response;
|
|
187
|
+
return __generator(this, function (_a) {
|
|
188
|
+
switch (_a.label) {
|
|
189
|
+
case 0: return [4 /*yield*/, this.destroyStoreRaw(requestParameters, initOverrides)];
|
|
190
|
+
case 1:
|
|
191
|
+
response = _a.sent();
|
|
192
|
+
return [4 /*yield*/, response.value()];
|
|
193
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
194
|
+
}
|
|
195
|
+
});
|
|
196
|
+
});
|
|
197
|
+
};
|
|
198
|
+
/**
|
|
199
|
+
* Creates request options for destroyStoreSpecialDate without sending the request
|
|
200
|
+
*/
|
|
201
|
+
StoreApi.prototype.destroyStoreSpecialDateRequestOpts = function (requestParameters) {
|
|
202
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
203
|
+
var queryParameters, headerParameters, urlPath;
|
|
204
|
+
return __generator(this, function (_a) {
|
|
205
|
+
if (requestParameters['store'] == null) {
|
|
206
|
+
throw new runtime.RequiredError('store', 'Required parameter "store" was null or undefined when calling destroyStoreSpecialDate().');
|
|
207
|
+
}
|
|
208
|
+
if (requestParameters['storeSpecialDate'] == null) {
|
|
209
|
+
throw new runtime.RequiredError('storeSpecialDate', 'Required parameter "storeSpecialDate" was null or undefined when calling destroyStoreSpecialDate().');
|
|
210
|
+
}
|
|
211
|
+
queryParameters = {};
|
|
212
|
+
headerParameters = {};
|
|
213
|
+
urlPath = "/admin-api/store/{store}/special-dates/{storeSpecialDate}";
|
|
214
|
+
urlPath = urlPath.replace("{".concat("store", "}"), encodeURIComponent(String(requestParameters['store'])));
|
|
215
|
+
urlPath = urlPath.replace("{".concat("storeSpecialDate", "}"), encodeURIComponent(String(requestParameters['storeSpecialDate'])));
|
|
216
|
+
return [2 /*return*/, {
|
|
217
|
+
path: urlPath,
|
|
218
|
+
method: 'DELETE',
|
|
219
|
+
headers: headerParameters,
|
|
220
|
+
query: queryParameters,
|
|
221
|
+
}];
|
|
222
|
+
});
|
|
223
|
+
});
|
|
224
|
+
};
|
|
225
|
+
/**
|
|
226
|
+
* Auto-generated: destroyStoreSpecialDate
|
|
227
|
+
*/
|
|
228
|
+
StoreApi.prototype.destroyStoreSpecialDateRaw = function (requestParameters, initOverrides) {
|
|
229
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
230
|
+
var requestOptions, response;
|
|
231
|
+
return __generator(this, function (_a) {
|
|
232
|
+
switch (_a.label) {
|
|
233
|
+
case 0: return [4 /*yield*/, this.destroyStoreSpecialDateRequestOpts(requestParameters)];
|
|
234
|
+
case 1:
|
|
235
|
+
requestOptions = _a.sent();
|
|
236
|
+
return [4 /*yield*/, this.request(requestOptions, initOverrides)];
|
|
237
|
+
case 2:
|
|
238
|
+
response = _a.sent();
|
|
239
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.GenericResponseFromJSON)(jsonValue); })];
|
|
240
|
+
}
|
|
241
|
+
});
|
|
242
|
+
});
|
|
243
|
+
};
|
|
244
|
+
/**
|
|
245
|
+
* Auto-generated: destroyStoreSpecialDate
|
|
246
|
+
*/
|
|
247
|
+
StoreApi.prototype.destroyStoreSpecialDate = function (requestParameters, initOverrides) {
|
|
248
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
249
|
+
var response;
|
|
250
|
+
return __generator(this, function (_a) {
|
|
251
|
+
switch (_a.label) {
|
|
252
|
+
case 0: return [4 /*yield*/, this.destroyStoreSpecialDateRaw(requestParameters, initOverrides)];
|
|
253
|
+
case 1:
|
|
254
|
+
response = _a.sent();
|
|
255
|
+
return [4 /*yield*/, response.value()];
|
|
256
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
257
|
+
}
|
|
258
|
+
});
|
|
259
|
+
});
|
|
260
|
+
};
|
|
261
|
+
/**
|
|
262
|
+
* Creates request options for detachSuppliersStore without sending the request
|
|
263
|
+
*/
|
|
264
|
+
StoreApi.prototype.detachSuppliersStoreRequestOpts = function (requestParameters) {
|
|
265
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
266
|
+
var queryParameters, headerParameters, urlPath;
|
|
267
|
+
return __generator(this, function (_a) {
|
|
268
|
+
if (requestParameters['store'] == null) {
|
|
269
|
+
throw new runtime.RequiredError('store', 'Required parameter "store" was null or undefined when calling detachSuppliersStore().');
|
|
270
|
+
}
|
|
271
|
+
queryParameters = {};
|
|
272
|
+
headerParameters = {};
|
|
273
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
274
|
+
urlPath = "/admin-api/store/{store}/detach-suppliers";
|
|
275
|
+
urlPath = urlPath.replace("{".concat("store", "}"), encodeURIComponent(String(requestParameters['store'])));
|
|
276
|
+
return [2 /*return*/, {
|
|
277
|
+
path: urlPath,
|
|
278
|
+
method: 'POST',
|
|
279
|
+
headers: headerParameters,
|
|
280
|
+
query: queryParameters,
|
|
281
|
+
body: (0, index_1.DetachSuppliersStoreRequestToJSON)(requestParameters['detachSuppliersStoreRequest']),
|
|
282
|
+
}];
|
|
283
|
+
});
|
|
284
|
+
});
|
|
285
|
+
};
|
|
286
|
+
/**
|
|
287
|
+
* Auto-generated: detachSuppliersStore
|
|
288
|
+
*/
|
|
289
|
+
StoreApi.prototype.detachSuppliersStoreRaw = function (requestParameters, initOverrides) {
|
|
290
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
291
|
+
var requestOptions, response;
|
|
292
|
+
return __generator(this, function (_a) {
|
|
293
|
+
switch (_a.label) {
|
|
294
|
+
case 0: return [4 /*yield*/, this.detachSuppliersStoreRequestOpts(requestParameters)];
|
|
295
|
+
case 1:
|
|
296
|
+
requestOptions = _a.sent();
|
|
297
|
+
return [4 /*yield*/, this.request(requestOptions, initOverrides)];
|
|
298
|
+
case 2:
|
|
299
|
+
response = _a.sent();
|
|
300
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.StoreResourceFromJSON)(jsonValue); })];
|
|
301
|
+
}
|
|
302
|
+
});
|
|
303
|
+
});
|
|
304
|
+
};
|
|
305
|
+
/**
|
|
306
|
+
* Auto-generated: detachSuppliersStore
|
|
307
|
+
*/
|
|
308
|
+
StoreApi.prototype.detachSuppliersStore = function (requestParameters, initOverrides) {
|
|
309
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
310
|
+
var response;
|
|
311
|
+
return __generator(this, function (_a) {
|
|
312
|
+
switch (_a.label) {
|
|
313
|
+
case 0: return [4 /*yield*/, this.detachSuppliersStoreRaw(requestParameters, initOverrides)];
|
|
314
|
+
case 1:
|
|
315
|
+
response = _a.sent();
|
|
316
|
+
return [4 /*yield*/, response.value()];
|
|
317
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
318
|
+
}
|
|
319
|
+
});
|
|
320
|
+
});
|
|
321
|
+
};
|
|
322
|
+
/**
|
|
323
|
+
* Creates request options for getAllStore without sending the request
|
|
324
|
+
*/
|
|
325
|
+
StoreApi.prototype.getAllStoreRequestOpts = function (requestParameters) {
|
|
326
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
327
|
+
var queryParameters, headerParameters, urlPath;
|
|
328
|
+
return __generator(this, function (_a) {
|
|
329
|
+
queryParameters = {};
|
|
330
|
+
headerParameters = {};
|
|
331
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
332
|
+
urlPath = "/admin-api/store/all";
|
|
333
|
+
return [2 /*return*/, {
|
|
334
|
+
path: urlPath,
|
|
335
|
+
method: 'POST',
|
|
336
|
+
headers: headerParameters,
|
|
337
|
+
query: queryParameters,
|
|
338
|
+
body: (0, index_1.GetAllStoreRequestToJSON)(requestParameters['getAllStoreRequest']),
|
|
339
|
+
}];
|
|
340
|
+
});
|
|
341
|
+
});
|
|
342
|
+
};
|
|
343
|
+
/**
|
|
344
|
+
* Auto-generated: getAllStore
|
|
345
|
+
*/
|
|
346
|
+
StoreApi.prototype.getAllStoreRaw = 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.getAllStoreRequestOpts(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.StoreListResourceArrayResponseFromJSON)(jsonValue); })];
|
|
358
|
+
}
|
|
359
|
+
});
|
|
360
|
+
});
|
|
361
|
+
};
|
|
362
|
+
/**
|
|
363
|
+
* Auto-generated: getAllStore
|
|
364
|
+
*/
|
|
365
|
+
StoreApi.prototype.getAllStore = function () {
|
|
366
|
+
return __awaiter(this, arguments, void 0, function (requestParameters, initOverrides) {
|
|
367
|
+
var response;
|
|
368
|
+
if (requestParameters === void 0) { requestParameters = {}; }
|
|
369
|
+
return __generator(this, function (_a) {
|
|
370
|
+
switch (_a.label) {
|
|
371
|
+
case 0: return [4 /*yield*/, this.getAllStoreRaw(requestParameters, initOverrides)];
|
|
372
|
+
case 1:
|
|
373
|
+
response = _a.sent();
|
|
374
|
+
return [4 /*yield*/, response.value()];
|
|
375
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
376
|
+
}
|
|
377
|
+
});
|
|
378
|
+
});
|
|
379
|
+
};
|
|
380
|
+
/**
|
|
381
|
+
* Creates request options for showStore without sending the request
|
|
382
|
+
*/
|
|
383
|
+
StoreApi.prototype.showStoreRequestOpts = function (requestParameters) {
|
|
384
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
385
|
+
var queryParameters, headerParameters, urlPath;
|
|
386
|
+
return __generator(this, function (_a) {
|
|
387
|
+
if (requestParameters['store'] == null) {
|
|
388
|
+
throw new runtime.RequiredError('store', 'Required parameter "store" was null or undefined when calling showStore().');
|
|
389
|
+
}
|
|
390
|
+
queryParameters = {};
|
|
391
|
+
headerParameters = {};
|
|
392
|
+
urlPath = "/admin-api/store/{store}";
|
|
393
|
+
urlPath = urlPath.replace("{".concat("store", "}"), encodeURIComponent(String(requestParameters['store'])));
|
|
394
|
+
return [2 /*return*/, {
|
|
395
|
+
path: urlPath,
|
|
396
|
+
method: 'GET',
|
|
397
|
+
headers: headerParameters,
|
|
398
|
+
query: queryParameters,
|
|
399
|
+
}];
|
|
400
|
+
});
|
|
401
|
+
});
|
|
402
|
+
};
|
|
403
|
+
/**
|
|
404
|
+
* Auto-generated: showStore
|
|
405
|
+
*/
|
|
406
|
+
StoreApi.prototype.showStoreRaw = function (requestParameters, initOverrides) {
|
|
407
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
408
|
+
var requestOptions, response;
|
|
409
|
+
return __generator(this, function (_a) {
|
|
410
|
+
switch (_a.label) {
|
|
411
|
+
case 0: return [4 /*yield*/, this.showStoreRequestOpts(requestParameters)];
|
|
412
|
+
case 1:
|
|
413
|
+
requestOptions = _a.sent();
|
|
414
|
+
return [4 /*yield*/, this.request(requestOptions, initOverrides)];
|
|
415
|
+
case 2:
|
|
416
|
+
response = _a.sent();
|
|
417
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.StoreResourceFromJSON)(jsonValue); })];
|
|
418
|
+
}
|
|
419
|
+
});
|
|
420
|
+
});
|
|
421
|
+
};
|
|
422
|
+
/**
|
|
423
|
+
* Auto-generated: showStore
|
|
424
|
+
*/
|
|
425
|
+
StoreApi.prototype.showStore = function (requestParameters, initOverrides) {
|
|
426
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
427
|
+
var response;
|
|
428
|
+
return __generator(this, function (_a) {
|
|
429
|
+
switch (_a.label) {
|
|
430
|
+
case 0: return [4 /*yield*/, this.showStoreRaw(requestParameters, initOverrides)];
|
|
431
|
+
case 1:
|
|
432
|
+
response = _a.sent();
|
|
433
|
+
return [4 /*yield*/, response.value()];
|
|
434
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
435
|
+
}
|
|
436
|
+
});
|
|
437
|
+
});
|
|
438
|
+
};
|
|
439
|
+
/**
|
|
440
|
+
* Creates request options for storeStore without sending the request
|
|
441
|
+
*/
|
|
442
|
+
StoreApi.prototype.storeStoreRequestOpts = function (requestParameters) {
|
|
443
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
444
|
+
var queryParameters, headerParameters, urlPath;
|
|
445
|
+
return __generator(this, function (_a) {
|
|
446
|
+
queryParameters = {};
|
|
447
|
+
headerParameters = {};
|
|
448
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
449
|
+
urlPath = "/admin-api/store/create";
|
|
450
|
+
return [2 /*return*/, {
|
|
451
|
+
path: urlPath,
|
|
452
|
+
method: 'POST',
|
|
453
|
+
headers: headerParameters,
|
|
454
|
+
query: queryParameters,
|
|
455
|
+
body: (0, index_1.StoreStoreRequestToJSON)(requestParameters['storeStoreRequest']),
|
|
456
|
+
}];
|
|
457
|
+
});
|
|
458
|
+
});
|
|
459
|
+
};
|
|
460
|
+
/**
|
|
461
|
+
* Auto-generated: storeStore
|
|
462
|
+
*/
|
|
463
|
+
StoreApi.prototype.storeStoreRaw = function (requestParameters, initOverrides) {
|
|
464
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
465
|
+
var requestOptions, response;
|
|
466
|
+
return __generator(this, function (_a) {
|
|
467
|
+
switch (_a.label) {
|
|
468
|
+
case 0: return [4 /*yield*/, this.storeStoreRequestOpts(requestParameters)];
|
|
469
|
+
case 1:
|
|
470
|
+
requestOptions = _a.sent();
|
|
471
|
+
return [4 /*yield*/, this.request(requestOptions, initOverrides)];
|
|
472
|
+
case 2:
|
|
473
|
+
response = _a.sent();
|
|
474
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.StoreResourceFromJSON)(jsonValue); })];
|
|
475
|
+
}
|
|
476
|
+
});
|
|
477
|
+
});
|
|
478
|
+
};
|
|
479
|
+
/**
|
|
480
|
+
* Auto-generated: storeStore
|
|
481
|
+
*/
|
|
482
|
+
StoreApi.prototype.storeStore = function () {
|
|
483
|
+
return __awaiter(this, arguments, void 0, function (requestParameters, initOverrides) {
|
|
484
|
+
var response;
|
|
485
|
+
if (requestParameters === void 0) { requestParameters = {}; }
|
|
486
|
+
return __generator(this, function (_a) {
|
|
487
|
+
switch (_a.label) {
|
|
488
|
+
case 0: return [4 /*yield*/, this.storeStoreRaw(requestParameters, initOverrides)];
|
|
489
|
+
case 1:
|
|
490
|
+
response = _a.sent();
|
|
491
|
+
return [4 /*yield*/, response.value()];
|
|
492
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
493
|
+
}
|
|
494
|
+
});
|
|
495
|
+
});
|
|
496
|
+
};
|
|
497
|
+
/**
|
|
498
|
+
* Creates request options for storeStoreSpecialDate without sending the request
|
|
499
|
+
*/
|
|
500
|
+
StoreApi.prototype.storeStoreSpecialDateRequestOpts = function (requestParameters) {
|
|
501
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
502
|
+
var queryParameters, headerParameters, urlPath;
|
|
503
|
+
return __generator(this, function (_a) {
|
|
504
|
+
if (requestParameters['store'] == null) {
|
|
505
|
+
throw new runtime.RequiredError('store', 'Required parameter "store" was null or undefined when calling storeStoreSpecialDate().');
|
|
506
|
+
}
|
|
507
|
+
queryParameters = {};
|
|
508
|
+
headerParameters = {};
|
|
509
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
510
|
+
urlPath = "/admin-api/store/{store}/special-dates";
|
|
511
|
+
urlPath = urlPath.replace("{".concat("store", "}"), encodeURIComponent(String(requestParameters['store'])));
|
|
512
|
+
return [2 /*return*/, {
|
|
513
|
+
path: urlPath,
|
|
514
|
+
method: 'POST',
|
|
515
|
+
headers: headerParameters,
|
|
516
|
+
query: queryParameters,
|
|
517
|
+
body: (0, index_1.StoreStoreSpecialDateRequestToJSON)(requestParameters['storeStoreSpecialDateRequest']),
|
|
518
|
+
}];
|
|
519
|
+
});
|
|
520
|
+
});
|
|
521
|
+
};
|
|
522
|
+
/**
|
|
523
|
+
* Auto-generated: storeStoreSpecialDate
|
|
524
|
+
*/
|
|
525
|
+
StoreApi.prototype.storeStoreSpecialDateRaw = function (requestParameters, initOverrides) {
|
|
526
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
527
|
+
var requestOptions, response;
|
|
528
|
+
return __generator(this, function (_a) {
|
|
529
|
+
switch (_a.label) {
|
|
530
|
+
case 0: return [4 /*yield*/, this.storeStoreSpecialDateRequestOpts(requestParameters)];
|
|
531
|
+
case 1:
|
|
532
|
+
requestOptions = _a.sent();
|
|
533
|
+
return [4 /*yield*/, this.request(requestOptions, initOverrides)];
|
|
534
|
+
case 2:
|
|
535
|
+
response = _a.sent();
|
|
536
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.StoreSpecialDateResourceFromJSON)(jsonValue); })];
|
|
537
|
+
}
|
|
538
|
+
});
|
|
539
|
+
});
|
|
540
|
+
};
|
|
541
|
+
/**
|
|
542
|
+
* Auto-generated: storeStoreSpecialDate
|
|
543
|
+
*/
|
|
544
|
+
StoreApi.prototype.storeStoreSpecialDate = function (requestParameters, initOverrides) {
|
|
545
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
546
|
+
var response;
|
|
547
|
+
return __generator(this, function (_a) {
|
|
548
|
+
switch (_a.label) {
|
|
549
|
+
case 0: return [4 /*yield*/, this.storeStoreSpecialDateRaw(requestParameters, initOverrides)];
|
|
550
|
+
case 1:
|
|
551
|
+
response = _a.sent();
|
|
552
|
+
return [4 /*yield*/, response.value()];
|
|
553
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
554
|
+
}
|
|
555
|
+
});
|
|
556
|
+
});
|
|
557
|
+
};
|
|
558
|
+
/**
|
|
559
|
+
* Creates request options for updateStore without sending the request
|
|
560
|
+
*/
|
|
561
|
+
StoreApi.prototype.updateStoreRequestOpts = function (requestParameters) {
|
|
562
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
563
|
+
var queryParameters, headerParameters, urlPath;
|
|
564
|
+
return __generator(this, function (_a) {
|
|
565
|
+
if (requestParameters['store'] == null) {
|
|
566
|
+
throw new runtime.RequiredError('store', 'Required parameter "store" was null or undefined when calling updateStore().');
|
|
567
|
+
}
|
|
568
|
+
queryParameters = {};
|
|
569
|
+
headerParameters = {};
|
|
570
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
571
|
+
urlPath = "/admin-api/store/{store}/update";
|
|
572
|
+
urlPath = urlPath.replace("{".concat("store", "}"), encodeURIComponent(String(requestParameters['store'])));
|
|
573
|
+
return [2 /*return*/, {
|
|
574
|
+
path: urlPath,
|
|
575
|
+
method: 'PUT',
|
|
576
|
+
headers: headerParameters,
|
|
577
|
+
query: queryParameters,
|
|
578
|
+
body: (0, index_1.UpdateStoreRequestToJSON)(requestParameters['updateStoreRequest']),
|
|
579
|
+
}];
|
|
580
|
+
});
|
|
581
|
+
});
|
|
582
|
+
};
|
|
583
|
+
/**
|
|
584
|
+
* Auto-generated: updateStore
|
|
585
|
+
*/
|
|
586
|
+
StoreApi.prototype.updateStoreRaw = function (requestParameters, initOverrides) {
|
|
587
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
588
|
+
var requestOptions, response;
|
|
589
|
+
return __generator(this, function (_a) {
|
|
590
|
+
switch (_a.label) {
|
|
591
|
+
case 0: return [4 /*yield*/, this.updateStoreRequestOpts(requestParameters)];
|
|
592
|
+
case 1:
|
|
593
|
+
requestOptions = _a.sent();
|
|
594
|
+
return [4 /*yield*/, this.request(requestOptions, initOverrides)];
|
|
595
|
+
case 2:
|
|
596
|
+
response = _a.sent();
|
|
597
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.StoreResourceFromJSON)(jsonValue); })];
|
|
598
|
+
}
|
|
599
|
+
});
|
|
600
|
+
});
|
|
601
|
+
};
|
|
602
|
+
/**
|
|
603
|
+
* Auto-generated: updateStore
|
|
604
|
+
*/
|
|
605
|
+
StoreApi.prototype.updateStore = function (requestParameters, initOverrides) {
|
|
606
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
607
|
+
var response;
|
|
608
|
+
return __generator(this, function (_a) {
|
|
609
|
+
switch (_a.label) {
|
|
610
|
+
case 0: return [4 /*yield*/, this.updateStoreRaw(requestParameters, initOverrides)];
|
|
611
|
+
case 1:
|
|
612
|
+
response = _a.sent();
|
|
613
|
+
return [4 /*yield*/, response.value()];
|
|
614
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
615
|
+
}
|
|
616
|
+
});
|
|
617
|
+
});
|
|
618
|
+
};
|
|
619
|
+
return StoreApi;
|
|
620
|
+
}(runtime.BaseAPI));
|
|
621
|
+
exports.StoreApi = StoreApi;
|
|
@@ -10,10 +10,18 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime';
|
|
13
|
-
import type { GenericResponse, GetAllSupplierRequest, IndexSupplierRequest, PaginatedSupplierListResourceResponse, StoreSupplierRequest, SupplierLiteResourceArrayResponse, SupplierResource, UpdateSupplierRequest } from '../models/index';
|
|
13
|
+
import type { AttachStoresSupplierRequest, DetachStoresSupplierRequest, GenericResponse, GetAllSupplierRequest, IndexSupplierRequest, PaginatedSupplierListResourceResponse, StoreSupplierRequest, SupplierLiteResourceArrayResponse, SupplierResource, UpdateSupplierRequest } from '../models/index';
|
|
14
|
+
export interface AttachStoresSupplierOperationRequest {
|
|
15
|
+
supplier: number;
|
|
16
|
+
attachStoresSupplierRequest?: AttachStoresSupplierRequest;
|
|
17
|
+
}
|
|
14
18
|
export interface DestroySupplierRequest {
|
|
15
19
|
supplier: number;
|
|
16
20
|
}
|
|
21
|
+
export interface DetachStoresSupplierOperationRequest {
|
|
22
|
+
supplier: number;
|
|
23
|
+
detachStoresSupplierRequest?: DetachStoresSupplierRequest;
|
|
24
|
+
}
|
|
17
25
|
export interface ExportSupplierRequest {
|
|
18
26
|
indexSupplierRequest?: IndexSupplierRequest;
|
|
19
27
|
}
|
|
@@ -40,6 +48,18 @@ export interface UpdateSupplierOperationRequest {
|
|
|
40
48
|
*
|
|
41
49
|
*/
|
|
42
50
|
export declare class SupplierApi extends runtime.BaseAPI {
|
|
51
|
+
/**
|
|
52
|
+
* Creates request options for attachStoresSupplier without sending the request
|
|
53
|
+
*/
|
|
54
|
+
attachStoresSupplierRequestOpts(requestParameters: AttachStoresSupplierOperationRequest): Promise<runtime.RequestOpts>;
|
|
55
|
+
/**
|
|
56
|
+
* Auto-generated: attachStoresSupplier
|
|
57
|
+
*/
|
|
58
|
+
attachStoresSupplierRaw(requestParameters: AttachStoresSupplierOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SupplierResource>>;
|
|
59
|
+
/**
|
|
60
|
+
* Auto-generated: attachStoresSupplier
|
|
61
|
+
*/
|
|
62
|
+
attachStoresSupplier(requestParameters: AttachStoresSupplierOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SupplierResource>;
|
|
43
63
|
/**
|
|
44
64
|
* Creates request options for destroySupplier without sending the request
|
|
45
65
|
*/
|
|
@@ -52,6 +72,18 @@ export declare class SupplierApi extends runtime.BaseAPI {
|
|
|
52
72
|
* Auto-generated: destroySupplier
|
|
53
73
|
*/
|
|
54
74
|
destroySupplier(requestParameters: DestroySupplierRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GenericResponse>;
|
|
75
|
+
/**
|
|
76
|
+
* Creates request options for detachStoresSupplier without sending the request
|
|
77
|
+
*/
|
|
78
|
+
detachStoresSupplierRequestOpts(requestParameters: DetachStoresSupplierOperationRequest): Promise<runtime.RequestOpts>;
|
|
79
|
+
/**
|
|
80
|
+
* Auto-generated: detachStoresSupplier
|
|
81
|
+
*/
|
|
82
|
+
detachStoresSupplierRaw(requestParameters: DetachStoresSupplierOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SupplierResource>>;
|
|
83
|
+
/**
|
|
84
|
+
* Auto-generated: detachStoresSupplier
|
|
85
|
+
*/
|
|
86
|
+
detachStoresSupplier(requestParameters: DetachStoresSupplierOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SupplierResource>;
|
|
55
87
|
/**
|
|
56
88
|
* Creates request options for exportSupplier without sending the request
|
|
57
89
|
*/
|