@lcdp/api-react-rest-client 2.1.2-develop.4364529993 → 2.1.2-develop.4425705383

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lcdp/api-react-rest-client",
3
- "version": "2.1.2-develop.4364529993",
3
+ "version": "2.1.2-develop.4425705383",
4
4
  "scripts": {
5
5
  "build": "tsc"
6
6
  },
@@ -17,6 +17,9 @@ export interface DeleteCurrentCartSubCartRequest {
17
17
  export interface GetCurrentCartSubCartRequest {
18
18
  subCartId: number;
19
19
  }
20
+ export interface GetCurrentCartSubCartsRequest {
21
+ orderBy?: GetCurrentCartSubCartsOrderByEnum;
22
+ }
20
23
  /**
21
24
  * no description
22
25
  */
@@ -40,9 +43,19 @@ export declare class ManageCartSubCartApi extends BaseAPI {
40
43
  /**
41
44
  * Get user cart split by SubCart
42
45
  */
43
- getCurrentCartSubCartsRaw(): Promise<ApiResponse<Array<CartSubCart> | BlobWithMeta>>;
46
+ getCurrentCartSubCartsRaw(requestParameters: GetCurrentCartSubCartsRequest): Promise<ApiResponse<Array<CartSubCart> | BlobWithMeta>>;
44
47
  /**
45
48
  * Get user cart split by SubCart
46
49
  */
47
- getCurrentCartSubCarts(): Promise<Array<CartSubCart> | BlobWithMeta>;
50
+ getCurrentCartSubCarts(requestParameters: GetCurrentCartSubCartsRequest): Promise<Array<CartSubCart> | BlobWithMeta>;
51
+ }
52
+ /**
53
+ * @export
54
+ * @enum {string}
55
+ */
56
+ export declare enum GetCurrentCartSubCartsOrderByEnum {
57
+ UPDATEDATasc = "UPDATED_AT:asc",
58
+ UPDATEDATdesc = "UPDATED_AT:desc",
59
+ TOTALEXCLUDINGTAXESasc = "TOTAL_EXCLUDING_TAXES:asc",
60
+ TOTALEXCLUDINGTAXESdesc = "TOTAL_EXCLUDING_TAXES:desc"
48
61
  }
@@ -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.ManageCartSubCartApi = void 0;
67
+ exports.GetCurrentCartSubCartsOrderByEnum = exports.ManageCartSubCartApi = void 0;
68
68
  var runtime_1 = require("../runtime");
69
69
  var models_1 = require("../models");
70
70
  /**
@@ -211,13 +211,16 @@ var ManageCartSubCartApi = /** @class */ (function (_super) {
211
211
  /**
212
212
  * Get user cart split by SubCart
213
213
  */
214
- ManageCartSubCartApi.prototype.getCurrentCartSubCartsRaw = function () {
214
+ ManageCartSubCartApi.prototype.getCurrentCartSubCartsRaw = function (requestParameters) {
215
215
  return __awaiter(this, void 0, void 0, function () {
216
216
  var queryParameters, headerParameters, token, tokenString, response, contentType, response_3;
217
217
  return __generator(this, function (_a) {
218
218
  switch (_a.label) {
219
219
  case 0:
220
220
  queryParameters = {};
221
+ if (requestParameters.orderBy !== undefined) {
222
+ queryParameters['orderBy'] = requestParameters.orderBy;
223
+ }
221
224
  headerParameters = {};
222
225
  if (this.configuration && this.configuration.apiKey) {
223
226
  headerParameters["x-api-key"] = this.configuration.apiKey("x-api-key"); // apiKeyAuth authentication
@@ -264,12 +267,12 @@ var ManageCartSubCartApi = /** @class */ (function (_super) {
264
267
  /**
265
268
  * Get user cart split by SubCart
266
269
  */
267
- ManageCartSubCartApi.prototype.getCurrentCartSubCarts = function () {
270
+ ManageCartSubCartApi.prototype.getCurrentCartSubCarts = function (requestParameters) {
268
271
  return __awaiter(this, void 0, void 0, function () {
269
272
  var response;
270
273
  return __generator(this, function (_a) {
271
274
  switch (_a.label) {
272
- case 0: return [4 /*yield*/, this.getCurrentCartSubCartsRaw()];
275
+ case 0: return [4 /*yield*/, this.getCurrentCartSubCartsRaw(requestParameters)];
273
276
  case 1:
274
277
  response = _a.sent();
275
278
  return [4 /*yield*/, response.value()];
@@ -281,3 +284,14 @@ var ManageCartSubCartApi = /** @class */ (function (_super) {
281
284
  return ManageCartSubCartApi;
282
285
  }(runtime_1.BaseAPI));
283
286
  exports.ManageCartSubCartApi = ManageCartSubCartApi;
287
+ /**
288
+ * @export
289
+ * @enum {string}
290
+ */
291
+ var GetCurrentCartSubCartsOrderByEnum;
292
+ (function (GetCurrentCartSubCartsOrderByEnum) {
293
+ GetCurrentCartSubCartsOrderByEnum["UPDATEDATasc"] = "UPDATED_AT:asc";
294
+ GetCurrentCartSubCartsOrderByEnum["UPDATEDATdesc"] = "UPDATED_AT:desc";
295
+ GetCurrentCartSubCartsOrderByEnum["TOTALEXCLUDINGTAXESasc"] = "TOTAL_EXCLUDING_TAXES:asc";
296
+ GetCurrentCartSubCartsOrderByEnum["TOTALEXCLUDINGTAXESdesc"] = "TOTAL_EXCLUDING_TAXES:desc";
297
+ })(GetCurrentCartSubCartsOrderByEnum = exports.GetCurrentCartSubCartsOrderByEnum || (exports.GetCurrentCartSubCartsOrderByEnum = {}));
@@ -23,43 +23,49 @@ export interface CartSubCart {
23
23
  * @type {number}
24
24
  * @memberof CartSubCart
25
25
  */
26
- id?: number;
26
+ id: number;
27
+ /**
28
+ * Last update date of this sub cart
29
+ * @type {Date}
30
+ * @memberof CartSubCart
31
+ */
32
+ updatedAt: Date;
27
33
  /**
28
34
  *
29
35
  * @type {CartSubCartTransport}
30
36
  * @memberof CartSubCart
31
37
  */
32
- transport?: CartSubCartTransport;
38
+ transport: CartSubCartTransport;
33
39
  /**
34
40
  *
35
41
  * @type {SellerLink}
36
42
  * @memberof CartSubCart
37
43
  */
38
- seller?: SellerLink;
44
+ seller: SellerLink;
39
45
  /**
40
46
  *
41
47
  * @type {number}
42
48
  * @memberof CartSubCart
43
49
  */
44
- lineCount?: number;
50
+ lineCount: number;
45
51
  /**
46
52
  *
47
53
  * @type {HttpLink}
48
54
  * @memberof CartSubCart
49
55
  */
50
- lines?: HttpLink;
56
+ lines: HttpLink;
51
57
  /**
52
58
  * Total buyer commission for this sub cart
53
59
  * @type {number}
54
60
  * @memberof CartSubCart
55
61
  */
56
- totalBuyerCommissionExcludingTaxes?: number;
62
+ totalBuyerCommissionExcludingTaxes: number;
57
63
  /**
58
64
  * Total price of the cart excluding taxes
59
65
  * @type {number}
60
66
  * @memberof CartSubCart
61
67
  */
62
- totalExcludingTaxes?: number;
68
+ totalExcludingTaxes: number;
63
69
  }
64
70
  export declare function CartSubCartFromJSON(json: any): CartSubCart;
65
71
  export declare function CartSubCartFromJSONTyped(json: any, ignoreDiscriminator: boolean): CartSubCart;
@@ -14,7 +14,6 @@
14
14
  */
15
15
  Object.defineProperty(exports, "__esModule", { value: true });
16
16
  exports.CartSubCartToJSON = exports.CartSubCartFromJSONTyped = exports.CartSubCartFromJSON = void 0;
17
- var runtime_1 = require("../runtime");
18
17
  var CartSubCartTransport_1 = require("./CartSubCartTransport");
19
18
  var HttpLink_1 = require("./HttpLink");
20
19
  var SellerLink_1 = require("./SellerLink");
@@ -27,13 +26,14 @@ function CartSubCartFromJSONTyped(json, ignoreDiscriminator) {
27
26
  return json;
28
27
  }
29
28
  return {
30
- 'id': !(0, runtime_1.exists)(json, 'id') ? undefined : json['id'],
31
- 'transport': !(0, runtime_1.exists)(json, 'transport') ? undefined : (0, CartSubCartTransport_1.CartSubCartTransportFromJSON)(json['transport']),
32
- 'seller': !(0, runtime_1.exists)(json, 'seller') ? undefined : (0, SellerLink_1.SellerLinkFromJSON)(json['seller']),
33
- 'lineCount': !(0, runtime_1.exists)(json, 'lineCount') ? undefined : json['lineCount'],
34
- 'lines': !(0, runtime_1.exists)(json, 'lines') ? undefined : (0, HttpLink_1.HttpLinkFromJSON)(json['lines']),
35
- 'totalBuyerCommissionExcludingTaxes': !(0, runtime_1.exists)(json, 'totalBuyerCommissionExcludingTaxes') ? undefined : json['totalBuyerCommissionExcludingTaxes'],
36
- 'totalExcludingTaxes': !(0, runtime_1.exists)(json, 'totalExcludingTaxes') ? undefined : json['totalExcludingTaxes'],
29
+ 'id': json['id'],
30
+ 'updatedAt': (new Date(json['updatedAt'])),
31
+ 'transport': (0, CartSubCartTransport_1.CartSubCartTransportFromJSON)(json['transport']),
32
+ 'seller': (0, SellerLink_1.SellerLinkFromJSON)(json['seller']),
33
+ 'lineCount': json['lineCount'],
34
+ 'lines': (0, HttpLink_1.HttpLinkFromJSON)(json['lines']),
35
+ 'totalBuyerCommissionExcludingTaxes': json['totalBuyerCommissionExcludingTaxes'],
36
+ 'totalExcludingTaxes': json['totalExcludingTaxes'],
37
37
  };
38
38
  }
39
39
  exports.CartSubCartFromJSONTyped = CartSubCartFromJSONTyped;
@@ -46,6 +46,7 @@ function CartSubCartToJSON(value) {
46
46
  }
47
47
  return {
48
48
  'id': value.id,
49
+ 'updatedAt': (value.updatedAt.toISOString()),
49
50
  'transport': (0, CartSubCartTransport_1.CartSubCartTransportToJSON)(value.transport),
50
51
  'seller': (0, SellerLink_1.SellerLinkToJSON)(value.seller),
51
52
  'lineCount': value.lineCount,
@@ -22,25 +22,25 @@ export interface CartSubCartLine {
22
22
  * @type {number}
23
23
  * @memberof CartSubCartLine
24
24
  */
25
- id?: number;
25
+ id: number;
26
26
  /**
27
27
  * Quantity desired by the buyer
28
28
  * @type {number}
29
29
  * @memberof CartSubCartLine
30
30
  */
31
- quantity?: number;
31
+ quantity: number;
32
32
  /**
33
33
  *
34
34
  * @type {ProductLink}
35
35
  * @memberof CartSubCartLine
36
36
  */
37
- product?: ProductLink;
37
+ product: ProductLink;
38
38
  /**
39
39
  *
40
40
  * @type {SaleOfferLink}
41
41
  * @memberof CartSubCartLine
42
42
  */
43
- saleOffer?: SaleOfferLink;
43
+ saleOffer: SaleOfferLink;
44
44
  /**
45
45
  *
46
46
  * @type {number}
@@ -52,7 +52,7 @@ export interface CartSubCartLine {
52
52
  * @type {number}
53
53
  * @memberof CartSubCartLine
54
54
  */
55
- totalExcludingTaxes?: number;
55
+ totalExcludingTaxes: number;
56
56
  }
57
57
  export declare function CartSubCartLineFromJSON(json: any): CartSubCartLine;
58
58
  export declare function CartSubCartLineFromJSONTyped(json: any, ignoreDiscriminator: boolean): CartSubCartLine;
@@ -26,12 +26,12 @@ function CartSubCartLineFromJSONTyped(json, ignoreDiscriminator) {
26
26
  return json;
27
27
  }
28
28
  return {
29
- 'id': !(0, runtime_1.exists)(json, 'id') ? undefined : json['id'],
30
- 'quantity': !(0, runtime_1.exists)(json, 'quantity') ? undefined : json['quantity'],
31
- 'product': !(0, runtime_1.exists)(json, 'product') ? undefined : (0, ProductLink_1.ProductLinkFromJSON)(json['product']),
32
- 'saleOffer': !(0, runtime_1.exists)(json, 'saleOffer') ? undefined : (0, SaleOfferLink_1.SaleOfferLinkFromJSON)(json['saleOffer']),
29
+ 'id': json['id'],
30
+ 'quantity': json['quantity'],
31
+ 'product': (0, ProductLink_1.ProductLinkFromJSON)(json['product']),
32
+ 'saleOffer': (0, SaleOfferLink_1.SaleOfferLinkFromJSON)(json['saleOffer']),
33
33
  'distributionRangeId': !(0, runtime_1.exists)(json, 'distributionRangeId') ? undefined : json['distributionRangeId'],
34
- 'totalExcludingTaxes': !(0, runtime_1.exists)(json, 'totalExcludingTaxes') ? undefined : json['totalExcludingTaxes'],
34
+ 'totalExcludingTaxes': json['totalExcludingTaxes'],
35
35
  };
36
36
  }
37
37
  exports.CartSubCartLineFromJSONTyped = CartSubCartLineFromJSONTyped;
@@ -20,19 +20,25 @@ export interface CartSubCartTransport {
20
20
  * @type {number}
21
21
  * @memberof CartSubCartTransport
22
22
  */
23
- minimumPrice?: number | null;
23
+ minimumPrice: number | null;
24
24
  /**
25
25
  * Total shipping fees price of the sub cart excluding taxes
26
26
  * @type {number}
27
27
  * @memberof CartSubCartTransport
28
28
  */
29
- totalShippingFeesExcludingTaxes?: number;
29
+ totalShippingFeesExcludingTaxes: number;
30
30
  /**
31
- * Limit in euro (totalExcludingTaxes) to achieve to have free sheeping fees. If no fee carriage threshold, value is null.
31
+ * Limit in euro (totalExcludingTaxes) to achieve to have free shipping fees. If no free carriage threshold reachable, value is null.
32
32
  * @type {number}
33
33
  * @memberof CartSubCartTransport
34
34
  */
35
- freeCarriageThreshold?: number | null;
35
+ freeCarriageThreshold: number | null;
36
+ /**
37
+ * Delivery delay in days
38
+ * @type {number}
39
+ * @memberof CartSubCartTransport
40
+ */
41
+ deliveryDelay: number;
36
42
  }
37
43
  export declare function CartSubCartTransportFromJSON(json: any): CartSubCartTransport;
38
44
  export declare function CartSubCartTransportFromJSONTyped(json: any, ignoreDiscriminator: boolean): CartSubCartTransport;
@@ -14,7 +14,6 @@
14
14
  */
15
15
  Object.defineProperty(exports, "__esModule", { value: true });
16
16
  exports.CartSubCartTransportToJSON = exports.CartSubCartTransportFromJSONTyped = exports.CartSubCartTransportFromJSON = void 0;
17
- var runtime_1 = require("../runtime");
18
17
  function CartSubCartTransportFromJSON(json) {
19
18
  return CartSubCartTransportFromJSONTyped(json, false);
20
19
  }
@@ -24,9 +23,10 @@ function CartSubCartTransportFromJSONTyped(json, ignoreDiscriminator) {
24
23
  return json;
25
24
  }
26
25
  return {
27
- 'minimumPrice': !(0, runtime_1.exists)(json, 'minimumPrice') ? json['minimumPrice'] : json['minimumPrice'],
28
- 'totalShippingFeesExcludingTaxes': !(0, runtime_1.exists)(json, 'totalShippingFeesExcludingTaxes') ? undefined : json['totalShippingFeesExcludingTaxes'],
29
- 'freeCarriageThreshold': !(0, runtime_1.exists)(json, 'freeCarriageThreshold') ? json['freeCarriageThreshold'] : json['freeCarriageThreshold'],
26
+ 'minimumPrice': json['minimumPrice'],
27
+ 'totalShippingFeesExcludingTaxes': json['totalShippingFeesExcludingTaxes'],
28
+ 'freeCarriageThreshold': json['freeCarriageThreshold'],
29
+ 'deliveryDelay': json['deliveryDelay'],
30
30
  };
31
31
  }
32
32
  exports.CartSubCartTransportFromJSONTyped = CartSubCartTransportFromJSONTyped;
@@ -41,6 +41,7 @@ function CartSubCartTransportToJSON(value) {
41
41
  'minimumPrice': value.minimumPrice,
42
42
  'totalShippingFeesExcludingTaxes': value.totalShippingFeesExcludingTaxes,
43
43
  'freeCarriageThreshold': value.freeCarriageThreshold,
44
+ 'deliveryDelay': value.deliveryDelay,
44
45
  };
45
46
  }
46
47
  exports.CartSubCartTransportToJSON = CartSubCartTransportToJSON;