@lcdp/api-react-rest-client 2.0.1 → 2.0.2-LDS-2812-contingenter-les-annonces.3987046606
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/magic-cart/src/models/Stock.d.ts +6 -0
- package/magic-cart/src/models/Stock.js +2 -0
- package/package.json +1 -1
- package/product/src/apis/SearchProductApi.d.ts +1 -0
- package/product/src/apis/SearchProductApi.js +3 -0
- package/sale-offer/src/apis/SearchSaleOfferApi.d.ts +2 -0
- package/sale-offer/src/apis/SearchSaleOfferApi.js +2 -0
- package/sale-offer/src/models/Stock.d.ts +6 -0
- package/sale-offer/src/models/Stock.js +2 -0
- package/shopping-cart/src/models/Stock.d.ts +6 -0
- package/shopping-cart/src/models/Stock.js +2 -0
- package/user/src/apis/SearchUserDocumentApi.d.ts +27 -1
- package/user/src/apis/SearchUserDocumentApi.js +96 -5
|
@@ -33,6 +33,12 @@ export interface Stock {
|
|
|
33
33
|
* @memberof Stock
|
|
34
34
|
*/
|
|
35
35
|
batch?: string | null;
|
|
36
|
+
/**
|
|
37
|
+
* Maximum buyable quantity for each order Null value signify there is no limit of buyable quantity (just limited by remainingQuantity)
|
|
38
|
+
* @type {number}
|
|
39
|
+
* @memberof Stock
|
|
40
|
+
*/
|
|
41
|
+
maxBuyableQuantity?: number | null;
|
|
36
42
|
}
|
|
37
43
|
export declare function StockFromJSON(json: any): Stock;
|
|
38
44
|
export declare function StockFromJSONTyped(json: any, ignoreDiscriminator: boolean): Stock;
|
|
@@ -27,6 +27,7 @@ function StockFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
27
27
|
'remainingQuantity': !(0, runtime_1.exists)(json, 'remainingQuantity') ? json['remainingQuantity'] : json['remainingQuantity'],
|
|
28
28
|
'lapsingDate': !(0, runtime_1.exists)(json, 'lapsingDate') ? json['lapsingDate'] : (new Date(json['lapsingDate'])),
|
|
29
29
|
'batch': !(0, runtime_1.exists)(json, 'batch') ? json['batch'] : json['batch'],
|
|
30
|
+
'maxBuyableQuantity': !(0, runtime_1.exists)(json, 'maxBuyableQuantity') ? json['maxBuyableQuantity'] : json['maxBuyableQuantity'],
|
|
30
31
|
};
|
|
31
32
|
}
|
|
32
33
|
exports.StockFromJSONTyped = StockFromJSONTyped;
|
|
@@ -41,6 +42,7 @@ function StockToJSON(value) {
|
|
|
41
42
|
'remainingQuantity': value.remainingQuantity,
|
|
42
43
|
'lapsingDate': value.lapsingDate === undefined ? undefined : (value.lapsingDate === null ? null : (0, runtime_1.toDateISOString)(value.lapsingDate)),
|
|
43
44
|
'batch': value.batch,
|
|
45
|
+
'maxBuyableQuantity': value.maxBuyableQuantity,
|
|
44
46
|
};
|
|
45
47
|
}
|
|
46
48
|
exports.StockToJSON = StockToJSON;
|
package/package.json
CHANGED
|
@@ -179,6 +179,9 @@ var SearchProductApi = /** @class */ (function (_super) {
|
|
|
179
179
|
if (requestParameters.labEq) {
|
|
180
180
|
queryParameters['lab[eq]'] = requestParameters.labEq;
|
|
181
181
|
}
|
|
182
|
+
if (requestParameters.nameIeq !== undefined) {
|
|
183
|
+
queryParameters['name[ieq]'] = requestParameters.nameIeq;
|
|
184
|
+
}
|
|
182
185
|
if (requestParameters.sWaitingSaleOfferCountGte !== undefined) {
|
|
183
186
|
queryParameters['sWaitingSaleOfferCount[gte]'] = requestParameters.sWaitingSaleOfferCountGte;
|
|
184
187
|
}
|
|
@@ -77,6 +77,8 @@ export declare enum GetSaleOffersOrderByEnum {
|
|
|
77
77
|
STOCKBATCHdesc = "STOCK_BATCH:desc",
|
|
78
78
|
STOCKREMAININGQUANTITYasc = "STOCK_REMAINING_QUANTITY:asc",
|
|
79
79
|
STOCKREMAININGQUANTITYdesc = "STOCK_REMAINING_QUANTITY:desc",
|
|
80
|
+
MAXBUYABLEQUANTITYasc = "MAX_BUYABLE_QUANTITY:asc",
|
|
81
|
+
MAXBUYABLEQUANTITYdesc = "MAX_BUYABLE_QUANTITY:desc",
|
|
80
82
|
MINIMALQUANTITYasc = "MINIMAL_QUANTITY:asc",
|
|
81
83
|
MINIMALQUANTITYdesc = "MINIMAL_QUANTITY:desc",
|
|
82
84
|
STATUSasc = "STATUS:asc",
|
|
@@ -304,6 +304,8 @@ var GetSaleOffersOrderByEnum;
|
|
|
304
304
|
GetSaleOffersOrderByEnum["STOCKBATCHdesc"] = "STOCK_BATCH:desc";
|
|
305
305
|
GetSaleOffersOrderByEnum["STOCKREMAININGQUANTITYasc"] = "STOCK_REMAINING_QUANTITY:asc";
|
|
306
306
|
GetSaleOffersOrderByEnum["STOCKREMAININGQUANTITYdesc"] = "STOCK_REMAINING_QUANTITY:desc";
|
|
307
|
+
GetSaleOffersOrderByEnum["MAXBUYABLEQUANTITYasc"] = "MAX_BUYABLE_QUANTITY:asc";
|
|
308
|
+
GetSaleOffersOrderByEnum["MAXBUYABLEQUANTITYdesc"] = "MAX_BUYABLE_QUANTITY:desc";
|
|
307
309
|
GetSaleOffersOrderByEnum["MINIMALQUANTITYasc"] = "MINIMAL_QUANTITY:asc";
|
|
308
310
|
GetSaleOffersOrderByEnum["MINIMALQUANTITYdesc"] = "MINIMAL_QUANTITY:desc";
|
|
309
311
|
GetSaleOffersOrderByEnum["STATUSasc"] = "STATUS:asc";
|
|
@@ -33,6 +33,12 @@ export interface Stock {
|
|
|
33
33
|
* @memberof Stock
|
|
34
34
|
*/
|
|
35
35
|
batch?: string | null;
|
|
36
|
+
/**
|
|
37
|
+
* Maximum buyable quantity for each order Null value signify there is no limit of buyable quantity (just limited by remainingQuantity)
|
|
38
|
+
* @type {number}
|
|
39
|
+
* @memberof Stock
|
|
40
|
+
*/
|
|
41
|
+
maxBuyableQuantity?: number | null;
|
|
36
42
|
}
|
|
37
43
|
export declare function StockFromJSON(json: any): Stock;
|
|
38
44
|
export declare function StockFromJSONTyped(json: any, ignoreDiscriminator: boolean): Stock;
|
|
@@ -27,6 +27,7 @@ function StockFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
27
27
|
'remainingQuantity': !(0, runtime_1.exists)(json, 'remainingQuantity') ? json['remainingQuantity'] : json['remainingQuantity'],
|
|
28
28
|
'lapsingDate': !(0, runtime_1.exists)(json, 'lapsingDate') ? json['lapsingDate'] : (new Date(json['lapsingDate'])),
|
|
29
29
|
'batch': !(0, runtime_1.exists)(json, 'batch') ? json['batch'] : json['batch'],
|
|
30
|
+
'maxBuyableQuantity': !(0, runtime_1.exists)(json, 'maxBuyableQuantity') ? json['maxBuyableQuantity'] : json['maxBuyableQuantity'],
|
|
30
31
|
};
|
|
31
32
|
}
|
|
32
33
|
exports.StockFromJSONTyped = StockFromJSONTyped;
|
|
@@ -41,6 +42,7 @@ function StockToJSON(value) {
|
|
|
41
42
|
'remainingQuantity': value.remainingQuantity,
|
|
42
43
|
'lapsingDate': value.lapsingDate === undefined ? undefined : (value.lapsingDate === null ? null : (0, runtime_1.toDateISOString)(value.lapsingDate)),
|
|
43
44
|
'batch': value.batch,
|
|
45
|
+
'maxBuyableQuantity': value.maxBuyableQuantity,
|
|
44
46
|
};
|
|
45
47
|
}
|
|
46
48
|
exports.StockToJSON = StockToJSON;
|
|
@@ -33,6 +33,12 @@ export interface Stock {
|
|
|
33
33
|
* @memberof Stock
|
|
34
34
|
*/
|
|
35
35
|
batch?: string | null;
|
|
36
|
+
/**
|
|
37
|
+
* Maximum buyable quantity for each order Null value signify there is no limit of buyable quantity (just limited by remainingQuantity)
|
|
38
|
+
* @type {number}
|
|
39
|
+
* @memberof Stock
|
|
40
|
+
*/
|
|
41
|
+
maxBuyableQuantity?: number | null;
|
|
36
42
|
}
|
|
37
43
|
export declare function StockFromJSON(json: any): Stock;
|
|
38
44
|
export declare function StockFromJSONTyped(json: any, ignoreDiscriminator: boolean): Stock;
|
|
@@ -27,6 +27,7 @@ function StockFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
27
27
|
'remainingQuantity': !(0, runtime_1.exists)(json, 'remainingQuantity') ? json['remainingQuantity'] : json['remainingQuantity'],
|
|
28
28
|
'lapsingDate': !(0, runtime_1.exists)(json, 'lapsingDate') ? json['lapsingDate'] : (new Date(json['lapsingDate'])),
|
|
29
29
|
'batch': !(0, runtime_1.exists)(json, 'batch') ? json['batch'] : json['batch'],
|
|
30
|
+
'maxBuyableQuantity': !(0, runtime_1.exists)(json, 'maxBuyableQuantity') ? json['maxBuyableQuantity'] : json['maxBuyableQuantity'],
|
|
30
31
|
};
|
|
31
32
|
}
|
|
32
33
|
exports.StockFromJSONTyped = StockFromJSONTyped;
|
|
@@ -41,6 +42,7 @@ function StockToJSON(value) {
|
|
|
41
42
|
'remainingQuantity': value.remainingQuantity,
|
|
42
43
|
'lapsingDate': value.lapsingDate === undefined ? undefined : (value.lapsingDate === null ? null : (0, runtime_1.toDateISOString)(value.lapsingDate)),
|
|
43
44
|
'batch': value.batch,
|
|
45
|
+
'maxBuyableQuantity': value.maxBuyableQuantity,
|
|
44
46
|
};
|
|
45
47
|
}
|
|
46
48
|
exports.StockToJSON = StockToJSON;
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import { BaseAPI, ApiResponse, BlobWithMeta } from '../runtime';
|
|
13
|
-
import { UserDocument } from '../models';
|
|
13
|
+
import { UserDocument, UserDocumentStatus } from '../models';
|
|
14
14
|
export interface GetCurrentUserDocumentRequest {
|
|
15
15
|
documentType: GetCurrentUserDocumentDocumentTypeEnum;
|
|
16
16
|
}
|
|
@@ -25,6 +25,10 @@ export interface GetUserDocumentMetadataRequest {
|
|
|
25
25
|
userId: number;
|
|
26
26
|
documentType: GetUserDocumentMetadataDocumentTypeEnum;
|
|
27
27
|
}
|
|
28
|
+
export interface GetUserDocumentStatusRequest {
|
|
29
|
+
userId: number;
|
|
30
|
+
documentType: GetUserDocumentStatusDocumentTypeEnum;
|
|
31
|
+
}
|
|
28
32
|
export interface GetUserDocumentsRequest {
|
|
29
33
|
userId: number;
|
|
30
34
|
}
|
|
@@ -72,6 +76,16 @@ export declare class SearchUserDocumentApi extends BaseAPI {
|
|
|
72
76
|
* Get metadata of document associated to given user
|
|
73
77
|
*/
|
|
74
78
|
getUserDocumentMetadata(requestParameters: GetUserDocumentMetadataRequest): Promise<void>;
|
|
79
|
+
/**
|
|
80
|
+
* Get document status
|
|
81
|
+
* Get document status
|
|
82
|
+
*/
|
|
83
|
+
getUserDocumentStatusRaw(requestParameters: GetUserDocumentStatusRequest): Promise<ApiResponse<UserDocumentStatus | BlobWithMeta>>;
|
|
84
|
+
/**
|
|
85
|
+
* Get document status
|
|
86
|
+
* Get document status
|
|
87
|
+
*/
|
|
88
|
+
getUserDocumentStatus(requestParameters: GetUserDocumentStatusRequest): Promise<UserDocumentStatus | BlobWithMeta>;
|
|
75
89
|
/**
|
|
76
90
|
* Get all user documents
|
|
77
91
|
*/
|
|
@@ -129,3 +143,15 @@ export declare enum GetUserDocumentMetadataDocumentTypeEnum {
|
|
|
129
143
|
CGV = "CGV",
|
|
130
144
|
GMP = "GMP"
|
|
131
145
|
}
|
|
146
|
+
/**
|
|
147
|
+
* @export
|
|
148
|
+
* @enum {string}
|
|
149
|
+
*/
|
|
150
|
+
export declare enum GetUserDocumentStatusDocumentTypeEnum {
|
|
151
|
+
KBIS = "KBIS",
|
|
152
|
+
ID = "ID",
|
|
153
|
+
SHAREHOLDER = "SHARE_HOLDER",
|
|
154
|
+
STATUS = "STATUS",
|
|
155
|
+
CGV = "CGV",
|
|
156
|
+
GMP = "GMP"
|
|
157
|
+
}
|
|
@@ -64,7 +64,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
|
64
64
|
}
|
|
65
65
|
};
|
|
66
66
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
67
|
-
exports.GetUserDocumentMetadataDocumentTypeEnum = exports.GetUserDocumentDocumentTypeEnum = exports.GetCurrentUserDocumentMetadataDocumentTypeEnum = exports.GetCurrentUserDocumentDocumentTypeEnum = exports.SearchUserDocumentApi = void 0;
|
|
67
|
+
exports.GetUserDocumentStatusDocumentTypeEnum = exports.GetUserDocumentMetadataDocumentTypeEnum = exports.GetUserDocumentDocumentTypeEnum = exports.GetCurrentUserDocumentMetadataDocumentTypeEnum = exports.GetCurrentUserDocumentDocumentTypeEnum = exports.SearchUserDocumentApi = void 0;
|
|
68
68
|
var runtime_1 = require("../runtime");
|
|
69
69
|
var models_1 = require("../models");
|
|
70
70
|
/**
|
|
@@ -417,12 +417,90 @@ var SearchUserDocumentApi = /** @class */ (function (_super) {
|
|
|
417
417
|
});
|
|
418
418
|
});
|
|
419
419
|
};
|
|
420
|
+
/**
|
|
421
|
+
* Get document status
|
|
422
|
+
* Get document status
|
|
423
|
+
*/
|
|
424
|
+
SearchUserDocumentApi.prototype.getUserDocumentStatusRaw = function (requestParameters) {
|
|
425
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
426
|
+
var queryParameters, headerParameters, token, tokenString, response, contentType, response_6;
|
|
427
|
+
return __generator(this, function (_a) {
|
|
428
|
+
switch (_a.label) {
|
|
429
|
+
case 0:
|
|
430
|
+
if (requestParameters.userId === null || requestParameters.userId === undefined) {
|
|
431
|
+
throw new runtime_1.RequiredError('userId', 'Required parameter requestParameters.userId was null or undefined when calling getUserDocumentStatus.');
|
|
432
|
+
}
|
|
433
|
+
if (requestParameters.documentType === null || requestParameters.documentType === undefined) {
|
|
434
|
+
throw new runtime_1.RequiredError('documentType', 'Required parameter requestParameters.documentType was null or undefined when calling getUserDocumentStatus.');
|
|
435
|
+
}
|
|
436
|
+
queryParameters = {};
|
|
437
|
+
headerParameters = {};
|
|
438
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
439
|
+
headerParameters["x-api-key"] = this.configuration.apiKey("x-api-key"); // apiKeyAuth authentication
|
|
440
|
+
}
|
|
441
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
442
|
+
token = this.configuration.accessToken;
|
|
443
|
+
tokenString = typeof token === 'function' ? token("bearerAuth", []) : token;
|
|
444
|
+
if (tokenString) {
|
|
445
|
+
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
446
|
+
}
|
|
447
|
+
}
|
|
448
|
+
_a.label = 1;
|
|
449
|
+
case 1:
|
|
450
|
+
_a.trys.push([1, 3, , 4]);
|
|
451
|
+
return [4 /*yield*/, this.request({
|
|
452
|
+
path: "/users/{userId}/documents/{documentType}/status".replace("{".concat("userId", "}"), encodeURIComponent(String(requestParameters.userId))).replace("{".concat("documentType", "}"), encodeURIComponent(String(requestParameters.documentType))),
|
|
453
|
+
method: 'GET',
|
|
454
|
+
headers: headerParameters,
|
|
455
|
+
query: queryParameters,
|
|
456
|
+
})];
|
|
457
|
+
case 2:
|
|
458
|
+
response = _a.sent();
|
|
459
|
+
contentType = response.headers.get("content-type");
|
|
460
|
+
if (contentType && contentType.indexOf("application/json") !== -1) {
|
|
461
|
+
return [2 /*return*/, new runtime_1.JSONApiResponse(response, function (jsonValue) { return (0, models_1.UserDocumentStatusFromJSON)(jsonValue); })];
|
|
462
|
+
}
|
|
463
|
+
else if (contentType && contentType.indexOf("text/plain") !== -1) {
|
|
464
|
+
return [2 /*return*/, new runtime_1.TextApiResponse(response)];
|
|
465
|
+
}
|
|
466
|
+
else {
|
|
467
|
+
// TODO : Better handling of others application types
|
|
468
|
+
return [2 /*return*/, new runtime_1.BlobWithMetaApiResponse(response)];
|
|
469
|
+
}
|
|
470
|
+
return [3 /*break*/, 4];
|
|
471
|
+
case 3:
|
|
472
|
+
response_6 = _a.sent();
|
|
473
|
+
console.debug(response_6);
|
|
474
|
+
throw response_6;
|
|
475
|
+
case 4: return [2 /*return*/];
|
|
476
|
+
}
|
|
477
|
+
});
|
|
478
|
+
});
|
|
479
|
+
};
|
|
480
|
+
/**
|
|
481
|
+
* Get document status
|
|
482
|
+
* Get document status
|
|
483
|
+
*/
|
|
484
|
+
SearchUserDocumentApi.prototype.getUserDocumentStatus = function (requestParameters) {
|
|
485
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
486
|
+
var response;
|
|
487
|
+
return __generator(this, function (_a) {
|
|
488
|
+
switch (_a.label) {
|
|
489
|
+
case 0: return [4 /*yield*/, this.getUserDocumentStatusRaw(requestParameters)];
|
|
490
|
+
case 1:
|
|
491
|
+
response = _a.sent();
|
|
492
|
+
return [4 /*yield*/, response.value()];
|
|
493
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
494
|
+
}
|
|
495
|
+
});
|
|
496
|
+
});
|
|
497
|
+
};
|
|
420
498
|
/**
|
|
421
499
|
* Get all user documents
|
|
422
500
|
*/
|
|
423
501
|
SearchUserDocumentApi.prototype.getUserDocumentsRaw = function (requestParameters) {
|
|
424
502
|
return __awaiter(this, void 0, void 0, function () {
|
|
425
|
-
var queryParameters, headerParameters, token, tokenString, response, contentType,
|
|
503
|
+
var queryParameters, headerParameters, token, tokenString, response, contentType, response_7;
|
|
426
504
|
return __generator(this, function (_a) {
|
|
427
505
|
switch (_a.label) {
|
|
428
506
|
case 0:
|
|
@@ -465,9 +543,9 @@ var SearchUserDocumentApi = /** @class */ (function (_super) {
|
|
|
465
543
|
}
|
|
466
544
|
return [3 /*break*/, 4];
|
|
467
545
|
case 3:
|
|
468
|
-
|
|
469
|
-
console.debug(
|
|
470
|
-
throw
|
|
546
|
+
response_7 = _a.sent();
|
|
547
|
+
console.debug(response_7);
|
|
548
|
+
throw response_7;
|
|
471
549
|
case 4: return [2 /*return*/];
|
|
472
550
|
}
|
|
473
551
|
});
|
|
@@ -545,3 +623,16 @@ var GetUserDocumentMetadataDocumentTypeEnum;
|
|
|
545
623
|
GetUserDocumentMetadataDocumentTypeEnum["CGV"] = "CGV";
|
|
546
624
|
GetUserDocumentMetadataDocumentTypeEnum["GMP"] = "GMP";
|
|
547
625
|
})(GetUserDocumentMetadataDocumentTypeEnum = exports.GetUserDocumentMetadataDocumentTypeEnum || (exports.GetUserDocumentMetadataDocumentTypeEnum = {}));
|
|
626
|
+
/**
|
|
627
|
+
* @export
|
|
628
|
+
* @enum {string}
|
|
629
|
+
*/
|
|
630
|
+
var GetUserDocumentStatusDocumentTypeEnum;
|
|
631
|
+
(function (GetUserDocumentStatusDocumentTypeEnum) {
|
|
632
|
+
GetUserDocumentStatusDocumentTypeEnum["KBIS"] = "KBIS";
|
|
633
|
+
GetUserDocumentStatusDocumentTypeEnum["ID"] = "ID";
|
|
634
|
+
GetUserDocumentStatusDocumentTypeEnum["SHAREHOLDER"] = "SHARE_HOLDER";
|
|
635
|
+
GetUserDocumentStatusDocumentTypeEnum["STATUS"] = "STATUS";
|
|
636
|
+
GetUserDocumentStatusDocumentTypeEnum["CGV"] = "CGV";
|
|
637
|
+
GetUserDocumentStatusDocumentTypeEnum["GMP"] = "GMP";
|
|
638
|
+
})(GetUserDocumentStatusDocumentTypeEnum = exports.GetUserDocumentStatusDocumentTypeEnum || (exports.GetUserDocumentStatusDocumentTypeEnum = {}));
|