@lcdp/api-react-rest-client 3.1.11 → 3.3.0
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/catalog/src/models/ProductInsight.d.ts +6 -6
- package/catalog/src/models/ProductInsight.js +6 -6
- package/catalog/src/models/ProductInsightCreateOrUpdateParameters.d.ts +8 -6
- package/catalog/src/models/ProductInsightCreateOrUpdateParameters.js +6 -4
- package/catalog/src/models/ProductSecondaryType.d.ts +25 -0
- package/catalog/src/models/ProductSecondaryType.js +48 -0
- package/catalog/src/models/ProductType.d.ts +28 -0
- package/catalog/src/models/ProductType.js +51 -0
- package/catalog/src/models/index.d.ts +2 -2
- package/catalog/src/models/index.js +2 -2
- package/factory/src/models/Product.d.ts +4 -3
- package/factory/src/models/Product.js +3 -2
- package/factory/src/models/ProductType.d.ts +28 -0
- package/factory/src/models/ProductType.js +51 -0
- package/factory/src/models/index.d.ts +1 -0
- package/factory/src/models/index.js +1 -0
- package/package.json +1 -1
- package/product/src/apis/ManageProductApi.d.ts +2 -2
- package/product/src/apis/ManageProductApi.js +2 -2
- package/product/src/apis/index.d.ts +0 -1
- package/product/src/apis/index.js +0 -1
- package/product/src/models/ProductCreationOrUpdateParameters.d.ts +8 -6
- package/product/src/models/ProductCreationOrUpdateParameters.js +6 -4
- package/product/src/models/ProductSecondaryType.d.ts +7 -19
- package/product/src/models/ProductSecondaryType.js +18 -17
- package/product/src/models/ProductType.d.ts +10 -19
- package/product/src/models/ProductType.js +21 -17
- package/user/src/apis/ManageUserRestrictionApi.d.ts +1 -25
- package/user/src/apis/ManageUserRestrictionApi.js +12 -152
- package/user/src/apis/SearchUserRestrictionApi.d.ts +1 -12
- package/user/src/apis/SearchUserRestrictionApi.js +0 -79
- package/user/src/models/ProductType.d.ts +28 -0
- package/user/src/models/ProductType.js +51 -0
- package/user/src/models/RestrictedProductType.d.ts +46 -0
- package/user/src/models/RestrictedProductType.js +55 -0
- package/user/src/models/User.d.ts +3 -2
- package/user/src/models/User.js +3 -2
- package/user/src/models/UserUpdateParameters.d.ts +7 -0
- package/user/src/models/UserUpdateParameters.js +3 -0
- package/user/src/models/index.d.ts +2 -2
- package/user/src/models/index.js +2 -2
- package/catalog/src/models/ProductSecondaryTypeLink.d.ts +0 -43
- package/catalog/src/models/ProductSecondaryTypeLink.js +0 -51
- package/catalog/src/models/ProductTypeLink.d.ts +0 -43
- package/catalog/src/models/ProductTypeLink.js +0 -51
- package/product/src/apis/SearchProductMetadataApi.d.ts +0 -56
- package/product/src/apis/SearchProductMetadataApi.js +0 -390
- package/user/src/models/ProductTypeLink.d.ts +0 -43
- package/user/src/models/ProductTypeLink.js +0 -51
- package/user/src/models/UserRestrictedProductTypeCreationParameter.d.ts +0 -31
- package/user/src/models/UserRestrictedProductTypeCreationParameter.js +0 -47
|
@@ -1,390 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/* tslint:disable */
|
|
3
|
-
/* eslint-disable */
|
|
4
|
-
/**
|
|
5
|
-
* lcdp-monolith-service
|
|
6
|
-
* This is the REST API of LCDP products
|
|
7
|
-
*
|
|
8
|
-
* The version of the OpenAPI document: 1.0.0
|
|
9
|
-
* Contact: contact@lecomptoirdespharmacies.fr
|
|
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;
|
|
41
|
-
return g = { next: verb(0), "throw": verb(1), "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 (_) 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.SearchProductMetadataApi = void 0;
|
|
68
|
-
var runtime = require("../runtime");
|
|
69
|
-
var index_1 = require("../models/index");
|
|
70
|
-
/**
|
|
71
|
-
*
|
|
72
|
-
*/
|
|
73
|
-
var SearchProductMetadataApi = /** @class */ (function (_super) {
|
|
74
|
-
__extends(SearchProductMetadataApi, _super);
|
|
75
|
-
function SearchProductMetadataApi() {
|
|
76
|
-
return _super !== null && _super.apply(this, arguments) || this;
|
|
77
|
-
}
|
|
78
|
-
/**
|
|
79
|
-
* Get product secondary type
|
|
80
|
-
*/
|
|
81
|
-
SearchProductMetadataApi.prototype.getProductSecondaryTypeRaw = function (requestParameters, initOverrides) {
|
|
82
|
-
return __awaiter(this, void 0, void 0, function () {
|
|
83
|
-
var queryParameters, headerParameters, _a, _b, token, tokenString, response, contentType, response_1;
|
|
84
|
-
return __generator(this, function (_c) {
|
|
85
|
-
switch (_c.label) {
|
|
86
|
-
case 0:
|
|
87
|
-
if (requestParameters['secondaryTypeId'] == null) {
|
|
88
|
-
throw new runtime.RequiredError('secondaryTypeId', 'Required parameter "secondaryTypeId" was null or undefined when calling getProductSecondaryType().');
|
|
89
|
-
}
|
|
90
|
-
queryParameters = {};
|
|
91
|
-
headerParameters = {};
|
|
92
|
-
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 2];
|
|
93
|
-
_a = headerParameters;
|
|
94
|
-
_b = "x-api-key";
|
|
95
|
-
return [4 /*yield*/, this.configuration.apiKey("x-api-key")];
|
|
96
|
-
case 1:
|
|
97
|
-
_a[_b] = _c.sent(); // apiKeyAuth authentication
|
|
98
|
-
_c.label = 2;
|
|
99
|
-
case 2:
|
|
100
|
-
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 4];
|
|
101
|
-
token = this.configuration.accessToken;
|
|
102
|
-
return [4 /*yield*/, token("bearerAuth", [])];
|
|
103
|
-
case 3:
|
|
104
|
-
tokenString = _c.sent();
|
|
105
|
-
if (tokenString) {
|
|
106
|
-
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
107
|
-
}
|
|
108
|
-
_c.label = 4;
|
|
109
|
-
case 4:
|
|
110
|
-
_c.trys.push([4, 6, , 7]);
|
|
111
|
-
return [4 /*yield*/, this.request({
|
|
112
|
-
path: "/products/secondary-types/{secondaryTypeId}".replace("{".concat("secondaryTypeId", "}"), encodeURIComponent(String(requestParameters['secondaryTypeId']))),
|
|
113
|
-
method: 'GET',
|
|
114
|
-
headers: headerParameters,
|
|
115
|
-
query: queryParameters,
|
|
116
|
-
}, initOverrides)];
|
|
117
|
-
case 5:
|
|
118
|
-
response = _c.sent();
|
|
119
|
-
contentType = response.headers.get("content-type");
|
|
120
|
-
if (contentType && contentType.indexOf("application/json") !== -1) {
|
|
121
|
-
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.ProductSecondaryTypeFromJSON)(jsonValue); })];
|
|
122
|
-
}
|
|
123
|
-
else if (contentType && contentType.indexOf("text/plain") !== -1) {
|
|
124
|
-
return [2 /*return*/, new runtime.TextApiResponse(response)];
|
|
125
|
-
}
|
|
126
|
-
else {
|
|
127
|
-
// TODO : Better handling of others application types
|
|
128
|
-
return [2 /*return*/, new runtime.BlobWithMetaApiResponse(response)];
|
|
129
|
-
}
|
|
130
|
-
return [3 /*break*/, 7];
|
|
131
|
-
case 6:
|
|
132
|
-
response_1 = _c.sent();
|
|
133
|
-
console.debug(response_1);
|
|
134
|
-
throw response_1;
|
|
135
|
-
case 7: return [2 /*return*/];
|
|
136
|
-
}
|
|
137
|
-
});
|
|
138
|
-
});
|
|
139
|
-
};
|
|
140
|
-
/**
|
|
141
|
-
* Get product secondary type
|
|
142
|
-
*/
|
|
143
|
-
SearchProductMetadataApi.prototype.getProductSecondaryType = function (requestParameters, initOverrides) {
|
|
144
|
-
return __awaiter(this, void 0, void 0, function () {
|
|
145
|
-
var response;
|
|
146
|
-
return __generator(this, function (_a) {
|
|
147
|
-
switch (_a.label) {
|
|
148
|
-
case 0: return [4 /*yield*/, this.getProductSecondaryTypeRaw(requestParameters, initOverrides)];
|
|
149
|
-
case 1:
|
|
150
|
-
response = _a.sent();
|
|
151
|
-
return [4 /*yield*/, response.value()];
|
|
152
|
-
case 2: return [2 /*return*/, _a.sent()];
|
|
153
|
-
}
|
|
154
|
-
});
|
|
155
|
-
});
|
|
156
|
-
};
|
|
157
|
-
/**
|
|
158
|
-
* Get product secondary types
|
|
159
|
-
*/
|
|
160
|
-
SearchProductMetadataApi.prototype.getProductSecondaryTypesRaw = function (initOverrides) {
|
|
161
|
-
return __awaiter(this, void 0, void 0, function () {
|
|
162
|
-
var queryParameters, headerParameters, _a, _b, token, tokenString, response, contentType, response_2;
|
|
163
|
-
return __generator(this, function (_c) {
|
|
164
|
-
switch (_c.label) {
|
|
165
|
-
case 0:
|
|
166
|
-
queryParameters = {};
|
|
167
|
-
headerParameters = {};
|
|
168
|
-
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 2];
|
|
169
|
-
_a = headerParameters;
|
|
170
|
-
_b = "x-api-key";
|
|
171
|
-
return [4 /*yield*/, this.configuration.apiKey("x-api-key")];
|
|
172
|
-
case 1:
|
|
173
|
-
_a[_b] = _c.sent(); // apiKeyAuth authentication
|
|
174
|
-
_c.label = 2;
|
|
175
|
-
case 2:
|
|
176
|
-
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 4];
|
|
177
|
-
token = this.configuration.accessToken;
|
|
178
|
-
return [4 /*yield*/, token("bearerAuth", [])];
|
|
179
|
-
case 3:
|
|
180
|
-
tokenString = _c.sent();
|
|
181
|
-
if (tokenString) {
|
|
182
|
-
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
183
|
-
}
|
|
184
|
-
_c.label = 4;
|
|
185
|
-
case 4:
|
|
186
|
-
_c.trys.push([4, 6, , 7]);
|
|
187
|
-
return [4 /*yield*/, this.request({
|
|
188
|
-
path: "/products/secondary-types",
|
|
189
|
-
method: 'GET',
|
|
190
|
-
headers: headerParameters,
|
|
191
|
-
query: queryParameters,
|
|
192
|
-
}, initOverrides)];
|
|
193
|
-
case 5:
|
|
194
|
-
response = _c.sent();
|
|
195
|
-
contentType = response.headers.get("content-type");
|
|
196
|
-
if (contentType && contentType.indexOf("application/json") !== -1) {
|
|
197
|
-
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return jsonValue.map(index_1.ProductSecondaryTypeFromJSON); })];
|
|
198
|
-
}
|
|
199
|
-
else if (contentType && contentType.indexOf("text/plain") !== -1) {
|
|
200
|
-
return [2 /*return*/, new runtime.TextApiResponse(response)];
|
|
201
|
-
}
|
|
202
|
-
else {
|
|
203
|
-
// TODO : Better handling of others application types
|
|
204
|
-
return [2 /*return*/, new runtime.BlobWithMetaApiResponse(response)];
|
|
205
|
-
}
|
|
206
|
-
return [3 /*break*/, 7];
|
|
207
|
-
case 6:
|
|
208
|
-
response_2 = _c.sent();
|
|
209
|
-
console.debug(response_2);
|
|
210
|
-
throw response_2;
|
|
211
|
-
case 7: return [2 /*return*/];
|
|
212
|
-
}
|
|
213
|
-
});
|
|
214
|
-
});
|
|
215
|
-
};
|
|
216
|
-
/**
|
|
217
|
-
* Get product secondary types
|
|
218
|
-
*/
|
|
219
|
-
SearchProductMetadataApi.prototype.getProductSecondaryTypes = function (initOverrides) {
|
|
220
|
-
return __awaiter(this, void 0, void 0, function () {
|
|
221
|
-
var response;
|
|
222
|
-
return __generator(this, function (_a) {
|
|
223
|
-
switch (_a.label) {
|
|
224
|
-
case 0: return [4 /*yield*/, this.getProductSecondaryTypesRaw(initOverrides)];
|
|
225
|
-
case 1:
|
|
226
|
-
response = _a.sent();
|
|
227
|
-
return [4 /*yield*/, response.value()];
|
|
228
|
-
case 2: return [2 /*return*/, _a.sent()];
|
|
229
|
-
}
|
|
230
|
-
});
|
|
231
|
-
});
|
|
232
|
-
};
|
|
233
|
-
/**
|
|
234
|
-
* Get product type
|
|
235
|
-
*/
|
|
236
|
-
SearchProductMetadataApi.prototype.getProductTypeRaw = function (requestParameters, initOverrides) {
|
|
237
|
-
return __awaiter(this, void 0, void 0, function () {
|
|
238
|
-
var queryParameters, headerParameters, _a, _b, token, tokenString, response, contentType, response_3;
|
|
239
|
-
return __generator(this, function (_c) {
|
|
240
|
-
switch (_c.label) {
|
|
241
|
-
case 0:
|
|
242
|
-
if (requestParameters['typeId'] == null) {
|
|
243
|
-
throw new runtime.RequiredError('typeId', 'Required parameter "typeId" was null or undefined when calling getProductType().');
|
|
244
|
-
}
|
|
245
|
-
queryParameters = {};
|
|
246
|
-
headerParameters = {};
|
|
247
|
-
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 2];
|
|
248
|
-
_a = headerParameters;
|
|
249
|
-
_b = "x-api-key";
|
|
250
|
-
return [4 /*yield*/, this.configuration.apiKey("x-api-key")];
|
|
251
|
-
case 1:
|
|
252
|
-
_a[_b] = _c.sent(); // apiKeyAuth authentication
|
|
253
|
-
_c.label = 2;
|
|
254
|
-
case 2:
|
|
255
|
-
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 4];
|
|
256
|
-
token = this.configuration.accessToken;
|
|
257
|
-
return [4 /*yield*/, token("bearerAuth", [])];
|
|
258
|
-
case 3:
|
|
259
|
-
tokenString = _c.sent();
|
|
260
|
-
if (tokenString) {
|
|
261
|
-
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
262
|
-
}
|
|
263
|
-
_c.label = 4;
|
|
264
|
-
case 4:
|
|
265
|
-
_c.trys.push([4, 6, , 7]);
|
|
266
|
-
return [4 /*yield*/, this.request({
|
|
267
|
-
path: "/products/types/{typeId}".replace("{".concat("typeId", "}"), encodeURIComponent(String(requestParameters['typeId']))),
|
|
268
|
-
method: 'GET',
|
|
269
|
-
headers: headerParameters,
|
|
270
|
-
query: queryParameters,
|
|
271
|
-
}, initOverrides)];
|
|
272
|
-
case 5:
|
|
273
|
-
response = _c.sent();
|
|
274
|
-
contentType = response.headers.get("content-type");
|
|
275
|
-
if (contentType && contentType.indexOf("application/json") !== -1) {
|
|
276
|
-
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.ProductTypeFromJSON)(jsonValue); })];
|
|
277
|
-
}
|
|
278
|
-
else if (contentType && contentType.indexOf("text/plain") !== -1) {
|
|
279
|
-
return [2 /*return*/, new runtime.TextApiResponse(response)];
|
|
280
|
-
}
|
|
281
|
-
else {
|
|
282
|
-
// TODO : Better handling of others application types
|
|
283
|
-
return [2 /*return*/, new runtime.BlobWithMetaApiResponse(response)];
|
|
284
|
-
}
|
|
285
|
-
return [3 /*break*/, 7];
|
|
286
|
-
case 6:
|
|
287
|
-
response_3 = _c.sent();
|
|
288
|
-
console.debug(response_3);
|
|
289
|
-
throw response_3;
|
|
290
|
-
case 7: return [2 /*return*/];
|
|
291
|
-
}
|
|
292
|
-
});
|
|
293
|
-
});
|
|
294
|
-
};
|
|
295
|
-
/**
|
|
296
|
-
* Get product type
|
|
297
|
-
*/
|
|
298
|
-
SearchProductMetadataApi.prototype.getProductType = function (requestParameters, initOverrides) {
|
|
299
|
-
return __awaiter(this, void 0, void 0, function () {
|
|
300
|
-
var response;
|
|
301
|
-
return __generator(this, function (_a) {
|
|
302
|
-
switch (_a.label) {
|
|
303
|
-
case 0: return [4 /*yield*/, this.getProductTypeRaw(requestParameters, initOverrides)];
|
|
304
|
-
case 1:
|
|
305
|
-
response = _a.sent();
|
|
306
|
-
return [4 /*yield*/, response.value()];
|
|
307
|
-
case 2: return [2 /*return*/, _a.sent()];
|
|
308
|
-
}
|
|
309
|
-
});
|
|
310
|
-
});
|
|
311
|
-
};
|
|
312
|
-
/**
|
|
313
|
-
* Get product types
|
|
314
|
-
*/
|
|
315
|
-
SearchProductMetadataApi.prototype.getProductTypesRaw = function (initOverrides) {
|
|
316
|
-
return __awaiter(this, void 0, void 0, function () {
|
|
317
|
-
var queryParameters, headerParameters, _a, _b, token, tokenString, response, contentType, response_4;
|
|
318
|
-
return __generator(this, function (_c) {
|
|
319
|
-
switch (_c.label) {
|
|
320
|
-
case 0:
|
|
321
|
-
queryParameters = {};
|
|
322
|
-
headerParameters = {};
|
|
323
|
-
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 2];
|
|
324
|
-
_a = headerParameters;
|
|
325
|
-
_b = "x-api-key";
|
|
326
|
-
return [4 /*yield*/, this.configuration.apiKey("x-api-key")];
|
|
327
|
-
case 1:
|
|
328
|
-
_a[_b] = _c.sent(); // apiKeyAuth authentication
|
|
329
|
-
_c.label = 2;
|
|
330
|
-
case 2:
|
|
331
|
-
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 4];
|
|
332
|
-
token = this.configuration.accessToken;
|
|
333
|
-
return [4 /*yield*/, token("bearerAuth", [])];
|
|
334
|
-
case 3:
|
|
335
|
-
tokenString = _c.sent();
|
|
336
|
-
if (tokenString) {
|
|
337
|
-
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
338
|
-
}
|
|
339
|
-
_c.label = 4;
|
|
340
|
-
case 4:
|
|
341
|
-
_c.trys.push([4, 6, , 7]);
|
|
342
|
-
return [4 /*yield*/, this.request({
|
|
343
|
-
path: "/products/types",
|
|
344
|
-
method: 'GET',
|
|
345
|
-
headers: headerParameters,
|
|
346
|
-
query: queryParameters,
|
|
347
|
-
}, initOverrides)];
|
|
348
|
-
case 5:
|
|
349
|
-
response = _c.sent();
|
|
350
|
-
contentType = response.headers.get("content-type");
|
|
351
|
-
if (contentType && contentType.indexOf("application/json") !== -1) {
|
|
352
|
-
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return jsonValue.map(index_1.ProductTypeFromJSON); })];
|
|
353
|
-
}
|
|
354
|
-
else if (contentType && contentType.indexOf("text/plain") !== -1) {
|
|
355
|
-
return [2 /*return*/, new runtime.TextApiResponse(response)];
|
|
356
|
-
}
|
|
357
|
-
else {
|
|
358
|
-
// TODO : Better handling of others application types
|
|
359
|
-
return [2 /*return*/, new runtime.BlobWithMetaApiResponse(response)];
|
|
360
|
-
}
|
|
361
|
-
return [3 /*break*/, 7];
|
|
362
|
-
case 6:
|
|
363
|
-
response_4 = _c.sent();
|
|
364
|
-
console.debug(response_4);
|
|
365
|
-
throw response_4;
|
|
366
|
-
case 7: return [2 /*return*/];
|
|
367
|
-
}
|
|
368
|
-
});
|
|
369
|
-
});
|
|
370
|
-
};
|
|
371
|
-
/**
|
|
372
|
-
* Get product types
|
|
373
|
-
*/
|
|
374
|
-
SearchProductMetadataApi.prototype.getProductTypes = function (initOverrides) {
|
|
375
|
-
return __awaiter(this, void 0, void 0, function () {
|
|
376
|
-
var response;
|
|
377
|
-
return __generator(this, function (_a) {
|
|
378
|
-
switch (_a.label) {
|
|
379
|
-
case 0: return [4 /*yield*/, this.getProductTypesRaw(initOverrides)];
|
|
380
|
-
case 1:
|
|
381
|
-
response = _a.sent();
|
|
382
|
-
return [4 /*yield*/, response.value()];
|
|
383
|
-
case 2: return [2 /*return*/, _a.sent()];
|
|
384
|
-
}
|
|
385
|
-
});
|
|
386
|
-
});
|
|
387
|
-
};
|
|
388
|
-
return SearchProductMetadataApi;
|
|
389
|
-
}(runtime.BaseAPI));
|
|
390
|
-
exports.SearchProductMetadataApi = SearchProductMetadataApi;
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* lcdp-monolith-service
|
|
3
|
-
* This is the REST API of LCDP products
|
|
4
|
-
*
|
|
5
|
-
* The version of the OpenAPI document: 1.0.0
|
|
6
|
-
* Contact: contact@lecomptoirdespharmacies.fr
|
|
7
|
-
*
|
|
8
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
-
* https://openapi-generator.tech
|
|
10
|
-
* Do not edit the class manually.
|
|
11
|
-
*/
|
|
12
|
-
/**
|
|
13
|
-
*
|
|
14
|
-
* @export
|
|
15
|
-
* @interface ProductTypeLink
|
|
16
|
-
*/
|
|
17
|
-
export interface ProductTypeLink {
|
|
18
|
-
/**
|
|
19
|
-
* Any URL that is using http or https protocol
|
|
20
|
-
* @type {string}
|
|
21
|
-
* @memberof ProductTypeLink
|
|
22
|
-
*/
|
|
23
|
-
href: string;
|
|
24
|
-
/**
|
|
25
|
-
*
|
|
26
|
-
* @type {string}
|
|
27
|
-
* @memberof ProductTypeLink
|
|
28
|
-
*/
|
|
29
|
-
id?: string;
|
|
30
|
-
/**
|
|
31
|
-
*
|
|
32
|
-
* @type {string}
|
|
33
|
-
* @memberof ProductTypeLink
|
|
34
|
-
*/
|
|
35
|
-
name?: string;
|
|
36
|
-
}
|
|
37
|
-
/**
|
|
38
|
-
* Check if a given object implements the ProductTypeLink interface.
|
|
39
|
-
*/
|
|
40
|
-
export declare function instanceOfProductTypeLink(value: object): value is ProductTypeLink;
|
|
41
|
-
export declare function ProductTypeLinkFromJSON(json: any): ProductTypeLink;
|
|
42
|
-
export declare function ProductTypeLinkFromJSONTyped(json: any, ignoreDiscriminator: boolean): ProductTypeLink;
|
|
43
|
-
export declare function ProductTypeLinkToJSON(value?: ProductTypeLink | null): any;
|
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/* tslint:disable */
|
|
3
|
-
/* eslint-disable */
|
|
4
|
-
/**
|
|
5
|
-
* lcdp-monolith-service
|
|
6
|
-
* This is the REST API of LCDP products
|
|
7
|
-
*
|
|
8
|
-
* The version of the OpenAPI document: 1.0.0
|
|
9
|
-
* Contact: contact@lecomptoirdespharmacies.fr
|
|
10
|
-
*
|
|
11
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
-
* https://openapi-generator.tech
|
|
13
|
-
* Do not edit the class manually.
|
|
14
|
-
*/
|
|
15
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
-
exports.ProductTypeLinkToJSON = exports.ProductTypeLinkFromJSONTyped = exports.ProductTypeLinkFromJSON = exports.instanceOfProductTypeLink = void 0;
|
|
17
|
-
/**
|
|
18
|
-
* Check if a given object implements the ProductTypeLink interface.
|
|
19
|
-
*/
|
|
20
|
-
function instanceOfProductTypeLink(value) {
|
|
21
|
-
if (!('href' in value) || value['href'] === undefined)
|
|
22
|
-
return false;
|
|
23
|
-
return true;
|
|
24
|
-
}
|
|
25
|
-
exports.instanceOfProductTypeLink = instanceOfProductTypeLink;
|
|
26
|
-
function ProductTypeLinkFromJSON(json) {
|
|
27
|
-
return ProductTypeLinkFromJSONTyped(json, false);
|
|
28
|
-
}
|
|
29
|
-
exports.ProductTypeLinkFromJSON = ProductTypeLinkFromJSON;
|
|
30
|
-
function ProductTypeLinkFromJSONTyped(json, ignoreDiscriminator) {
|
|
31
|
-
if (json == null) {
|
|
32
|
-
return json;
|
|
33
|
-
}
|
|
34
|
-
return {
|
|
35
|
-
'href': json['href'],
|
|
36
|
-
'id': json['id'],
|
|
37
|
-
'name': json['name'],
|
|
38
|
-
};
|
|
39
|
-
}
|
|
40
|
-
exports.ProductTypeLinkFromJSONTyped = ProductTypeLinkFromJSONTyped;
|
|
41
|
-
function ProductTypeLinkToJSON(value) {
|
|
42
|
-
if (value == null) {
|
|
43
|
-
return value;
|
|
44
|
-
}
|
|
45
|
-
return {
|
|
46
|
-
'href': value['href'],
|
|
47
|
-
'id': value['id'],
|
|
48
|
-
'name': value['name'],
|
|
49
|
-
};
|
|
50
|
-
}
|
|
51
|
-
exports.ProductTypeLinkToJSON = ProductTypeLinkToJSON;
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* lcdp-monolith-service
|
|
3
|
-
* This is the REST API of LCDP products
|
|
4
|
-
*
|
|
5
|
-
* The version of the OpenAPI document: 1.0.0
|
|
6
|
-
* Contact: contact@lecomptoirdespharmacies.fr
|
|
7
|
-
*
|
|
8
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
-
* https://openapi-generator.tech
|
|
10
|
-
* Do not edit the class manually.
|
|
11
|
-
*/
|
|
12
|
-
/**
|
|
13
|
-
*
|
|
14
|
-
* @export
|
|
15
|
-
* @interface UserRestrictedProductTypeCreationParameter
|
|
16
|
-
*/
|
|
17
|
-
export interface UserRestrictedProductTypeCreationParameter {
|
|
18
|
-
/**
|
|
19
|
-
* Product type id
|
|
20
|
-
* @type {string}
|
|
21
|
-
* @memberof UserRestrictedProductTypeCreationParameter
|
|
22
|
-
*/
|
|
23
|
-
productTypeId: string;
|
|
24
|
-
}
|
|
25
|
-
/**
|
|
26
|
-
* Check if a given object implements the UserRestrictedProductTypeCreationParameter interface.
|
|
27
|
-
*/
|
|
28
|
-
export declare function instanceOfUserRestrictedProductTypeCreationParameter(value: object): value is UserRestrictedProductTypeCreationParameter;
|
|
29
|
-
export declare function UserRestrictedProductTypeCreationParameterFromJSON(json: any): UserRestrictedProductTypeCreationParameter;
|
|
30
|
-
export declare function UserRestrictedProductTypeCreationParameterFromJSONTyped(json: any, ignoreDiscriminator: boolean): UserRestrictedProductTypeCreationParameter;
|
|
31
|
-
export declare function UserRestrictedProductTypeCreationParameterToJSON(value?: UserRestrictedProductTypeCreationParameter | null): any;
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/* tslint:disable */
|
|
3
|
-
/* eslint-disable */
|
|
4
|
-
/**
|
|
5
|
-
* lcdp-monolith-service
|
|
6
|
-
* This is the REST API of LCDP products
|
|
7
|
-
*
|
|
8
|
-
* The version of the OpenAPI document: 1.0.0
|
|
9
|
-
* Contact: contact@lecomptoirdespharmacies.fr
|
|
10
|
-
*
|
|
11
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
-
* https://openapi-generator.tech
|
|
13
|
-
* Do not edit the class manually.
|
|
14
|
-
*/
|
|
15
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
-
exports.UserRestrictedProductTypeCreationParameterToJSON = exports.UserRestrictedProductTypeCreationParameterFromJSONTyped = exports.UserRestrictedProductTypeCreationParameterFromJSON = exports.instanceOfUserRestrictedProductTypeCreationParameter = void 0;
|
|
17
|
-
/**
|
|
18
|
-
* Check if a given object implements the UserRestrictedProductTypeCreationParameter interface.
|
|
19
|
-
*/
|
|
20
|
-
function instanceOfUserRestrictedProductTypeCreationParameter(value) {
|
|
21
|
-
if (!('productTypeId' in value) || value['productTypeId'] === undefined)
|
|
22
|
-
return false;
|
|
23
|
-
return true;
|
|
24
|
-
}
|
|
25
|
-
exports.instanceOfUserRestrictedProductTypeCreationParameter = instanceOfUserRestrictedProductTypeCreationParameter;
|
|
26
|
-
function UserRestrictedProductTypeCreationParameterFromJSON(json) {
|
|
27
|
-
return UserRestrictedProductTypeCreationParameterFromJSONTyped(json, false);
|
|
28
|
-
}
|
|
29
|
-
exports.UserRestrictedProductTypeCreationParameterFromJSON = UserRestrictedProductTypeCreationParameterFromJSON;
|
|
30
|
-
function UserRestrictedProductTypeCreationParameterFromJSONTyped(json, ignoreDiscriminator) {
|
|
31
|
-
if (json == null) {
|
|
32
|
-
return json;
|
|
33
|
-
}
|
|
34
|
-
return {
|
|
35
|
-
'productTypeId': json['productTypeId'],
|
|
36
|
-
};
|
|
37
|
-
}
|
|
38
|
-
exports.UserRestrictedProductTypeCreationParameterFromJSONTyped = UserRestrictedProductTypeCreationParameterFromJSONTyped;
|
|
39
|
-
function UserRestrictedProductTypeCreationParameterToJSON(value) {
|
|
40
|
-
if (value == null) {
|
|
41
|
-
return value;
|
|
42
|
-
}
|
|
43
|
-
return {
|
|
44
|
-
'productTypeId': value['productTypeId'],
|
|
45
|
-
};
|
|
46
|
-
}
|
|
47
|
-
exports.UserRestrictedProductTypeCreationParameterToJSON = UserRestrictedProductTypeCreationParameterToJSON;
|