@lcdp/api-react-rest-client 2.9.0-upgrade-codegen-client-react.12586609052 → 2.9.1-develop.13139572022
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/auth/src/models/RestError.d.ts +4 -2
- package/auth/src/models/RestError.js +4 -2
- package/auth/src/runtime.js +11 -2
- package/banking-operation/src/runtime.js +11 -2
- package/catalog/src/models/RestError.d.ts +4 -2
- package/catalog/src/models/RestError.js +4 -2
- package/catalog/src/runtime.js +11 -2
- package/challenge/src/runtime.js +11 -2
- package/configuration/src/models/RestError.d.ts +4 -2
- package/configuration/src/models/RestError.js +4 -2
- package/configuration/src/runtime.js +11 -2
- package/content/src/models/RestError.d.ts +4 -2
- package/content/src/models/RestError.js +4 -2
- package/content/src/runtime.js +11 -2
- package/factory/src/runtime.js +11 -2
- package/favorite/src/models/RestError.d.ts +4 -2
- package/favorite/src/models/RestError.js +4 -2
- package/favorite/src/runtime.js +11 -2
- package/geo/src/runtime.js +11 -2
- package/inventory/src/apis/ManageInventoryApi.d.ts +5 -17
- package/inventory/src/apis/ManageInventoryApi.js +12 -86
- package/inventory/src/apis/SearchInventoryApi.d.ts +29 -22
- package/inventory/src/apis/SearchInventoryApi.js +106 -87
- package/inventory/src/models/ActiveProduct.d.ts +10 -3
- package/inventory/src/models/ActiveProduct.js +5 -2
- package/inventory/src/models/ActiveProductUpdateParameters.d.ts +4 -3
- package/inventory/src/models/ActiveProductUpdateParameters.js +3 -2
- package/inventory/src/models/Inventory.d.ts +63 -0
- package/inventory/src/models/Inventory.js +57 -0
- package/inventory/src/models/InventoryJournal.d.ts +31 -0
- package/inventory/src/models/InventoryJournal.js +45 -0
- package/inventory/src/models/MisalignedProduct.d.ts +6 -0
- package/inventory/src/models/MisalignedProduct.js +2 -0
- package/inventory/src/models/OverstockProduct.d.ts +6 -0
- package/inventory/src/models/OverstockProduct.js +2 -0
- package/inventory/src/models/PaginatedInventories.d.ts +39 -0
- package/inventory/src/models/PaginatedInventories.js +53 -0
- package/inventory/src/models/RestError.d.ts +4 -2
- package/inventory/src/models/RestError.js +4 -2
- package/inventory/src/models/SynchronizationMode.d.ts +25 -0
- package/inventory/src/models/SynchronizationMode.js +48 -0
- package/inventory/src/models/index.d.ts +4 -3
- package/inventory/src/models/index.js +4 -3
- package/inventory/src/runtime.js +11 -2
- package/invoice/src/models/RestError.d.ts +4 -2
- package/invoice/src/models/RestError.js +4 -2
- package/invoice/src/runtime.js +11 -2
- package/laboratory/src/runtime.js +11 -2
- package/laboratory-store/src/models/RestError.d.ts +4 -2
- package/laboratory-store/src/models/RestError.js +4 -2
- package/laboratory-store/src/runtime.js +11 -2
- package/laboratory-store-log/src/runtime.js +11 -2
- package/lexicon/src/models/RestError.d.ts +4 -2
- package/lexicon/src/models/RestError.js +4 -2
- package/lexicon/src/runtime.js +11 -2
- package/litigation/src/models/RestError.d.ts +4 -2
- package/litigation/src/models/RestError.js +4 -2
- package/litigation/src/runtime.js +11 -2
- package/magic-cart/src/runtime.js +11 -2
- package/mandate/src/runtime.js +11 -2
- package/mangopay-hook/src/models/RestError.d.ts +4 -2
- package/mangopay-hook/src/models/RestError.js +4 -2
- package/mangopay-hook/src/runtime.js +11 -2
- package/message/src/runtime.js +11 -2
- package/notification/src/models/RestError.d.ts +4 -2
- package/notification/src/models/RestError.js +4 -2
- package/notification/src/runtime.js +11 -2
- package/order/src/models/RestError.d.ts +4 -2
- package/order/src/models/RestError.js +4 -2
- package/order/src/runtime.js +11 -2
- package/order-log/src/runtime.js +11 -2
- package/outrage-message/src/runtime.js +11 -2
- package/package.json +1 -1
- package/product/src/models/RestError.d.ts +4 -2
- package/product/src/models/RestError.js +4 -2
- package/product/src/runtime.js +11 -2
- package/pub/src/models/RestError.d.ts +4 -2
- package/pub/src/models/RestError.js +4 -2
- package/pub/src/runtime.js +11 -2
- package/recommendation/src/runtime.js +11 -2
- package/rfx/src/models/RestError.d.ts +4 -2
- package/rfx/src/models/RestError.js +4 -2
- package/rfx/src/runtime.js +11 -2
- package/sale-offer/src/models/RestError.d.ts +4 -2
- package/sale-offer/src/models/RestError.js +4 -2
- package/sale-offer/src/runtime.js +11 -2
- package/sale-offer-log/src/runtime.js +11 -2
- package/servant/src/models/RestError.d.ts +4 -2
- package/servant/src/models/RestError.js +4 -2
- package/servant/src/runtime.js +11 -2
- package/shipment/src/models/RestError.d.ts +4 -2
- package/shipment/src/models/RestError.js +4 -2
- package/shipment/src/runtime.js +11 -2
- package/shopping-cart/src/models/RestError.d.ts +4 -2
- package/shopping-cart/src/models/RestError.js +4 -2
- package/shopping-cart/src/runtime.js +11 -2
- package/smuggler/src/models/RestError.d.ts +4 -2
- package/smuggler/src/models/RestError.js +4 -2
- package/smuggler/src/runtime.js +11 -2
- package/statistic/src/models/RestError.d.ts +4 -2
- package/statistic/src/models/RestError.js +4 -2
- package/statistic/src/runtime.js +11 -2
- package/subscription/src/models/RestError.d.ts +4 -2
- package/subscription/src/models/RestError.js +4 -2
- package/subscription/src/runtime.js +11 -2
- package/third-party/src/models/RestError.d.ts +4 -2
- package/third-party/src/models/RestError.js +4 -2
- package/third-party/src/runtime.js +11 -2
- package/thread/src/runtime.js +11 -2
- package/ubo/src/models/RestError.d.ts +4 -2
- package/ubo/src/models/RestError.js +4 -2
- package/ubo/src/runtime.js +11 -2
- package/user/src/models/RestError.d.ts +4 -2
- package/user/src/models/RestError.js +4 -2
- package/user/src/runtime.js +11 -2
- package/wish/src/models/RestError.d.ts +4 -2
- package/wish/src/models/RestError.js +4 -2
- package/wish/src/runtime.js +11 -2
- package/inventory/src/models/Synchroneity.d.ts +0 -32
- package/inventory/src/models/Synchroneity.js +0 -46
- package/inventory/src/models/SynchroneityOffisante.d.ts +0 -38
- package/inventory/src/models/SynchroneityOffisante.js +0 -48
- package/inventory/src/models/SynchroneitySource.d.ts +0 -37
- package/inventory/src/models/SynchroneitySource.js +0 -47
|
@@ -378,13 +378,19 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
378
378
|
/**
|
|
379
379
|
* Get advices statistics
|
|
380
380
|
*/
|
|
381
|
-
SearchInventoryApi.prototype.getCurrentInventoryStatisticsRaw = function (initOverrides) {
|
|
381
|
+
SearchInventoryApi.prototype.getCurrentInventoryStatisticsRaw = function (requestParameters, initOverrides) {
|
|
382
382
|
return __awaiter(this, void 0, void 0, function () {
|
|
383
383
|
var queryParameters, headerParameters, _a, _b, token, tokenString, response, contentType, response_4;
|
|
384
384
|
return __generator(this, function (_c) {
|
|
385
385
|
switch (_c.label) {
|
|
386
386
|
case 0:
|
|
387
387
|
queryParameters = {};
|
|
388
|
+
if (requestParameters['overstockBlEq'] != null) {
|
|
389
|
+
queryParameters['overstockBl[eq]'] = requestParameters['overstockBlEq'];
|
|
390
|
+
}
|
|
391
|
+
if (requestParameters['overstockForecastGte'] != null) {
|
|
392
|
+
queryParameters['overstockForecast[gte]'] = requestParameters['overstockForecastGte'];
|
|
393
|
+
}
|
|
388
394
|
headerParameters = {};
|
|
389
395
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 2];
|
|
390
396
|
_a = headerParameters;
|
|
@@ -437,12 +443,13 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
437
443
|
/**
|
|
438
444
|
* Get advices statistics
|
|
439
445
|
*/
|
|
440
|
-
SearchInventoryApi.prototype.getCurrentInventoryStatistics = function (initOverrides) {
|
|
446
|
+
SearchInventoryApi.prototype.getCurrentInventoryStatistics = function (requestParameters, initOverrides) {
|
|
447
|
+
if (requestParameters === void 0) { requestParameters = {}; }
|
|
441
448
|
return __awaiter(this, void 0, void 0, function () {
|
|
442
449
|
var response;
|
|
443
450
|
return __generator(this, function (_a) {
|
|
444
451
|
switch (_a.label) {
|
|
445
|
-
case 0: return [4 /*yield*/, this.getCurrentInventoryStatisticsRaw(initOverrides)];
|
|
452
|
+
case 0: return [4 /*yield*/, this.getCurrentInventoryStatisticsRaw(requestParameters, initOverrides)];
|
|
446
453
|
case 1:
|
|
447
454
|
response = _a.sent();
|
|
448
455
|
return [4 /*yield*/, response.value()];
|
|
@@ -452,16 +459,24 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
452
459
|
});
|
|
453
460
|
};
|
|
454
461
|
/**
|
|
455
|
-
*
|
|
456
|
-
* Get synchronization state of inventory
|
|
462
|
+
* Get all inventories
|
|
457
463
|
*/
|
|
458
|
-
SearchInventoryApi.prototype.
|
|
464
|
+
SearchInventoryApi.prototype.getInventoriesRaw = function (requestParameters, initOverrides) {
|
|
459
465
|
return __awaiter(this, void 0, void 0, function () {
|
|
460
466
|
var queryParameters, headerParameters, _a, _b, token, tokenString, response, contentType, response_5;
|
|
461
467
|
return __generator(this, function (_c) {
|
|
462
468
|
switch (_c.label) {
|
|
463
469
|
case 0:
|
|
464
470
|
queryParameters = {};
|
|
471
|
+
if (requestParameters['idEq'] != null) {
|
|
472
|
+
queryParameters['id[eq]'] = requestParameters['idEq'];
|
|
473
|
+
}
|
|
474
|
+
if (requestParameters['p'] != null) {
|
|
475
|
+
queryParameters['p'] = requestParameters['p'];
|
|
476
|
+
}
|
|
477
|
+
if (requestParameters['pp'] != null) {
|
|
478
|
+
queryParameters['pp'] = requestParameters['pp'];
|
|
479
|
+
}
|
|
465
480
|
headerParameters = {};
|
|
466
481
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 2];
|
|
467
482
|
_a = headerParameters;
|
|
@@ -483,7 +498,7 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
483
498
|
case 4:
|
|
484
499
|
_c.trys.push([4, 6, , 7]);
|
|
485
500
|
return [4 /*yield*/, this.request({
|
|
486
|
-
path: "/inventories
|
|
501
|
+
path: "/inventories",
|
|
487
502
|
method: 'GET',
|
|
488
503
|
headers: headerParameters,
|
|
489
504
|
query: queryParameters,
|
|
@@ -492,7 +507,7 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
492
507
|
response = _c.sent();
|
|
493
508
|
contentType = response.headers.get("content-type");
|
|
494
509
|
if (contentType && contentType.indexOf("application/json") !== -1) {
|
|
495
|
-
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.
|
|
510
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.PaginatedInventoriesFromJSON)(jsonValue); })];
|
|
496
511
|
}
|
|
497
512
|
else if (contentType && contentType.indexOf("text/plain") !== -1) {
|
|
498
513
|
return [2 /*return*/, new runtime.TextApiResponse(response)];
|
|
@@ -512,15 +527,15 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
512
527
|
});
|
|
513
528
|
};
|
|
514
529
|
/**
|
|
515
|
-
*
|
|
516
|
-
* Get synchronization state of inventory
|
|
530
|
+
* Get all inventories
|
|
517
531
|
*/
|
|
518
|
-
SearchInventoryApi.prototype.
|
|
532
|
+
SearchInventoryApi.prototype.getInventories = function (requestParameters, initOverrides) {
|
|
533
|
+
if (requestParameters === void 0) { requestParameters = {}; }
|
|
519
534
|
return __awaiter(this, void 0, void 0, function () {
|
|
520
535
|
var response;
|
|
521
536
|
return __generator(this, function (_a) {
|
|
522
537
|
switch (_a.label) {
|
|
523
|
-
case 0: return [4 /*yield*/, this.
|
|
538
|
+
case 0: return [4 /*yield*/, this.getInventoriesRaw(requestParameters, initOverrides)];
|
|
524
539
|
case 1:
|
|
525
540
|
response = _a.sent();
|
|
526
541
|
return [4 /*yield*/, response.value()];
|
|
@@ -530,36 +545,18 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
530
545
|
});
|
|
531
546
|
};
|
|
532
547
|
/**
|
|
533
|
-
*
|
|
548
|
+
* Get inventory by id
|
|
534
549
|
*/
|
|
535
|
-
SearchInventoryApi.prototype.
|
|
550
|
+
SearchInventoryApi.prototype.getInventoryRaw = function (requestParameters, initOverrides) {
|
|
536
551
|
return __awaiter(this, void 0, void 0, function () {
|
|
537
552
|
var queryParameters, headerParameters, _a, _b, token, tokenString, response, contentType, response_6;
|
|
538
553
|
return __generator(this, function (_c) {
|
|
539
554
|
switch (_c.label) {
|
|
540
555
|
case 0:
|
|
541
556
|
if (requestParameters['inventoryId'] == null) {
|
|
542
|
-
throw new runtime.RequiredError('inventoryId', 'Required parameter "inventoryId" was null or undefined when calling
|
|
557
|
+
throw new runtime.RequiredError('inventoryId', 'Required parameter "inventoryId" was null or undefined when calling getInventory().');
|
|
543
558
|
}
|
|
544
559
|
queryParameters = {};
|
|
545
|
-
if (requestParameters['q'] != null) {
|
|
546
|
-
queryParameters['q'] = requestParameters['q'];
|
|
547
|
-
}
|
|
548
|
-
if (requestParameters['labEq'] != null) {
|
|
549
|
-
queryParameters['lab[eq]'] = requestParameters['labEq'];
|
|
550
|
-
}
|
|
551
|
-
if (requestParameters['ptEq'] != null) {
|
|
552
|
-
queryParameters['pt[eq]'] = requestParameters['ptEq'];
|
|
553
|
-
}
|
|
554
|
-
if (requestParameters['orderBy'] != null) {
|
|
555
|
-
queryParameters['orderBy'] = requestParameters['orderBy'];
|
|
556
|
-
}
|
|
557
|
-
if (requestParameters['p'] != null) {
|
|
558
|
-
queryParameters['p'] = requestParameters['p'];
|
|
559
|
-
}
|
|
560
|
-
if (requestParameters['pp'] != null) {
|
|
561
|
-
queryParameters['pp'] = requestParameters['pp'];
|
|
562
|
-
}
|
|
563
560
|
headerParameters = {};
|
|
564
561
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 2];
|
|
565
562
|
_a = headerParameters;
|
|
@@ -581,7 +578,7 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
581
578
|
case 4:
|
|
582
579
|
_c.trys.push([4, 6, , 7]);
|
|
583
580
|
return [4 /*yield*/, this.request({
|
|
584
|
-
path: "/inventories/{inventoryId}
|
|
581
|
+
path: "/inventories/{inventoryId}".replace("{".concat("inventoryId", "}"), encodeURIComponent(String(requestParameters['inventoryId']))),
|
|
585
582
|
method: 'GET',
|
|
586
583
|
headers: headerParameters,
|
|
587
584
|
query: queryParameters,
|
|
@@ -590,7 +587,7 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
590
587
|
response = _c.sent();
|
|
591
588
|
contentType = response.headers.get("content-type");
|
|
592
589
|
if (contentType && contentType.indexOf("application/json") !== -1) {
|
|
593
|
-
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.
|
|
590
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.InventoryFromJSON)(jsonValue); })];
|
|
594
591
|
}
|
|
595
592
|
else if (contentType && contentType.indexOf("text/plain") !== -1) {
|
|
596
593
|
return [2 /*return*/, new runtime.TextApiResponse(response)];
|
|
@@ -610,14 +607,14 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
610
607
|
});
|
|
611
608
|
};
|
|
612
609
|
/**
|
|
613
|
-
*
|
|
610
|
+
* Get inventory by id
|
|
614
611
|
*/
|
|
615
|
-
SearchInventoryApi.prototype.
|
|
612
|
+
SearchInventoryApi.prototype.getInventory = function (requestParameters, initOverrides) {
|
|
616
613
|
return __awaiter(this, void 0, void 0, function () {
|
|
617
614
|
var response;
|
|
618
615
|
return __generator(this, function (_a) {
|
|
619
616
|
switch (_a.label) {
|
|
620
|
-
case 0: return [4 /*yield*/, this.
|
|
617
|
+
case 0: return [4 /*yield*/, this.getInventoryRaw(requestParameters, initOverrides)];
|
|
621
618
|
case 1:
|
|
622
619
|
response = _a.sent();
|
|
623
620
|
return [4 /*yield*/, response.value()];
|
|
@@ -627,16 +624,16 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
627
624
|
});
|
|
628
625
|
};
|
|
629
626
|
/**
|
|
630
|
-
*
|
|
627
|
+
* Search products with params for an inventory
|
|
631
628
|
*/
|
|
632
|
-
SearchInventoryApi.prototype.
|
|
629
|
+
SearchInventoryApi.prototype.getInventoryActiveProductsRaw = function (requestParameters, initOverrides) {
|
|
633
630
|
return __awaiter(this, void 0, void 0, function () {
|
|
634
631
|
var queryParameters, headerParameters, _a, _b, token, tokenString, response, contentType, response_7;
|
|
635
632
|
return __generator(this, function (_c) {
|
|
636
633
|
switch (_c.label) {
|
|
637
634
|
case 0:
|
|
638
635
|
if (requestParameters['inventoryId'] == null) {
|
|
639
|
-
throw new runtime.RequiredError('inventoryId', 'Required parameter "inventoryId" was null or undefined when calling
|
|
636
|
+
throw new runtime.RequiredError('inventoryId', 'Required parameter "inventoryId" was null or undefined when calling getInventoryActiveProducts().');
|
|
640
637
|
}
|
|
641
638
|
queryParameters = {};
|
|
642
639
|
if (requestParameters['q'] != null) {
|
|
@@ -678,7 +675,7 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
678
675
|
case 4:
|
|
679
676
|
_c.trys.push([4, 6, , 7]);
|
|
680
677
|
return [4 /*yield*/, this.request({
|
|
681
|
-
path: "/inventories/{inventoryId}/
|
|
678
|
+
path: "/inventories/{inventoryId}/active-products".replace("{".concat("inventoryId", "}"), encodeURIComponent(String(requestParameters['inventoryId']))),
|
|
682
679
|
method: 'GET',
|
|
683
680
|
headers: headerParameters,
|
|
684
681
|
query: queryParameters,
|
|
@@ -687,7 +684,7 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
687
684
|
response = _c.sent();
|
|
688
685
|
contentType = response.headers.get("content-type");
|
|
689
686
|
if (contentType && contentType.indexOf("application/json") !== -1) {
|
|
690
|
-
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.
|
|
687
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.PaginatedActiveProductsFromJSON)(jsonValue); })];
|
|
691
688
|
}
|
|
692
689
|
else if (contentType && contentType.indexOf("text/plain") !== -1) {
|
|
693
690
|
return [2 /*return*/, new runtime.TextApiResponse(response)];
|
|
@@ -707,14 +704,14 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
707
704
|
});
|
|
708
705
|
};
|
|
709
706
|
/**
|
|
710
|
-
*
|
|
707
|
+
* Search products with params for an inventory
|
|
711
708
|
*/
|
|
712
|
-
SearchInventoryApi.prototype.
|
|
709
|
+
SearchInventoryApi.prototype.getInventoryActiveProducts = function (requestParameters, initOverrides) {
|
|
713
710
|
return __awaiter(this, void 0, void 0, function () {
|
|
714
711
|
var response;
|
|
715
712
|
return __generator(this, function (_a) {
|
|
716
713
|
switch (_a.label) {
|
|
717
|
-
case 0: return [4 /*yield*/, this.
|
|
714
|
+
case 0: return [4 /*yield*/, this.getInventoryActiveProductsRaw(requestParameters, initOverrides)];
|
|
718
715
|
case 1:
|
|
719
716
|
response = _a.sent();
|
|
720
717
|
return [4 /*yield*/, response.value()];
|
|
@@ -724,16 +721,16 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
724
721
|
});
|
|
725
722
|
};
|
|
726
723
|
/**
|
|
727
|
-
* Get
|
|
724
|
+
* Get product\'s where an action is required
|
|
728
725
|
*/
|
|
729
|
-
SearchInventoryApi.prototype.
|
|
726
|
+
SearchInventoryApi.prototype.getInventoryMisalignedProductsRaw = function (requestParameters, initOverrides) {
|
|
730
727
|
return __awaiter(this, void 0, void 0, function () {
|
|
731
728
|
var queryParameters, headerParameters, _a, _b, token, tokenString, response, contentType, response_8;
|
|
732
729
|
return __generator(this, function (_c) {
|
|
733
730
|
switch (_c.label) {
|
|
734
731
|
case 0:
|
|
735
732
|
if (requestParameters['inventoryId'] == null) {
|
|
736
|
-
throw new runtime.RequiredError('inventoryId', 'Required parameter "inventoryId" was null or undefined when calling
|
|
733
|
+
throw new runtime.RequiredError('inventoryId', 'Required parameter "inventoryId" was null or undefined when calling getInventoryMisalignedProducts().');
|
|
737
734
|
}
|
|
738
735
|
queryParameters = {};
|
|
739
736
|
if (requestParameters['q'] != null) {
|
|
@@ -745,21 +742,6 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
745
742
|
if (requestParameters['ptEq'] != null) {
|
|
746
743
|
queryParameters['pt[eq]'] = requestParameters['ptEq'];
|
|
747
744
|
}
|
|
748
|
-
if (requestParameters['blEq'] != null) {
|
|
749
|
-
queryParameters['bl[eq]'] = requestParameters['blEq'];
|
|
750
|
-
}
|
|
751
|
-
if (requestParameters['forecastGte'] != null) {
|
|
752
|
-
queryParameters['forecast[gte]'] = requestParameters['forecastGte'];
|
|
753
|
-
}
|
|
754
|
-
if (requestParameters['forecastLte'] != null) {
|
|
755
|
-
queryParameters['forecast[lte]'] = requestParameters['forecastLte'];
|
|
756
|
-
}
|
|
757
|
-
if (requestParameters['forecastPr'] != null) {
|
|
758
|
-
queryParameters['forecast[pr]'] = requestParameters['forecastPr'];
|
|
759
|
-
}
|
|
760
|
-
if (requestParameters['isUnsoldEq'] != null) {
|
|
761
|
-
queryParameters['isUnsold[eq]'] = requestParameters['isUnsoldEq'];
|
|
762
|
-
}
|
|
763
745
|
if (requestParameters['orderBy'] != null) {
|
|
764
746
|
queryParameters['orderBy'] = requestParameters['orderBy'];
|
|
765
747
|
}
|
|
@@ -790,7 +772,7 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
790
772
|
case 4:
|
|
791
773
|
_c.trys.push([4, 6, , 7]);
|
|
792
774
|
return [4 /*yield*/, this.request({
|
|
793
|
-
path: "/inventories/{inventoryId}/
|
|
775
|
+
path: "/inventories/{inventoryId}/misaligned-products".replace("{".concat("inventoryId", "}"), encodeURIComponent(String(requestParameters['inventoryId']))),
|
|
794
776
|
method: 'GET',
|
|
795
777
|
headers: headerParameters,
|
|
796
778
|
query: queryParameters,
|
|
@@ -799,7 +781,7 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
799
781
|
response = _c.sent();
|
|
800
782
|
contentType = response.headers.get("content-type");
|
|
801
783
|
if (contentType && contentType.indexOf("application/json") !== -1) {
|
|
802
|
-
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.
|
|
784
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.PaginatedMisalignedProductsFromJSON)(jsonValue); })];
|
|
803
785
|
}
|
|
804
786
|
else if (contentType && contentType.indexOf("text/plain") !== -1) {
|
|
805
787
|
return [2 /*return*/, new runtime.TextApiResponse(response)];
|
|
@@ -819,14 +801,14 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
819
801
|
});
|
|
820
802
|
};
|
|
821
803
|
/**
|
|
822
|
-
* Get
|
|
804
|
+
* Get product\'s where an action is required
|
|
823
805
|
*/
|
|
824
|
-
SearchInventoryApi.prototype.
|
|
806
|
+
SearchInventoryApi.prototype.getInventoryMisalignedProducts = function (requestParameters, initOverrides) {
|
|
825
807
|
return __awaiter(this, void 0, void 0, function () {
|
|
826
808
|
var response;
|
|
827
809
|
return __generator(this, function (_a) {
|
|
828
810
|
switch (_a.label) {
|
|
829
|
-
case 0: return [4 /*yield*/, this.
|
|
811
|
+
case 0: return [4 /*yield*/, this.getInventoryMisalignedProductsRaw(requestParameters, initOverrides)];
|
|
830
812
|
case 1:
|
|
831
813
|
response = _a.sent();
|
|
832
814
|
return [4 /*yield*/, response.value()];
|
|
@@ -836,18 +818,51 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
836
818
|
});
|
|
837
819
|
};
|
|
838
820
|
/**
|
|
839
|
-
* Get
|
|
821
|
+
* Get products that the pharmacian should destock
|
|
840
822
|
*/
|
|
841
|
-
SearchInventoryApi.prototype.
|
|
823
|
+
SearchInventoryApi.prototype.getInventoryOverstockProductsRaw = function (requestParameters, initOverrides) {
|
|
842
824
|
return __awaiter(this, void 0, void 0, function () {
|
|
843
825
|
var queryParameters, headerParameters, _a, _b, token, tokenString, response, contentType, response_9;
|
|
844
826
|
return __generator(this, function (_c) {
|
|
845
827
|
switch (_c.label) {
|
|
846
828
|
case 0:
|
|
847
829
|
if (requestParameters['inventoryId'] == null) {
|
|
848
|
-
throw new runtime.RequiredError('inventoryId', 'Required parameter "inventoryId" was null or undefined when calling
|
|
830
|
+
throw new runtime.RequiredError('inventoryId', 'Required parameter "inventoryId" was null or undefined when calling getInventoryOverstockProducts().');
|
|
849
831
|
}
|
|
850
832
|
queryParameters = {};
|
|
833
|
+
if (requestParameters['q'] != null) {
|
|
834
|
+
queryParameters['q'] = requestParameters['q'];
|
|
835
|
+
}
|
|
836
|
+
if (requestParameters['labEq'] != null) {
|
|
837
|
+
queryParameters['lab[eq]'] = requestParameters['labEq'];
|
|
838
|
+
}
|
|
839
|
+
if (requestParameters['ptEq'] != null) {
|
|
840
|
+
queryParameters['pt[eq]'] = requestParameters['ptEq'];
|
|
841
|
+
}
|
|
842
|
+
if (requestParameters['blEq'] != null) {
|
|
843
|
+
queryParameters['bl[eq]'] = requestParameters['blEq'];
|
|
844
|
+
}
|
|
845
|
+
if (requestParameters['forecastGte'] != null) {
|
|
846
|
+
queryParameters['forecast[gte]'] = requestParameters['forecastGte'];
|
|
847
|
+
}
|
|
848
|
+
if (requestParameters['forecastLte'] != null) {
|
|
849
|
+
queryParameters['forecast[lte]'] = requestParameters['forecastLte'];
|
|
850
|
+
}
|
|
851
|
+
if (requestParameters['forecastPr'] != null) {
|
|
852
|
+
queryParameters['forecast[pr]'] = requestParameters['forecastPr'];
|
|
853
|
+
}
|
|
854
|
+
if (requestParameters['isUnsoldEq'] != null) {
|
|
855
|
+
queryParameters['isUnsold[eq]'] = requestParameters['isUnsoldEq'];
|
|
856
|
+
}
|
|
857
|
+
if (requestParameters['orderBy'] != null) {
|
|
858
|
+
queryParameters['orderBy'] = requestParameters['orderBy'];
|
|
859
|
+
}
|
|
860
|
+
if (requestParameters['p'] != null) {
|
|
861
|
+
queryParameters['p'] = requestParameters['p'];
|
|
862
|
+
}
|
|
863
|
+
if (requestParameters['pp'] != null) {
|
|
864
|
+
queryParameters['pp'] = requestParameters['pp'];
|
|
865
|
+
}
|
|
851
866
|
headerParameters = {};
|
|
852
867
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 2];
|
|
853
868
|
_a = headerParameters;
|
|
@@ -869,7 +884,7 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
869
884
|
case 4:
|
|
870
885
|
_c.trys.push([4, 6, , 7]);
|
|
871
886
|
return [4 /*yield*/, this.request({
|
|
872
|
-
path: "/inventories/{inventoryId}/
|
|
887
|
+
path: "/inventories/{inventoryId}/overstock-products".replace("{".concat("inventoryId", "}"), encodeURIComponent(String(requestParameters['inventoryId']))),
|
|
873
888
|
method: 'GET',
|
|
874
889
|
headers: headerParameters,
|
|
875
890
|
query: queryParameters,
|
|
@@ -878,7 +893,7 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
878
893
|
response = _c.sent();
|
|
879
894
|
contentType = response.headers.get("content-type");
|
|
880
895
|
if (contentType && contentType.indexOf("application/json") !== -1) {
|
|
881
|
-
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.
|
|
896
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.PaginatedOverstockProductsFromJSON)(jsonValue); })];
|
|
882
897
|
}
|
|
883
898
|
else if (contentType && contentType.indexOf("text/plain") !== -1) {
|
|
884
899
|
return [2 /*return*/, new runtime.TextApiResponse(response)];
|
|
@@ -898,14 +913,14 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
898
913
|
});
|
|
899
914
|
};
|
|
900
915
|
/**
|
|
901
|
-
* Get
|
|
916
|
+
* Get products that the pharmacian should destock
|
|
902
917
|
*/
|
|
903
|
-
SearchInventoryApi.prototype.
|
|
918
|
+
SearchInventoryApi.prototype.getInventoryOverstockProducts = function (requestParameters, initOverrides) {
|
|
904
919
|
return __awaiter(this, void 0, void 0, function () {
|
|
905
920
|
var response;
|
|
906
921
|
return __generator(this, function (_a) {
|
|
907
922
|
switch (_a.label) {
|
|
908
|
-
case 0: return [4 /*yield*/, this.
|
|
923
|
+
case 0: return [4 /*yield*/, this.getInventoryOverstockProductsRaw(requestParameters, initOverrides)];
|
|
909
924
|
case 1:
|
|
910
925
|
response = _a.sent();
|
|
911
926
|
return [4 /*yield*/, response.value()];
|
|
@@ -915,19 +930,24 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
915
930
|
});
|
|
916
931
|
};
|
|
917
932
|
/**
|
|
918
|
-
*
|
|
919
|
-
* Get synchronization state of inventory
|
|
933
|
+
* Get advices statistics
|
|
920
934
|
*/
|
|
921
|
-
SearchInventoryApi.prototype.
|
|
935
|
+
SearchInventoryApi.prototype.getInventoryStatisticsRaw = function (requestParameters, initOverrides) {
|
|
922
936
|
return __awaiter(this, void 0, void 0, function () {
|
|
923
937
|
var queryParameters, headerParameters, _a, _b, token, tokenString, response, contentType, response_10;
|
|
924
938
|
return __generator(this, function (_c) {
|
|
925
939
|
switch (_c.label) {
|
|
926
940
|
case 0:
|
|
927
941
|
if (requestParameters['inventoryId'] == null) {
|
|
928
|
-
throw new runtime.RequiredError('inventoryId', 'Required parameter "inventoryId" was null or undefined when calling
|
|
942
|
+
throw new runtime.RequiredError('inventoryId', 'Required parameter "inventoryId" was null or undefined when calling getInventoryStatistics().');
|
|
929
943
|
}
|
|
930
944
|
queryParameters = {};
|
|
945
|
+
if (requestParameters['overstockBlEq'] != null) {
|
|
946
|
+
queryParameters['overstockBl[eq]'] = requestParameters['overstockBlEq'];
|
|
947
|
+
}
|
|
948
|
+
if (requestParameters['overstockForecastGte'] != null) {
|
|
949
|
+
queryParameters['overstockForecast[gte]'] = requestParameters['overstockForecastGte'];
|
|
950
|
+
}
|
|
931
951
|
headerParameters = {};
|
|
932
952
|
if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 2];
|
|
933
953
|
_a = headerParameters;
|
|
@@ -949,7 +969,7 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
949
969
|
case 4:
|
|
950
970
|
_c.trys.push([4, 6, , 7]);
|
|
951
971
|
return [4 /*yield*/, this.request({
|
|
952
|
-
path: "/inventories/{inventoryId}/
|
|
972
|
+
path: "/inventories/{inventoryId}/statistics".replace("{".concat("inventoryId", "}"), encodeURIComponent(String(requestParameters['inventoryId']))),
|
|
953
973
|
method: 'GET',
|
|
954
974
|
headers: headerParameters,
|
|
955
975
|
query: queryParameters,
|
|
@@ -958,7 +978,7 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
958
978
|
response = _c.sent();
|
|
959
979
|
contentType = response.headers.get("content-type");
|
|
960
980
|
if (contentType && contentType.indexOf("application/json") !== -1) {
|
|
961
|
-
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.
|
|
981
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.StatisticsFromJSON)(jsonValue); })];
|
|
962
982
|
}
|
|
963
983
|
else if (contentType && contentType.indexOf("text/plain") !== -1) {
|
|
964
984
|
return [2 /*return*/, new runtime.TextApiResponse(response)];
|
|
@@ -978,15 +998,14 @@ var SearchInventoryApi = /** @class */ (function (_super) {
|
|
|
978
998
|
});
|
|
979
999
|
};
|
|
980
1000
|
/**
|
|
981
|
-
*
|
|
982
|
-
* Get synchronization state of inventory
|
|
1001
|
+
* Get advices statistics
|
|
983
1002
|
*/
|
|
984
|
-
SearchInventoryApi.prototype.
|
|
1003
|
+
SearchInventoryApi.prototype.getInventoryStatistics = function (requestParameters, initOverrides) {
|
|
985
1004
|
return __awaiter(this, void 0, void 0, function () {
|
|
986
1005
|
var response;
|
|
987
1006
|
return __generator(this, function (_a) {
|
|
988
1007
|
switch (_a.label) {
|
|
989
|
-
case 0: return [4 /*yield*/, this.
|
|
1008
|
+
case 0: return [4 /*yield*/, this.getInventoryStatisticsRaw(requestParameters, initOverrides)];
|
|
990
1009
|
case 1:
|
|
991
1010
|
response = _a.sent();
|
|
992
1011
|
return [4 /*yield*/, response.value()];
|
|
@@ -9,6 +9,7 @@
|
|
|
9
9
|
* https://openapi-generator.tech
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
|
+
import type { SynchronizationMode } from './SynchronizationMode';
|
|
12
13
|
import type { ProductLink } from './ProductLink';
|
|
13
14
|
/**
|
|
14
15
|
*
|
|
@@ -35,11 +36,17 @@ export interface ActiveProduct {
|
|
|
35
36
|
*/
|
|
36
37
|
activeStock?: number;
|
|
37
38
|
/**
|
|
38
|
-
*
|
|
39
|
-
* @type {
|
|
39
|
+
*
|
|
40
|
+
* @type {SynchronizationMode}
|
|
41
|
+
* @memberof ActiveProduct
|
|
42
|
+
*/
|
|
43
|
+
synchronizationMode?: SynchronizationMode;
|
|
44
|
+
/**
|
|
45
|
+
* Date of last update of the product
|
|
46
|
+
* @type {Date}
|
|
40
47
|
* @memberof ActiveProduct
|
|
41
48
|
*/
|
|
42
|
-
|
|
49
|
+
updatedAt?: Date;
|
|
43
50
|
}
|
|
44
51
|
/**
|
|
45
52
|
* Check if a given object implements the ActiveProduct interface.
|
|
@@ -14,6 +14,7 @@
|
|
|
14
14
|
*/
|
|
15
15
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
16
|
exports.ActiveProductToJSON = exports.ActiveProductFromJSONTyped = exports.ActiveProductFromJSON = exports.instanceOfActiveProduct = void 0;
|
|
17
|
+
var SynchronizationMode_1 = require("./SynchronizationMode");
|
|
17
18
|
var ProductLink_1 = require("./ProductLink");
|
|
18
19
|
/**
|
|
19
20
|
* Check if a given object implements the ActiveProduct interface.
|
|
@@ -34,7 +35,8 @@ function ActiveProductFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
34
35
|
'product': (json['product'] === null || json['product'] === undefined) ? json['product'] : (0, ProductLink_1.ProductLinkFromJSON)(json['product']),
|
|
35
36
|
'totalActiveSaleOffers': json['totalActiveSaleOffers'],
|
|
36
37
|
'activeStock': json['activeStock'],
|
|
37
|
-
'
|
|
38
|
+
'synchronizationMode': (json['synchronizationMode'] === null || json['synchronizationMode'] === undefined) ? json['synchronizationMode'] : (0, SynchronizationMode_1.SynchronizationModeFromJSON)(json['synchronizationMode']),
|
|
39
|
+
'updatedAt': (json['updatedAt'] === null || json['updatedAt'] === undefined) ? json['updatedAt'] : new Date(json['updatedAt']),
|
|
38
40
|
};
|
|
39
41
|
}
|
|
40
42
|
exports.ActiveProductFromJSONTyped = ActiveProductFromJSONTyped;
|
|
@@ -46,7 +48,8 @@ function ActiveProductToJSON(value) {
|
|
|
46
48
|
'product': (0, ProductLink_1.ProductLinkToJSON)(value['product']),
|
|
47
49
|
'totalActiveSaleOffers': value['totalActiveSaleOffers'],
|
|
48
50
|
'activeStock': value['activeStock'],
|
|
49
|
-
'
|
|
51
|
+
'synchronizationMode': (0, SynchronizationMode_1.SynchronizationModeToJSON)(value['synchronizationMode']),
|
|
52
|
+
'updatedAt': (value['updatedAt'] === null || value['updatedAt'] === undefined) ? value['updatedAt'] : (value['updatedAt']).toISOString(),
|
|
50
53
|
};
|
|
51
54
|
}
|
|
52
55
|
exports.ActiveProductToJSON = ActiveProductToJSON;
|
|
@@ -9,6 +9,7 @@
|
|
|
9
9
|
* https://openapi-generator.tech
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
|
+
import type { SynchronizationMode } from './SynchronizationMode';
|
|
12
13
|
/**
|
|
13
14
|
*
|
|
14
15
|
* @export
|
|
@@ -16,11 +17,11 @@
|
|
|
16
17
|
*/
|
|
17
18
|
export interface ActiveProductUpdateParameters {
|
|
18
19
|
/**
|
|
19
|
-
*
|
|
20
|
-
* @type {
|
|
20
|
+
*
|
|
21
|
+
* @type {SynchronizationMode}
|
|
21
22
|
* @memberof ActiveProductUpdateParameters
|
|
22
23
|
*/
|
|
23
|
-
|
|
24
|
+
synchronizationMode?: SynchronizationMode;
|
|
24
25
|
}
|
|
25
26
|
/**
|
|
26
27
|
* Check if a given object implements the ActiveProductUpdateParameters interface.
|
|
@@ -14,6 +14,7 @@
|
|
|
14
14
|
*/
|
|
15
15
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
16
|
exports.ActiveProductUpdateParametersToJSON = exports.ActiveProductUpdateParametersFromJSONTyped = exports.ActiveProductUpdateParametersFromJSON = exports.instanceOfActiveProductUpdateParameters = void 0;
|
|
17
|
+
var SynchronizationMode_1 = require("./SynchronizationMode");
|
|
17
18
|
/**
|
|
18
19
|
* Check if a given object implements the ActiveProductUpdateParameters interface.
|
|
19
20
|
*/
|
|
@@ -30,7 +31,7 @@ function ActiveProductUpdateParametersFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
30
31
|
return json;
|
|
31
32
|
}
|
|
32
33
|
return {
|
|
33
|
-
'
|
|
34
|
+
'synchronizationMode': (json['synchronizationMode'] === null || json['synchronizationMode'] === undefined) ? json['synchronizationMode'] : (0, SynchronizationMode_1.SynchronizationModeFromJSON)(json['synchronizationMode']),
|
|
34
35
|
};
|
|
35
36
|
}
|
|
36
37
|
exports.ActiveProductUpdateParametersFromJSONTyped = ActiveProductUpdateParametersFromJSONTyped;
|
|
@@ -39,7 +40,7 @@ function ActiveProductUpdateParametersToJSON(value) {
|
|
|
39
40
|
return value;
|
|
40
41
|
}
|
|
41
42
|
return {
|
|
42
|
-
'
|
|
43
|
+
'synchronizationMode': (0, SynchronizationMode_1.SynchronizationModeToJSON)(value['synchronizationMode']),
|
|
43
44
|
};
|
|
44
45
|
}
|
|
45
46
|
exports.ActiveProductUpdateParametersToJSON = ActiveProductUpdateParametersToJSON;
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* lcdp-pharmaide-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 type { InventoryJournal } from './InventoryJournal';
|
|
13
|
+
import type { HttpLink } from './HttpLink';
|
|
14
|
+
/**
|
|
15
|
+
*
|
|
16
|
+
* @export
|
|
17
|
+
* @interface Inventory
|
|
18
|
+
*/
|
|
19
|
+
export interface Inventory {
|
|
20
|
+
/**
|
|
21
|
+
* Inventory id, match user id
|
|
22
|
+
* @type {number}
|
|
23
|
+
* @memberof Inventory
|
|
24
|
+
*/
|
|
25
|
+
id?: number;
|
|
26
|
+
/**
|
|
27
|
+
* Number of products with stock available in Offisante
|
|
28
|
+
* @type {number}
|
|
29
|
+
* @memberof Inventory
|
|
30
|
+
*/
|
|
31
|
+
availableStockProductCount?: number;
|
|
32
|
+
/**
|
|
33
|
+
*
|
|
34
|
+
* @type {HttpLink}
|
|
35
|
+
* @memberof Inventory
|
|
36
|
+
*/
|
|
37
|
+
activeProducts?: HttpLink;
|
|
38
|
+
/**
|
|
39
|
+
*
|
|
40
|
+
* @type {HttpLink}
|
|
41
|
+
* @memberof Inventory
|
|
42
|
+
*/
|
|
43
|
+
overstockProducts?: HttpLink;
|
|
44
|
+
/**
|
|
45
|
+
*
|
|
46
|
+
* @type {HttpLink}
|
|
47
|
+
* @memberof Inventory
|
|
48
|
+
*/
|
|
49
|
+
misalignedProducts?: HttpLink;
|
|
50
|
+
/**
|
|
51
|
+
*
|
|
52
|
+
* @type {InventoryJournal}
|
|
53
|
+
* @memberof Inventory
|
|
54
|
+
*/
|
|
55
|
+
journal?: InventoryJournal;
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* Check if a given object implements the Inventory interface.
|
|
59
|
+
*/
|
|
60
|
+
export declare function instanceOfInventory(value: object): value is Inventory;
|
|
61
|
+
export declare function InventoryFromJSON(json: any): Inventory;
|
|
62
|
+
export declare function InventoryFromJSONTyped(json: any, ignoreDiscriminator: boolean): Inventory;
|
|
63
|
+
export declare function InventoryToJSON(value?: Inventory | null): any;
|