@lcdp/api-react-rest-client 2.2.0-develop.5257187856 → 2.2.0-fix-best-rebate-min.5257097244

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.
Files changed (66) hide show
  1. package/catalog/index.d.ts +1 -0
  2. package/catalog/index.js +17 -0
  3. package/catalog/src/apis/ManageProductInsightApi.d.ts +54 -0
  4. package/catalog/src/apis/ManageProductInsightApi.js +295 -0
  5. package/catalog/src/apis/SearchProductInsightApi.d.ts +53 -0
  6. package/catalog/src/apis/SearchProductInsightApi.js +246 -0
  7. package/catalog/src/apis/index.d.ts +2 -0
  8. package/catalog/src/apis/index.js +18 -0
  9. package/catalog/src/index.d.ts +3 -0
  10. package/catalog/src/index.js +19 -0
  11. package/catalog/src/models/Barcodes.d.ts +45 -0
  12. package/catalog/src/models/Barcodes.js +48 -0
  13. package/catalog/src/models/HttpLink.d.ts +27 -0
  14. package/catalog/src/models/HttpLink.js +41 -0
  15. package/catalog/src/models/LaboratoryLink.d.ts +34 -0
  16. package/catalog/src/models/LaboratoryLink.js +50 -0
  17. package/catalog/src/models/LaboratoryLinkAllOf.d.ts +33 -0
  18. package/catalog/src/models/LaboratoryLinkAllOf.js +44 -0
  19. package/catalog/src/models/PaginatedObject.d.ts +28 -0
  20. package/catalog/src/models/PaginatedObject.js +42 -0
  21. package/catalog/src/models/PaginatedProductInsights.d.ts +29 -0
  22. package/catalog/src/models/PaginatedProductInsights.js +50 -0
  23. package/catalog/src/models/PaginatedProductInsightsAllOf.d.ts +28 -0
  24. package/catalog/src/models/PaginatedProductInsightsAllOf.js +42 -0
  25. package/catalog/src/models/PagingMetadata.d.ts +45 -0
  26. package/catalog/src/models/PagingMetadata.js +47 -0
  27. package/catalog/src/models/ProductInsight.d.ts +100 -0
  28. package/catalog/src/models/ProductInsight.js +70 -0
  29. package/catalog/src/models/ProductInsightCreationOrUpdateParameters.d.ts +83 -0
  30. package/catalog/src/models/ProductInsightCreationOrUpdateParameters.js +62 -0
  31. package/catalog/src/models/ProductInsightJournal.d.ts +33 -0
  32. package/catalog/src/models/ProductInsightJournal.js +43 -0
  33. package/catalog/src/models/ProductSecondaryTypeLink.d.ts +34 -0
  34. package/catalog/src/models/ProductSecondaryTypeLink.js +50 -0
  35. package/catalog/src/models/ProductSecondaryTypeLinkAllOf.d.ts +33 -0
  36. package/catalog/src/models/ProductSecondaryTypeLinkAllOf.js +44 -0
  37. package/catalog/src/models/ProductStorageType.d.ts +25 -0
  38. package/catalog/src/models/ProductStorageType.js +40 -0
  39. package/catalog/src/models/ProductTypeLink.d.ts +34 -0
  40. package/catalog/src/models/ProductTypeLink.js +50 -0
  41. package/catalog/src/models/ProductTypeLinkAllOf.d.ts +33 -0
  42. package/catalog/src/models/ProductTypeLinkAllOf.js +44 -0
  43. package/catalog/src/models/RestError.d.ts +85 -0
  44. package/catalog/src/models/RestError.js +97 -0
  45. package/catalog/src/models/VatLink.d.ts +40 -0
  46. package/catalog/src/models/VatLink.js +50 -0
  47. package/catalog/src/models/VatLinkAllOf.d.ts +39 -0
  48. package/catalog/src/models/VatLinkAllOf.js +46 -0
  49. package/catalog/src/models/index.d.ts +19 -0
  50. package/catalog/src/models/index.js +35 -0
  51. package/catalog/src/runtime.d.ts +149 -0
  52. package/catalog/src/runtime.js +480 -0
  53. package/package.json +1 -1
  54. package/product/src/apis/SearchProductMetadataApi.d.ts +22 -0
  55. package/product/src/apis/SearchProductMetadataApi.js +154 -8
  56. package/product/src/models/{ProductProvider.d.ts → DataProvider.d.ts} +7 -5
  57. package/product/src/models/DataProvider.js +40 -0
  58. package/product/src/models/Product.d.ts +9 -9
  59. package/product/src/models/Product.js +5 -5
  60. package/product/src/models/ProductMetadata.d.ts +28 -0
  61. package/product/src/models/ProductMetadata.js +42 -0
  62. package/product/src/models/ProductMetadataSources.d.ts +88 -0
  63. package/product/src/models/ProductMetadataSources.js +62 -0
  64. package/product/src/models/index.d.ts +3 -1
  65. package/product/src/models/index.js +3 -1
  66. package/product/src/models/ProductProvider.js +0 -38
@@ -76,14 +76,17 @@ var SearchProductMetadataApi = /** @class */ (function (_super) {
76
76
  return _super !== null && _super.apply(this, arguments) || this;
77
77
  }
78
78
  /**
79
- * Get product secondary types
79
+ * Get product secondary type
80
80
  */
81
- SearchProductMetadataApi.prototype.getProductSecondaryTypesRaw = function () {
81
+ SearchProductMetadataApi.prototype.getProductSecondaryTypeRaw = function (requestParameters) {
82
82
  return __awaiter(this, void 0, void 0, function () {
83
83
  var queryParameters, headerParameters, token, tokenString, response, contentType, response_1;
84
84
  return __generator(this, function (_a) {
85
85
  switch (_a.label) {
86
86
  case 0:
87
+ if (requestParameters.secondaryTypeId === null || requestParameters.secondaryTypeId === undefined) {
88
+ throw new runtime_1.RequiredError('secondaryTypeId', 'Required parameter requestParameters.secondaryTypeId was null or undefined when calling getProductSecondaryType.');
89
+ }
87
90
  queryParameters = {};
88
91
  headerParameters = {};
89
92
  if (this.configuration && this.configuration.apiKey) {
@@ -100,7 +103,7 @@ var SearchProductMetadataApi = /** @class */ (function (_super) {
100
103
  case 1:
101
104
  _a.trys.push([1, 3, , 4]);
102
105
  return [4 /*yield*/, this.request({
103
- path: "/products/secondary-types",
106
+ path: "/products/secondary-types/{secondaryTypeId}".replace("{".concat("secondaryTypeId", "}"), encodeURIComponent(String(requestParameters.secondaryTypeId))),
104
107
  method: 'GET',
105
108
  headers: headerParameters,
106
109
  query: queryParameters,
@@ -109,7 +112,7 @@ var SearchProductMetadataApi = /** @class */ (function (_super) {
109
112
  response = _a.sent();
110
113
  contentType = response.headers.get("content-type");
111
114
  if (contentType && contentType.indexOf("application/json") !== -1) {
112
- return [2 /*return*/, new runtime_1.JSONApiResponse(response, function (jsonValue) { return jsonValue.map(models_1.ProductSecondaryTypeFromJSON); })];
115
+ return [2 /*return*/, new runtime_1.JSONApiResponse(response, function (jsonValue) { return (0, models_1.ProductSecondaryTypeFromJSON)(jsonValue); })];
113
116
  }
114
117
  else if (contentType && contentType.indexOf("text/plain") !== -1) {
115
118
  return [2 /*return*/, new runtime_1.TextApiResponse(response)];
@@ -128,6 +131,76 @@ var SearchProductMetadataApi = /** @class */ (function (_super) {
128
131
  });
129
132
  });
130
133
  };
134
+ /**
135
+ * Get product secondary type
136
+ */
137
+ SearchProductMetadataApi.prototype.getProductSecondaryType = function (requestParameters) {
138
+ return __awaiter(this, void 0, void 0, function () {
139
+ var response;
140
+ return __generator(this, function (_a) {
141
+ switch (_a.label) {
142
+ case 0: return [4 /*yield*/, this.getProductSecondaryTypeRaw(requestParameters)];
143
+ case 1:
144
+ response = _a.sent();
145
+ return [4 /*yield*/, response.value()];
146
+ case 2: return [2 /*return*/, _a.sent()];
147
+ }
148
+ });
149
+ });
150
+ };
151
+ /**
152
+ * Get product secondary types
153
+ */
154
+ SearchProductMetadataApi.prototype.getProductSecondaryTypesRaw = function () {
155
+ return __awaiter(this, void 0, void 0, function () {
156
+ var queryParameters, headerParameters, token, tokenString, response, contentType, response_2;
157
+ return __generator(this, function (_a) {
158
+ switch (_a.label) {
159
+ case 0:
160
+ queryParameters = {};
161
+ headerParameters = {};
162
+ if (this.configuration && this.configuration.apiKey) {
163
+ headerParameters["x-api-key"] = this.configuration.apiKey("x-api-key"); // apiKeyAuth authentication
164
+ }
165
+ if (this.configuration && this.configuration.accessToken) {
166
+ token = this.configuration.accessToken;
167
+ tokenString = typeof token === 'function' ? token("bearerAuth", []) : token;
168
+ if (tokenString) {
169
+ headerParameters["Authorization"] = "Bearer ".concat(tokenString);
170
+ }
171
+ }
172
+ _a.label = 1;
173
+ case 1:
174
+ _a.trys.push([1, 3, , 4]);
175
+ return [4 /*yield*/, this.request({
176
+ path: "/products/secondary-types",
177
+ method: 'GET',
178
+ headers: headerParameters,
179
+ query: queryParameters,
180
+ })];
181
+ case 2:
182
+ response = _a.sent();
183
+ contentType = response.headers.get("content-type");
184
+ if (contentType && contentType.indexOf("application/json") !== -1) {
185
+ return [2 /*return*/, new runtime_1.JSONApiResponse(response, function (jsonValue) { return jsonValue.map(models_1.ProductSecondaryTypeFromJSON); })];
186
+ }
187
+ else if (contentType && contentType.indexOf("text/plain") !== -1) {
188
+ return [2 /*return*/, new runtime_1.TextApiResponse(response)];
189
+ }
190
+ else {
191
+ // TODO : Better handling of others application types
192
+ return [2 /*return*/, new runtime_1.BlobWithMetaApiResponse(response)];
193
+ }
194
+ return [3 /*break*/, 4];
195
+ case 3:
196
+ response_2 = _a.sent();
197
+ console.debug(response_2);
198
+ throw response_2;
199
+ case 4: return [2 /*return*/];
200
+ }
201
+ });
202
+ });
203
+ };
131
204
  /**
132
205
  * Get product secondary types
133
206
  */
@@ -145,12 +218,85 @@ var SearchProductMetadataApi = /** @class */ (function (_super) {
145
218
  });
146
219
  });
147
220
  };
221
+ /**
222
+ * Get product type
223
+ */
224
+ SearchProductMetadataApi.prototype.getProductTypeRaw = function (requestParameters) {
225
+ return __awaiter(this, void 0, void 0, function () {
226
+ var queryParameters, headerParameters, token, tokenString, response, contentType, response_3;
227
+ return __generator(this, function (_a) {
228
+ switch (_a.label) {
229
+ case 0:
230
+ if (requestParameters.typeId === null || requestParameters.typeId === undefined) {
231
+ throw new runtime_1.RequiredError('typeId', 'Required parameter requestParameters.typeId was null or undefined when calling getProductType.');
232
+ }
233
+ queryParameters = {};
234
+ headerParameters = {};
235
+ if (this.configuration && this.configuration.apiKey) {
236
+ headerParameters["x-api-key"] = this.configuration.apiKey("x-api-key"); // apiKeyAuth authentication
237
+ }
238
+ if (this.configuration && this.configuration.accessToken) {
239
+ token = this.configuration.accessToken;
240
+ tokenString = typeof token === 'function' ? token("bearerAuth", []) : token;
241
+ if (tokenString) {
242
+ headerParameters["Authorization"] = "Bearer ".concat(tokenString);
243
+ }
244
+ }
245
+ _a.label = 1;
246
+ case 1:
247
+ _a.trys.push([1, 3, , 4]);
248
+ return [4 /*yield*/, this.request({
249
+ path: "/products/types/{typeId}".replace("{".concat("typeId", "}"), encodeURIComponent(String(requestParameters.typeId))),
250
+ method: 'GET',
251
+ headers: headerParameters,
252
+ query: queryParameters,
253
+ })];
254
+ case 2:
255
+ response = _a.sent();
256
+ contentType = response.headers.get("content-type");
257
+ if (contentType && contentType.indexOf("application/json") !== -1) {
258
+ return [2 /*return*/, new runtime_1.JSONApiResponse(response, function (jsonValue) { return (0, models_1.ProductTypeFromJSON)(jsonValue); })];
259
+ }
260
+ else if (contentType && contentType.indexOf("text/plain") !== -1) {
261
+ return [2 /*return*/, new runtime_1.TextApiResponse(response)];
262
+ }
263
+ else {
264
+ // TODO : Better handling of others application types
265
+ return [2 /*return*/, new runtime_1.BlobWithMetaApiResponse(response)];
266
+ }
267
+ return [3 /*break*/, 4];
268
+ case 3:
269
+ response_3 = _a.sent();
270
+ console.debug(response_3);
271
+ throw response_3;
272
+ case 4: return [2 /*return*/];
273
+ }
274
+ });
275
+ });
276
+ };
277
+ /**
278
+ * Get product type
279
+ */
280
+ SearchProductMetadataApi.prototype.getProductType = function (requestParameters) {
281
+ return __awaiter(this, void 0, void 0, function () {
282
+ var response;
283
+ return __generator(this, function (_a) {
284
+ switch (_a.label) {
285
+ case 0: return [4 /*yield*/, this.getProductTypeRaw(requestParameters)];
286
+ case 1:
287
+ response = _a.sent();
288
+ return [4 /*yield*/, response.value()];
289
+ case 2: return [2 /*return*/, _a.sent()];
290
+ }
291
+ });
292
+ });
293
+ };
148
294
  /**
149
295
  * Get product types
150
296
  */
151
297
  SearchProductMetadataApi.prototype.getProductTypesRaw = function () {
152
298
  return __awaiter(this, void 0, void 0, function () {
153
- var queryParameters, headerParameters, token, tokenString, response, contentType, response_2;
299
+ var queryParameters, headerParameters, token, tokenString, response, contentType, response_4;
154
300
  return __generator(this, function (_a) {
155
301
  switch (_a.label) {
156
302
  case 0:
@@ -190,9 +336,9 @@ var SearchProductMetadataApi = /** @class */ (function (_super) {
190
336
  }
191
337
  return [3 /*break*/, 4];
192
338
  case 3:
193
- response_2 = _a.sent();
194
- console.debug(response_2);
195
- throw response_2;
339
+ response_4 = _a.sent();
340
+ console.debug(response_4);
341
+ throw response_4;
196
342
  case 4: return [2 /*return*/];
197
343
  }
198
344
  });
@@ -14,10 +14,12 @@
14
14
  * @export
15
15
  * @enum {string}
16
16
  */
17
- export declare enum ProductProvider {
17
+ export declare enum DataProvider {
18
18
  VIDAL = "VIDAL",
19
- BCB = "BCB"
19
+ BCB = "BCB",
20
+ LCDP = "LCDP",
21
+ USER = "USER"
20
22
  }
21
- export declare function ProductProviderFromJSON(json: any): ProductProvider;
22
- export declare function ProductProviderFromJSONTyped(json: any, ignoreDiscriminator: boolean): ProductProvider;
23
- export declare function ProductProviderToJSON(value?: ProductProvider | null): any;
23
+ export declare function DataProviderFromJSON(json: any): DataProvider;
24
+ export declare function DataProviderFromJSONTyped(json: any, ignoreDiscriminator: boolean): DataProvider;
25
+ export declare function DataProviderToJSON(value?: DataProvider | null): any;
@@ -0,0 +1,40 @@
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.DataProviderToJSON = exports.DataProviderFromJSONTyped = exports.DataProviderFromJSON = exports.DataProvider = void 0;
17
+ /**
18
+ *
19
+ * @export
20
+ * @enum {string}
21
+ */
22
+ var DataProvider;
23
+ (function (DataProvider) {
24
+ DataProvider["VIDAL"] = "VIDAL";
25
+ DataProvider["BCB"] = "BCB";
26
+ DataProvider["LCDP"] = "LCDP";
27
+ DataProvider["USER"] = "USER";
28
+ })(DataProvider = exports.DataProvider || (exports.DataProvider = {}));
29
+ function DataProviderFromJSON(json) {
30
+ return DataProviderFromJSONTyped(json, false);
31
+ }
32
+ exports.DataProviderFromJSON = DataProviderFromJSON;
33
+ function DataProviderFromJSONTyped(json, ignoreDiscriminator) {
34
+ return json;
35
+ }
36
+ exports.DataProviderFromJSONTyped = DataProviderFromJSONTyped;
37
+ function DataProviderToJSON(value) {
38
+ return value;
39
+ }
40
+ exports.DataProviderToJSON = DataProviderToJSON;
@@ -14,7 +14,7 @@ import { HttpLink } from './HttpLink';
14
14
  import { LaboratoryLink } from './LaboratoryLink';
15
15
  import { ProductDispensationPlace } from './ProductDispensationPlace';
16
16
  import { ProductMarketStatus } from './ProductMarketStatus';
17
- import { ProductProvider } from './ProductProvider';
17
+ import { ProductMetadata } from './ProductMetadata';
18
18
  import { ProductSecondaryType } from './ProductSecondaryType';
19
19
  import { ProductStatus } from './ProductStatus';
20
20
  import { ProductStorageType } from './ProductStorageType';
@@ -32,19 +32,13 @@ export interface Product {
32
32
  * @type {number}
33
33
  * @memberof Product
34
34
  */
35
- id?: number;
35
+ id: number;
36
36
  /**
37
37
  * Indicates if automatic external synchronization is enabled
38
38
  * @type {boolean}
39
39
  * @memberof Product
40
40
  */
41
41
  isExternalSyncEnabled?: boolean;
42
- /**
43
- *
44
- * @type {Array<ProductProvider>}
45
- * @memberof Product
46
- */
47
- providers?: Array<ProductProvider>;
48
42
  /**
49
43
  *
50
44
  * @type {Barcodes}
@@ -56,7 +50,7 @@ export interface Product {
56
50
  * @type {string}
57
51
  * @memberof Product
58
52
  */
59
- name?: string;
53
+ name: string;
60
54
  /**
61
55
  *
62
56
  * @type {string}
@@ -183,6 +177,12 @@ export interface Product {
183
177
  * @memberof Product
184
178
  */
185
179
  tags?: Array<string>;
180
+ /**
181
+ *
182
+ * @type {ProductMetadata}
183
+ * @memberof Product
184
+ */
185
+ metadata: ProductMetadata;
186
186
  }
187
187
  export declare function ProductFromJSON(json: any): Product;
188
188
  export declare function ProductFromJSONTyped(json: any, ignoreDiscriminator: boolean): Product;
@@ -20,7 +20,7 @@ var HttpLink_1 = require("./HttpLink");
20
20
  var LaboratoryLink_1 = require("./LaboratoryLink");
21
21
  var ProductDispensationPlace_1 = require("./ProductDispensationPlace");
22
22
  var ProductMarketStatus_1 = require("./ProductMarketStatus");
23
- var ProductProvider_1 = require("./ProductProvider");
23
+ var ProductMetadata_1 = require("./ProductMetadata");
24
24
  var ProductSecondaryType_1 = require("./ProductSecondaryType");
25
25
  var ProductStatus_1 = require("./ProductStatus");
26
26
  var ProductStorageType_1 = require("./ProductStorageType");
@@ -36,11 +36,10 @@ function ProductFromJSONTyped(json, ignoreDiscriminator) {
36
36
  return json;
37
37
  }
38
38
  return {
39
- 'id': !(0, runtime_1.exists)(json, 'id') ? undefined : json['id'],
39
+ 'id': json['id'],
40
40
  'isExternalSyncEnabled': !(0, runtime_1.exists)(json, 'isExternalSyncEnabled') ? undefined : json['isExternalSyncEnabled'],
41
- 'providers': !(0, runtime_1.exists)(json, 'providers') ? undefined : (json['providers'].map(ProductProvider_1.ProductProviderFromJSON)),
42
41
  'barcodes': !(0, runtime_1.exists)(json, 'barcodes') ? undefined : (0, Barcodes_1.BarcodesFromJSON)(json['barcodes']),
43
- 'name': !(0, runtime_1.exists)(json, 'name') ? undefined : json['name'],
42
+ 'name': json['name'],
44
43
  'shortName': !(0, runtime_1.exists)(json, 'shortName') ? json['shortName'] : json['shortName'],
45
44
  'dci': !(0, runtime_1.exists)(json, 'dci') ? json['dci'] : json['dci'],
46
45
  'unitWeight': !(0, runtime_1.exists)(json, 'unitWeight') ? json['unitWeight'] : json['unitWeight'],
@@ -62,6 +61,7 @@ function ProductFromJSONTyped(json, ignoreDiscriminator) {
62
61
  'restricted': !(0, runtime_1.exists)(json, 'restricted') ? undefined : json['restricted'],
63
62
  'proscriptions': !(0, runtime_1.exists)(json, 'proscriptions') ? undefined : (0, HttpLink_1.HttpLinkFromJSON)(json['proscriptions']),
64
63
  'tags': !(0, runtime_1.exists)(json, 'tags') ? undefined : json['tags'],
64
+ 'metadata': (0, ProductMetadata_1.ProductMetadataFromJSON)(json['metadata']),
65
65
  };
66
66
  }
67
67
  exports.ProductFromJSONTyped = ProductFromJSONTyped;
@@ -75,7 +75,6 @@ function ProductToJSON(value) {
75
75
  return {
76
76
  'id': value.id,
77
77
  'isExternalSyncEnabled': value.isExternalSyncEnabled,
78
- 'providers': value.providers === undefined ? undefined : (value.providers.map(ProductProvider_1.ProductProviderToJSON)),
79
78
  'barcodes': (0, Barcodes_1.BarcodesToJSON)(value.barcodes),
80
79
  'name': value.name,
81
80
  'shortName': value.shortName,
@@ -99,6 +98,7 @@ function ProductToJSON(value) {
99
98
  'restricted': value.restricted,
100
99
  'proscriptions': (0, HttpLink_1.HttpLinkToJSON)(value.proscriptions),
101
100
  'tags': value.tags,
101
+ 'metadata': (0, ProductMetadata_1.ProductMetadataToJSON)(value.metadata),
102
102
  };
103
103
  }
104
104
  exports.ProductToJSON = ProductToJSON;
@@ -0,0 +1,28 @@
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
+ import { ProductMetadataSources } from './ProductMetadataSources';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface ProductMetadata
17
+ */
18
+ export interface ProductMetadata {
19
+ /**
20
+ *
21
+ * @type {ProductMetadataSources}
22
+ * @memberof ProductMetadata
23
+ */
24
+ sources: ProductMetadataSources;
25
+ }
26
+ export declare function ProductMetadataFromJSON(json: any): ProductMetadata;
27
+ export declare function ProductMetadataFromJSONTyped(json: any, ignoreDiscriminator: boolean): ProductMetadata;
28
+ export declare function ProductMetadataToJSON(value?: ProductMetadata | null): any;
@@ -0,0 +1,42 @@
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.ProductMetadataToJSON = exports.ProductMetadataFromJSONTyped = exports.ProductMetadataFromJSON = void 0;
17
+ var ProductMetadataSources_1 = require("./ProductMetadataSources");
18
+ function ProductMetadataFromJSON(json) {
19
+ return ProductMetadataFromJSONTyped(json, false);
20
+ }
21
+ exports.ProductMetadataFromJSON = ProductMetadataFromJSON;
22
+ function ProductMetadataFromJSONTyped(json, ignoreDiscriminator) {
23
+ if ((json === undefined) || (json === null)) {
24
+ return json;
25
+ }
26
+ return {
27
+ 'sources': (0, ProductMetadataSources_1.ProductMetadataSourcesFromJSON)(json['sources']),
28
+ };
29
+ }
30
+ exports.ProductMetadataFromJSONTyped = ProductMetadataFromJSONTyped;
31
+ function ProductMetadataToJSON(value) {
32
+ if (value === undefined) {
33
+ return undefined;
34
+ }
35
+ if (value === null) {
36
+ return null;
37
+ }
38
+ return {
39
+ 'sources': (0, ProductMetadataSources_1.ProductMetadataSourcesToJSON)(value.sources),
40
+ };
41
+ }
42
+ exports.ProductMetadataToJSON = ProductMetadataToJSON;
@@ -0,0 +1,88 @@
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
+ import { DataProvider } from './DataProvider';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface ProductMetadataSources
17
+ */
18
+ export interface ProductMetadataSources {
19
+ /**
20
+ *
21
+ * @type {DataProvider}
22
+ * @memberof ProductMetadataSources
23
+ */
24
+ barcodes: DataProvider;
25
+ /**
26
+ *
27
+ * @type {DataProvider}
28
+ * @memberof ProductMetadataSources
29
+ */
30
+ name: DataProvider;
31
+ /**
32
+ *
33
+ * @type {DataProvider}
34
+ * @memberof ProductMetadataSources
35
+ */
36
+ dci: DataProvider;
37
+ /**
38
+ *
39
+ * @type {DataProvider}
40
+ * @memberof ProductMetadataSources
41
+ */
42
+ unitWeight: DataProvider;
43
+ /**
44
+ *
45
+ * @type {DataProvider}
46
+ * @memberof ProductMetadataSources
47
+ */
48
+ unitPrice: DataProvider;
49
+ /**
50
+ *
51
+ * @type {DataProvider}
52
+ * @memberof ProductMetadataSources
53
+ */
54
+ type: DataProvider;
55
+ /**
56
+ *
57
+ * @type {DataProvider}
58
+ * @memberof ProductMetadataSources
59
+ */
60
+ secondaryType: DataProvider;
61
+ /**
62
+ *
63
+ * @type {DataProvider}
64
+ * @memberof ProductMetadataSources
65
+ */
66
+ laboratory: DataProvider;
67
+ /**
68
+ *
69
+ * @type {DataProvider}
70
+ * @memberof ProductMetadataSources
71
+ */
72
+ vat: DataProvider;
73
+ /**
74
+ *
75
+ * @type {DataProvider}
76
+ * @memberof ProductMetadataSources
77
+ */
78
+ storageType: DataProvider;
79
+ /**
80
+ *
81
+ * @type {Array<DataProvider>}
82
+ * @memberof ProductMetadataSources
83
+ */
84
+ images: Array<DataProvider>;
85
+ }
86
+ export declare function ProductMetadataSourcesFromJSON(json: any): ProductMetadataSources;
87
+ export declare function ProductMetadataSourcesFromJSONTyped(json: any, ignoreDiscriminator: boolean): ProductMetadataSources;
88
+ export declare function ProductMetadataSourcesToJSON(value?: ProductMetadataSources | null): any;
@@ -0,0 +1,62 @@
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.ProductMetadataSourcesToJSON = exports.ProductMetadataSourcesFromJSONTyped = exports.ProductMetadataSourcesFromJSON = void 0;
17
+ var DataProvider_1 = require("./DataProvider");
18
+ function ProductMetadataSourcesFromJSON(json) {
19
+ return ProductMetadataSourcesFromJSONTyped(json, false);
20
+ }
21
+ exports.ProductMetadataSourcesFromJSON = ProductMetadataSourcesFromJSON;
22
+ function ProductMetadataSourcesFromJSONTyped(json, ignoreDiscriminator) {
23
+ if ((json === undefined) || (json === null)) {
24
+ return json;
25
+ }
26
+ return {
27
+ 'barcodes': (0, DataProvider_1.DataProviderFromJSON)(json['barcodes']),
28
+ 'name': (0, DataProvider_1.DataProviderFromJSON)(json['name']),
29
+ 'dci': (0, DataProvider_1.DataProviderFromJSON)(json['dci']),
30
+ 'unitWeight': (0, DataProvider_1.DataProviderFromJSON)(json['unitWeight']),
31
+ 'unitPrice': (0, DataProvider_1.DataProviderFromJSON)(json['unitPrice']),
32
+ 'type': (0, DataProvider_1.DataProviderFromJSON)(json['type']),
33
+ 'secondaryType': (0, DataProvider_1.DataProviderFromJSON)(json['secondaryType']),
34
+ 'laboratory': (0, DataProvider_1.DataProviderFromJSON)(json['laboratory']),
35
+ 'vat': (0, DataProvider_1.DataProviderFromJSON)(json['vat']),
36
+ 'storageType': (0, DataProvider_1.DataProviderFromJSON)(json['storageType']),
37
+ 'images': (json['images'].map(DataProvider_1.DataProviderFromJSON)),
38
+ };
39
+ }
40
+ exports.ProductMetadataSourcesFromJSONTyped = ProductMetadataSourcesFromJSONTyped;
41
+ function ProductMetadataSourcesToJSON(value) {
42
+ if (value === undefined) {
43
+ return undefined;
44
+ }
45
+ if (value === null) {
46
+ return null;
47
+ }
48
+ return {
49
+ 'barcodes': (0, DataProvider_1.DataProviderToJSON)(value.barcodes),
50
+ 'name': (0, DataProvider_1.DataProviderToJSON)(value.name),
51
+ 'dci': (0, DataProvider_1.DataProviderToJSON)(value.dci),
52
+ 'unitWeight': (0, DataProvider_1.DataProviderToJSON)(value.unitWeight),
53
+ 'unitPrice': (0, DataProvider_1.DataProviderToJSON)(value.unitPrice),
54
+ 'type': (0, DataProvider_1.DataProviderToJSON)(value.type),
55
+ 'secondaryType': (0, DataProvider_1.DataProviderToJSON)(value.secondaryType),
56
+ 'laboratory': (0, DataProvider_1.DataProviderToJSON)(value.laboratory),
57
+ 'vat': (0, DataProvider_1.DataProviderToJSON)(value.vat),
58
+ 'storageType': (0, DataProvider_1.DataProviderToJSON)(value.storageType),
59
+ 'images': (value.images.map(DataProvider_1.DataProviderToJSON)),
60
+ };
61
+ }
62
+ exports.ProductMetadataSourcesToJSON = ProductMetadataSourcesToJSON;
@@ -1,4 +1,5 @@
1
1
  export * from './Barcodes';
2
+ export * from './DataProvider';
2
3
  export * from './HttpLink';
3
4
  export * from './Image';
4
5
  export * from './ImageCreationParameters';
@@ -15,9 +16,10 @@ export * from './Product';
15
16
  export * from './ProductCreationOrUpdateParameters';
16
17
  export * from './ProductDispensationPlace';
17
18
  export * from './ProductMarketStatus';
19
+ export * from './ProductMetadata';
20
+ export * from './ProductMetadataSources';
18
21
  export * from './ProductProscription';
19
22
  export * from './ProductProscriptionCreationParameters';
20
- export * from './ProductProvider';
21
23
  export * from './ProductSecondaryType';
22
24
  export * from './ProductStatus';
23
25
  export * from './ProductStorageType';
@@ -15,6 +15,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./Barcodes"), exports);
18
+ __exportStar(require("./DataProvider"), exports);
18
19
  __exportStar(require("./HttpLink"), exports);
19
20
  __exportStar(require("./Image"), exports);
20
21
  __exportStar(require("./ImageCreationParameters"), exports);
@@ -31,9 +32,10 @@ __exportStar(require("./Product"), exports);
31
32
  __exportStar(require("./ProductCreationOrUpdateParameters"), exports);
32
33
  __exportStar(require("./ProductDispensationPlace"), exports);
33
34
  __exportStar(require("./ProductMarketStatus"), exports);
35
+ __exportStar(require("./ProductMetadata"), exports);
36
+ __exportStar(require("./ProductMetadataSources"), exports);
34
37
  __exportStar(require("./ProductProscription"), exports);
35
38
  __exportStar(require("./ProductProscriptionCreationParameters"), exports);
36
- __exportStar(require("./ProductProvider"), exports);
37
39
  __exportStar(require("./ProductSecondaryType"), exports);
38
40
  __exportStar(require("./ProductStatus"), exports);
39
41
  __exportStar(require("./ProductStorageType"), exports);
@@ -1,38 +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.ProductProviderToJSON = exports.ProductProviderFromJSONTyped = exports.ProductProviderFromJSON = exports.ProductProvider = void 0;
17
- /**
18
- *
19
- * @export
20
- * @enum {string}
21
- */
22
- var ProductProvider;
23
- (function (ProductProvider) {
24
- ProductProvider["VIDAL"] = "VIDAL";
25
- ProductProvider["BCB"] = "BCB";
26
- })(ProductProvider = exports.ProductProvider || (exports.ProductProvider = {}));
27
- function ProductProviderFromJSON(json) {
28
- return ProductProviderFromJSONTyped(json, false);
29
- }
30
- exports.ProductProviderFromJSON = ProductProviderFromJSON;
31
- function ProductProviderFromJSONTyped(json, ignoreDiscriminator) {
32
- return json;
33
- }
34
- exports.ProductProviderFromJSONTyped = ProductProviderFromJSONTyped;
35
- function ProductProviderToJSON(value) {
36
- return value;
37
- }
38
- exports.ProductProviderToJSON = ProductProviderToJSON;