@lcdp/api-react-rest-client 2.5.6-develop.6928204926 → 2.5.6

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.
@@ -22,12 +22,12 @@ export interface DeleteTagRequest {
22
22
  */
23
23
  export declare class ManageLexiconApi extends BaseAPI {
24
24
  /**
25
- * Tag should be register in this API to be reuse more easely Preconditions : - Tag should not be null or an empty string - Tag should be less than 25 characters
25
+ * Tag should be register in this API to be reuse more easely Precondition : - Tag should not be null or an empty string - Tag should be less than 25 characters
26
26
  * Create a new tag
27
27
  */
28
28
  createTagRaw(requestParameters: CreateTagRequest): Promise<ApiResponse<Tag | BlobWithMeta>>;
29
29
  /**
30
- * Tag should be register in this API to be reuse more easely Preconditions : - Tag should not be null or an empty string - Tag should be less than 25 characters
30
+ * Tag should be register in this API to be reuse more easely Precondition : - Tag should not be null or an empty string - Tag should be less than 25 characters
31
31
  * Create a new tag
32
32
  */
33
33
  createTag(requestParameters: CreateTagRequest): Promise<Tag | BlobWithMeta>;
@@ -76,7 +76,7 @@ var ManageLexiconApi = /** @class */ (function (_super) {
76
76
  return _super !== null && _super.apply(this, arguments) || this;
77
77
  }
78
78
  /**
79
- * Tag should be register in this API to be reuse more easely Preconditions : - Tag should not be null or an empty string - Tag should be less than 25 characters
79
+ * Tag should be register in this API to be reuse more easely Precondition : - Tag should not be null or an empty string - Tag should be less than 25 characters
80
80
  * Create a new tag
81
81
  */
82
82
  ManageLexiconApi.prototype.createTagRaw = function (requestParameters) {
@@ -143,7 +143,7 @@ var ManageLexiconApi = /** @class */ (function (_super) {
143
143
  });
144
144
  };
145
145
  /**
146
- * Tag should be register in this API to be reuse more easely Preconditions : - Tag should not be null or an empty string - Tag should be less than 25 characters
146
+ * Tag should be register in this API to be reuse more easely Precondition : - Tag should not be null or an empty string - Tag should be less than 25 characters
147
147
  * Create a new tag
148
148
  */
149
149
  ManageLexiconApi.prototype.createTag = function (requestParameters) {
@@ -118,12 +118,12 @@ export declare class ManageOrderApi extends BaseAPI {
118
118
  */
119
119
  updateOrderAnomalies(requestParameters: UpdateOrderAnomaliesRequest): Promise<void>;
120
120
  /**
121
- * # Preconditions : - \'released\' can not be greater than \'claimed\' - \'released\' can be modified only if \'limitedStock\' is true
121
+ * # Preconditions : - \'released\' can not be greater than \'claimed\'
122
122
  * Update order reservations
123
123
  */
124
124
  updateOrderReservationRaw(requestParameters: UpdateOrderReservationRequest): Promise<ApiResponse<Reservation | BlobWithMeta>>;
125
125
  /**
126
- * # Preconditions : - \'released\' can not be greater than \'claimed\' - \'released\' can be modified only if \'limitedStock\' is true
126
+ * # Preconditions : - \'released\' can not be greater than \'claimed\'
127
127
  * Update order reservations
128
128
  */
129
129
  updateOrderReservation(requestParameters: UpdateOrderReservationRequest): Promise<Reservation | BlobWithMeta>;
@@ -618,7 +618,7 @@ var ManageOrderApi = /** @class */ (function (_super) {
618
618
  });
619
619
  };
620
620
  /**
621
- * # Preconditions : - \'released\' can not be greater than \'claimed\' - \'released\' can be modified only if \'limitedStock\' is true
621
+ * # Preconditions : - \'released\' can not be greater than \'claimed\'
622
622
  * Update order reservations
623
623
  */
624
624
  ManageOrderApi.prototype.updateOrderReservationRaw = function (requestParameters) {
@@ -691,7 +691,7 @@ var ManageOrderApi = /** @class */ (function (_super) {
691
691
  });
692
692
  };
693
693
  /**
694
- * # Preconditions : - \'released\' can not be greater than \'claimed\' - \'released\' can be modified only if \'limitedStock\' is true
694
+ * # Preconditions : - \'released\' can not be greater than \'claimed\'
695
695
  * Update order reservations
696
696
  */
697
697
  ManageOrderApi.prototype.updateOrderReservation = function (requestParameters) {
@@ -65,12 +65,10 @@ export declare class SearchOrderApi extends BaseAPI {
65
65
  */
66
66
  getOrderDeliveryVoucher(requestParameters: GetOrderDeliveryVoucherRequest): Promise<BlobWithMeta>;
67
67
  /**
68
- * Preconditions : - You are administrator, BUYER or SELLER
69
68
  * Get reservations for an order
70
69
  */
71
70
  getOrderReservationsRaw(requestParameters: GetOrderReservationsRequest): Promise<ApiResponse<Array<Reservation> | BlobWithMeta>>;
72
71
  /**
73
- * Preconditions : - You are administrator, BUYER or SELLER
74
72
  * Get reservations for an order
75
73
  */
76
74
  getOrderReservations(requestParameters: GetOrderReservationsRequest): Promise<Array<Reservation> | BlobWithMeta>;
@@ -240,7 +240,6 @@ var SearchOrderApi = /** @class */ (function (_super) {
240
240
  });
241
241
  };
242
242
  /**
243
- * Preconditions : - You are administrator, BUYER or SELLER
244
243
  * Get reservations for an order
245
244
  */
246
245
  SearchOrderApi.prototype.getOrderReservationsRaw = function (requestParameters) {
@@ -305,7 +304,6 @@ var SearchOrderApi = /** @class */ (function (_super) {
305
304
  });
306
305
  };
307
306
  /**
308
- * Preconditions : - You are administrator, BUYER or SELLER
309
307
  * Get reservations for an order
310
308
  */
311
309
  SearchOrderApi.prototype.getOrderReservations = function (requestParameters) {
@@ -35,12 +35,6 @@ export interface Reservation {
35
35
  * @memberof Reservation
36
36
  */
37
37
  saleOffer?: SaleOfferLink;
38
- /**
39
- * True if the associated sale offer have a limited stock. False if not. Important note : You can not release claimed items for a non limited-stock sale offer.
40
- * @type {boolean}
41
- * @memberof Reservation
42
- */
43
- limitedStock?: boolean;
44
38
  /**
45
39
  * Total number of item linked to this order (claimed + released)
46
40
  * @type {number}
@@ -29,7 +29,6 @@ function ReservationFromJSONTyped(json, ignoreDiscriminator) {
29
29
  'id': !(0, runtime_1.exists)(json, 'id') ? undefined : json['id'],
30
30
  'product': !(0, runtime_1.exists)(json, 'product') ? undefined : (0, ProductLink_1.ProductLinkFromJSON)(json['product']),
31
31
  'saleOffer': !(0, runtime_1.exists)(json, 'saleOffer') ? undefined : (0, SaleOfferLink_1.SaleOfferLinkFromJSON)(json['saleOffer']),
32
- 'limitedStock': !(0, runtime_1.exists)(json, 'limitedStock') ? undefined : json['limitedStock'],
33
32
  'total': !(0, runtime_1.exists)(json, 'total') ? undefined : json['total'],
34
33
  'claimed': !(0, runtime_1.exists)(json, 'claimed') ? undefined : json['claimed'],
35
34
  'released': !(0, runtime_1.exists)(json, 'released') ? undefined : json['released'],
@@ -47,7 +46,6 @@ function ReservationToJSON(value) {
47
46
  'id': value.id,
48
47
  'product': (0, ProductLink_1.ProductLinkToJSON)(value.product),
49
48
  'saleOffer': (0, SaleOfferLink_1.SaleOfferLinkToJSON)(value.saleOffer),
50
- 'limitedStock': value.limitedStock,
51
49
  'total': value.total,
52
50
  'claimed': value.claimed,
53
51
  'released': value.released,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lcdp/api-react-rest-client",
3
- "version": "2.5.6-develop.6928204926",
3
+ "version": "2.5.6",
4
4
  "scripts": {
5
5
  "build": "tsc"
6
6
  },
@@ -43,12 +43,12 @@ export interface UpdateSaleOffersRequest {
43
43
  */
44
44
  export declare class ManageSaleOfferApi extends BaseAPI {
45
45
  /**
46
- * Create a new sale offer. WARNING : There is some special restrictions according the user that create sale offer # All : - Owner should have a valid mangopay mandate - Unit price should be lower than product unitPrice - For unitary sale offer, minimalQuantity should be lower than stock remainingQuantity # Pharmacy : - Can only create UNITARY sale offer - Sale offer should have at least one item in quantity - Can not set images on sale offers - Can not create sale offers without stock - Can create sale offer only for legal allowed products - Batch should be auhtorized by ANSM/DGCCRF - Lapsing date of stock must be after REQUIRED_LAPSING_MONTHS months # Laboratory : - Can not create a sale offer on a product that already have an existing non-disabled sale offer - Can create sale offer without lapsing - Can create sale offer without remaining quantity
46
+ * Create a new sale offer. WARNING : There is some special restrictions according the user that create sale offer # All : - Owner should have a valid mangopay mandate - Unit price should be lower than product unitPrice # Pharmacy : - Can only create UNITARY sale offer - Sale offer should have at least one item in quantity - Can not set images on sale offers - Can not create sale offers without stock - Can create sale offer only for legal allowed products - Batch should be auhtorized by ANSM/DGCCRF - Lapsing date of stock must be after REQUIRED_LAPSING_MONTHS months # Laboratory : - Can not create a sale offer on a product that already have an existing non-disabled sale offer - Can create sale offer without lapsing - Can create sale offer without remaining quantity
47
47
  * Create a new sale offer
48
48
  */
49
49
  createSaleOfferRaw(requestParameters: CreateSaleOfferRequest): Promise<ApiResponse<SaleOffer | BlobWithMeta>>;
50
50
  /**
51
- * Create a new sale offer. WARNING : There is some special restrictions according the user that create sale offer # All : - Owner should have a valid mangopay mandate - Unit price should be lower than product unitPrice - For unitary sale offer, minimalQuantity should be lower than stock remainingQuantity # Pharmacy : - Can only create UNITARY sale offer - Sale offer should have at least one item in quantity - Can not set images on sale offers - Can not create sale offers without stock - Can create sale offer only for legal allowed products - Batch should be auhtorized by ANSM/DGCCRF - Lapsing date of stock must be after REQUIRED_LAPSING_MONTHS months # Laboratory : - Can not create a sale offer on a product that already have an existing non-disabled sale offer - Can create sale offer without lapsing - Can create sale offer without remaining quantity
51
+ * Create a new sale offer. WARNING : There is some special restrictions according the user that create sale offer # All : - Owner should have a valid mangopay mandate - Unit price should be lower than product unitPrice # Pharmacy : - Can only create UNITARY sale offer - Sale offer should have at least one item in quantity - Can not set images on sale offers - Can not create sale offers without stock - Can create sale offer only for legal allowed products - Batch should be auhtorized by ANSM/DGCCRF - Lapsing date of stock must be after REQUIRED_LAPSING_MONTHS months # Laboratory : - Can not create a sale offer on a product that already have an existing non-disabled sale offer - Can create sale offer without lapsing - Can create sale offer without remaining quantity
52
52
  * Create a new sale offer
53
53
  */
54
54
  createSaleOffer(requestParameters: CreateSaleOfferRequest): Promise<SaleOffer | BlobWithMeta>;
@@ -76,7 +76,7 @@ var ManageSaleOfferApi = /** @class */ (function (_super) {
76
76
  return _super !== null && _super.apply(this, arguments) || this;
77
77
  }
78
78
  /**
79
- * Create a new sale offer. WARNING : There is some special restrictions according the user that create sale offer # All : - Owner should have a valid mangopay mandate - Unit price should be lower than product unitPrice - For unitary sale offer, minimalQuantity should be lower than stock remainingQuantity # Pharmacy : - Can only create UNITARY sale offer - Sale offer should have at least one item in quantity - Can not set images on sale offers - Can not create sale offers without stock - Can create sale offer only for legal allowed products - Batch should be auhtorized by ANSM/DGCCRF - Lapsing date of stock must be after REQUIRED_LAPSING_MONTHS months # Laboratory : - Can not create a sale offer on a product that already have an existing non-disabled sale offer - Can create sale offer without lapsing - Can create sale offer without remaining quantity
79
+ * Create a new sale offer. WARNING : There is some special restrictions according the user that create sale offer # All : - Owner should have a valid mangopay mandate - Unit price should be lower than product unitPrice # Pharmacy : - Can only create UNITARY sale offer - Sale offer should have at least one item in quantity - Can not set images on sale offers - Can not create sale offers without stock - Can create sale offer only for legal allowed products - Batch should be auhtorized by ANSM/DGCCRF - Lapsing date of stock must be after REQUIRED_LAPSING_MONTHS months # Laboratory : - Can not create a sale offer on a product that already have an existing non-disabled sale offer - Can create sale offer without lapsing - Can create sale offer without remaining quantity
80
80
  * Create a new sale offer
81
81
  */
82
82
  ManageSaleOfferApi.prototype.createSaleOfferRaw = function (requestParameters) {
@@ -143,7 +143,7 @@ var ManageSaleOfferApi = /** @class */ (function (_super) {
143
143
  });
144
144
  };
145
145
  /**
146
- * Create a new sale offer. WARNING : There is some special restrictions according the user that create sale offer # All : - Owner should have a valid mangopay mandate - Unit price should be lower than product unitPrice - For unitary sale offer, minimalQuantity should be lower than stock remainingQuantity # Pharmacy : - Can only create UNITARY sale offer - Sale offer should have at least one item in quantity - Can not set images on sale offers - Can not create sale offers without stock - Can create sale offer only for legal allowed products - Batch should be auhtorized by ANSM/DGCCRF - Lapsing date of stock must be after REQUIRED_LAPSING_MONTHS months # Laboratory : - Can not create a sale offer on a product that already have an existing non-disabled sale offer - Can create sale offer without lapsing - Can create sale offer without remaining quantity
146
+ * Create a new sale offer. WARNING : There is some special restrictions according the user that create sale offer # All : - Owner should have a valid mangopay mandate - Unit price should be lower than product unitPrice # Pharmacy : - Can only create UNITARY sale offer - Sale offer should have at least one item in quantity - Can not set images on sale offers - Can not create sale offers without stock - Can create sale offer only for legal allowed products - Batch should be auhtorized by ANSM/DGCCRF - Lapsing date of stock must be after REQUIRED_LAPSING_MONTHS months # Laboratory : - Can not create a sale offer on a product that already have an existing non-disabled sale offer - Can create sale offer without lapsing - Can create sale offer without remaining quantity
147
147
  * Create a new sale offer
148
148
  */
149
149
  ManageSaleOfferApi.prototype.createSaleOffer = function (requestParameters) {
@@ -58,7 +58,7 @@ export interface SaleOffer {
58
58
  * @type {AnyIdentifiedDistributionMode}
59
59
  * @memberof SaleOffer
60
60
  */
61
- distributionMode?: AnyIdentifiedDistributionMode;
61
+ distributionMode?: AnyIdentifiedDistributionMode | null;
62
62
  /**
63
63
  * The minimal unit price for this sale offer.
64
64
  * @type {number}
@@ -37,7 +37,7 @@ function SaleOfferFromJSONTyped(json, ignoreDiscriminator) {
37
37
  'product': !(0, runtime_1.exists)(json, 'product') ? undefined : (0, ProductLink_1.ProductLinkFromJSON)(json['product']),
38
38
  'stock': !(0, runtime_1.exists)(json, 'stock') ? undefined : (0, Stock_1.StockFromJSON)(json['stock']),
39
39
  'description': !(0, runtime_1.exists)(json, 'description') ? json['description'] : json['description'],
40
- 'distributionMode': !(0, runtime_1.exists)(json, 'distributionMode') ? undefined : (0, AnyIdentifiedDistributionMode_1.AnyIdentifiedDistributionModeFromJSON)(json['distributionMode']),
40
+ 'distributionMode': !(0, runtime_1.exists)(json, 'distributionMode') ? json['distributionMode'] : (0, AnyIdentifiedDistributionMode_1.AnyIdentifiedDistributionModeFromJSON)(json['distributionMode']),
41
41
  'minimalUnitPrice': !(0, runtime_1.exists)(json, 'minimalUnitPrice') ? undefined : json['minimalUnitPrice'],
42
42
  'bestRebate': !(0, runtime_1.exists)(json, 'bestRebate') ? undefined : json['bestRebate'],
43
43
  'owner': !(0, runtime_1.exists)(json, 'owner') ? undefined : (0, OwnerLink_1.OwnerLinkFromJSON)(json['owner']),
@@ -13,7 +13,7 @@ import { AnyDistributionMode } from './AnyDistributionMode';
13
13
  import { SaleOfferCreationImagesParameters } from './SaleOfferCreationImagesParameters';
14
14
  import { Stock } from './Stock';
15
15
  /**
16
- * All these fields are optional when copying from an existing ad. List of fields required in case of sale offer creation from scratch : - ownerId - productId - distributionMode
16
+ * All these fields are required for ad creation from scratch but optional when copying from an existing ad
17
17
  * @export
18
18
  * @interface SaleOfferCreationParameters
19
19
  */
@@ -41,7 +41,7 @@ export interface SaleOfferCreationParameters {
41
41
  * @type {AnyDistributionMode}
42
42
  * @memberof SaleOfferCreationParameters
43
43
  */
44
- distributionMode?: AnyDistributionMode;
44
+ distributionMode?: AnyDistributionMode | null;
45
45
  /**
46
46
  * Free text to describe this ad
47
47
  * @type {string}
@@ -30,7 +30,7 @@ function SaleOfferCreationParametersFromJSONTyped(json, ignoreDiscriminator) {
30
30
  'ownerId': !(0, runtime_1.exists)(json, 'ownerId') ? undefined : json['ownerId'],
31
31
  'productId': !(0, runtime_1.exists)(json, 'productId') ? undefined : json['productId'],
32
32
  'stock': !(0, runtime_1.exists)(json, 'stock') ? undefined : (0, Stock_1.StockFromJSON)(json['stock']),
33
- 'distributionMode': !(0, runtime_1.exists)(json, 'distributionMode') ? undefined : (0, AnyDistributionMode_1.AnyDistributionModeFromJSON)(json['distributionMode']),
33
+ 'distributionMode': !(0, runtime_1.exists)(json, 'distributionMode') ? json['distributionMode'] : (0, AnyDistributionMode_1.AnyDistributionModeFromJSON)(json['distributionMode']),
34
34
  'description': !(0, runtime_1.exists)(json, 'description') ? json['description'] : json['description'],
35
35
  'images': !(0, runtime_1.exists)(json, 'images') ? undefined : (0, SaleOfferCreationImagesParameters_1.SaleOfferCreationImagesParametersFromJSON)(json['images']),
36
36
  'rank': !(0, runtime_1.exists)(json, 'rank') ? json['rank'] : json['rank'],
@@ -20,7 +20,7 @@ export interface SaleOfferJournal {
20
20
  * @type {Date}
21
21
  * @memberof SaleOfferJournal
22
22
  */
23
- statusUpdatedAt: Date;
23
+ statusUpdatedAt?: Date;
24
24
  }
25
25
  export declare function SaleOfferJournalFromJSON(json: any): SaleOfferJournal;
26
26
  export declare function SaleOfferJournalFromJSONTyped(json: any, ignoreDiscriminator: boolean): SaleOfferJournal;
@@ -14,6 +14,7 @@
14
14
  */
15
15
  Object.defineProperty(exports, "__esModule", { value: true });
16
16
  exports.SaleOfferJournalToJSON = exports.SaleOfferJournalFromJSONTyped = exports.SaleOfferJournalFromJSON = void 0;
17
+ var runtime_1 = require("../runtime");
17
18
  function SaleOfferJournalFromJSON(json) {
18
19
  return SaleOfferJournalFromJSONTyped(json, false);
19
20
  }
@@ -23,7 +24,7 @@ function SaleOfferJournalFromJSONTyped(json, ignoreDiscriminator) {
23
24
  return json;
24
25
  }
25
26
  return {
26
- 'statusUpdatedAt': (new Date(json['statusUpdatedAt'])),
27
+ 'statusUpdatedAt': !(0, runtime_1.exists)(json, 'statusUpdatedAt') ? undefined : (new Date(json['statusUpdatedAt'])),
27
28
  };
28
29
  }
29
30
  exports.SaleOfferJournalFromJSONTyped = SaleOfferJournalFromJSONTyped;
@@ -35,7 +36,7 @@ function SaleOfferJournalToJSON(value) {
35
36
  return null;
36
37
  }
37
38
  return {
38
- 'statusUpdatedAt': (value.statusUpdatedAt.toISOString()),
39
+ 'statusUpdatedAt': value.statusUpdatedAt === undefined ? undefined : (value.statusUpdatedAt.toISOString()),
39
40
  };
40
41
  }
41
42
  exports.SaleOfferJournalToJSON = SaleOfferJournalToJSON;
@@ -29,7 +29,7 @@ export interface SaleOfferNewVersionParameters {
29
29
  * @type {AnyDistributionMode}
30
30
  * @memberof SaleOfferNewVersionParameters
31
31
  */
32
- distributionMode?: AnyDistributionMode;
32
+ distributionMode?: AnyDistributionMode | null;
33
33
  /**
34
34
  *
35
35
  * @type {SaleOfferCreationImagesParameters}
@@ -28,7 +28,7 @@ function SaleOfferNewVersionParametersFromJSONTyped(json, ignoreDiscriminator) {
28
28
  }
29
29
  return {
30
30
  'stock': !(0, runtime_1.exists)(json, 'stock') ? undefined : (0, Stock_1.StockFromJSON)(json['stock']),
31
- 'distributionMode': !(0, runtime_1.exists)(json, 'distributionMode') ? undefined : (0, AnyDistributionMode_1.AnyDistributionModeFromJSON)(json['distributionMode']),
31
+ 'distributionMode': !(0, runtime_1.exists)(json, 'distributionMode') ? json['distributionMode'] : (0, AnyDistributionMode_1.AnyDistributionModeFromJSON)(json['distributionMode']),
32
32
  'images': !(0, runtime_1.exists)(json, 'images') ? undefined : (0, SaleOfferCreationImagesParameters_1.SaleOfferCreationImagesParametersFromJSON)(json['images']),
33
33
  'description': !(0, runtime_1.exists)(json, 'description') ? json['description'] : json['description'],
34
34
  'rank': !(0, runtime_1.exists)(json, 'rank') ? json['rank'] : json['rank'],