@lcdp/api-react-rest-client 2.5.14-develop.8063982322 → 2.5.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (39) hide show
  1. package/configuration/src/apis/ManageVariableApi.d.ts +1 -28
  2. package/configuration/src/apis/ManageVariableApi.js +4 -160
  3. package/configuration/src/models/Variable.d.ts +2 -2
  4. package/configuration/src/models/Variable.js +3 -2
  5. package/configuration/src/models/Vat.d.ts +3 -3
  6. package/configuration/src/models/Vat.js +4 -3
  7. package/order/src/apis/SearchOrderApi.d.ts +1 -1
  8. package/order/src/apis/SearchOrderApi.js +2 -2
  9. package/order/src/apis/index.d.ts +0 -2
  10. package/order/src/apis/index.js +0 -2
  11. package/order/src/models/OrderJournal.d.ts +1 -1
  12. package/order/src/models/OrderJournal.js +2 -2
  13. package/order/src/models/index.d.ts +0 -6
  14. package/order/src/models/index.js +0 -6
  15. package/package.json +1 -1
  16. package/product/src/apis/SearchProductApi.d.ts +1 -1
  17. package/product/src/apis/SearchProductApi.js +2 -2
  18. package/product/src/models/Vat.d.ts +3 -3
  19. package/product/src/models/Vat.js +4 -3
  20. package/pub/src/apis/SearchPubApi.d.ts +1 -1
  21. package/pub/src/apis/SearchPubApi.js +2 -2
  22. package/user/src/apis/SearchUserApi.d.ts +1 -1
  23. package/user/src/apis/SearchUserApi.js +2 -2
  24. package/order/src/apis/ManageFreeCarriageCouponApi.d.ts +0 -42
  25. package/order/src/apis/ManageFreeCarriageCouponApi.js +0 -233
  26. package/order/src/apis/SearchFreeCarriageCouponApi.d.ts +0 -49
  27. package/order/src/apis/SearchFreeCarriageCouponApi.js +0 -202
  28. package/order/src/models/FreeCarriageCoupon.d.ts +0 -82
  29. package/order/src/models/FreeCarriageCoupon.js +0 -61
  30. package/order/src/models/FreeCarriageCouponCreationParameters.d.ts +0 -57
  31. package/order/src/models/FreeCarriageCouponCreationParameters.js +0 -52
  32. package/order/src/models/FreeCarriageCouponOwnerLink.d.ts +0 -28
  33. package/order/src/models/FreeCarriageCouponOwnerLink.js +0 -49
  34. package/order/src/models/FreeCarriageCouponOwnerLinkAllOf.d.ts +0 -27
  35. package/order/src/models/FreeCarriageCouponOwnerLinkAllOf.js +0 -41
  36. package/order/src/models/PaginatedFreeCarriageCoupons.d.ts +0 -29
  37. package/order/src/models/PaginatedFreeCarriageCoupons.js +0 -50
  38. package/order/src/models/PaginatedFreeCarriageCouponsAllOf.d.ts +0 -28
  39. package/order/src/models/PaginatedFreeCarriageCouponsAllOf.js +0 -42
@@ -1,233 +0,0 @@
1
- "use strict";
2
- /* tslint:disable */
3
- /* eslint-disable */
4
- /**
5
- * lcdp-monolith-service
6
- * This is the REST API of LCDP orders
7
- *
8
- * The version of the OpenAPI document: 1.0.0
9
- * Contact: contact@lecomptoirdespharmacies.fr
10
- *
11
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
- * https://openapi-generator.tech
13
- * Do not edit the class manually.
14
- */
15
- var __extends = (this && this.__extends) || (function () {
16
- var extendStatics = function (d, b) {
17
- extendStatics = Object.setPrototypeOf ||
18
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
19
- function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
20
- return extendStatics(d, b);
21
- };
22
- return function (d, b) {
23
- if (typeof b !== "function" && b !== null)
24
- throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
25
- extendStatics(d, b);
26
- function __() { this.constructor = d; }
27
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
28
- };
29
- })();
30
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
31
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
32
- return new (P || (P = Promise))(function (resolve, reject) {
33
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
34
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
35
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
36
- step((generator = generator.apply(thisArg, _arguments || [])).next());
37
- });
38
- };
39
- var __generator = (this && this.__generator) || function (thisArg, body) {
40
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
41
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
42
- function verb(n) { return function (v) { return step([n, v]); }; }
43
- function step(op) {
44
- if (f) throw new TypeError("Generator is already executing.");
45
- while (_) try {
46
- if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
47
- if (y = 0, t) op = [op[0] & 2, t.value];
48
- switch (op[0]) {
49
- case 0: case 1: t = op; break;
50
- case 4: _.label++; return { value: op[1], done: false };
51
- case 5: _.label++; y = op[1]; op = [0]; continue;
52
- case 7: op = _.ops.pop(); _.trys.pop(); continue;
53
- default:
54
- if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
55
- if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
56
- if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
57
- if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
58
- if (t[2]) _.ops.pop();
59
- _.trys.pop(); continue;
60
- }
61
- op = body.call(thisArg, _);
62
- } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
63
- if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
64
- }
65
- };
66
- Object.defineProperty(exports, "__esModule", { value: true });
67
- exports.ManageFreeCarriageCouponApi = void 0;
68
- var runtime_1 = require("../runtime");
69
- var models_1 = require("../models");
70
- /**
71
- * no description
72
- */
73
- var ManageFreeCarriageCouponApi = /** @class */ (function (_super) {
74
- __extends(ManageFreeCarriageCouponApi, _super);
75
- function ManageFreeCarriageCouponApi() {
76
- return _super !== null && _super.apply(this, arguments) || this;
77
- }
78
- /**
79
- * This endpoint allow you to create one or multiple coupons in one API call
80
- * Create free carriage coupons
81
- */
82
- ManageFreeCarriageCouponApi.prototype.createFreeCarriageCouponsRaw = function (requestParameters) {
83
- return __awaiter(this, void 0, void 0, function () {
84
- var queryParameters, headerParameters, token, tokenString, _a, response, contentType, response_1;
85
- return __generator(this, function (_b) {
86
- switch (_b.label) {
87
- case 0:
88
- if (requestParameters.freeCarriageCouponCreationParameters === null || requestParameters.freeCarriageCouponCreationParameters === undefined) {
89
- throw new runtime_1.RequiredError('freeCarriageCouponCreationParameters', 'Required parameter requestParameters.freeCarriageCouponCreationParameters was null or undefined when calling createFreeCarriageCoupons.');
90
- }
91
- queryParameters = {};
92
- headerParameters = {};
93
- headerParameters['Content-Type'] = 'application/json';
94
- if (this.configuration && this.configuration.apiKey) {
95
- headerParameters["x-api-key"] = this.configuration.apiKey("x-api-key"); // apiKeyAuth authentication
96
- }
97
- if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 4];
98
- token = this.configuration.accessToken;
99
- if (!(typeof token === 'function')) return [3 /*break*/, 2];
100
- return [4 /*yield*/, token("bearerAuth", [])];
101
- case 1:
102
- _a = _b.sent();
103
- return [3 /*break*/, 3];
104
- case 2:
105
- _a = token;
106
- _b.label = 3;
107
- case 3:
108
- tokenString = _a;
109
- if (tokenString) {
110
- headerParameters["Authorization"] = "Bearer ".concat(tokenString);
111
- }
112
- _b.label = 4;
113
- case 4:
114
- _b.trys.push([4, 6, , 7]);
115
- return [4 /*yield*/, this.request({
116
- path: "/free-carriage-coupons",
117
- method: 'POST',
118
- headers: headerParameters,
119
- query: queryParameters,
120
- body: requestParameters.freeCarriageCouponCreationParameters.map(models_1.FreeCarriageCouponCreationParametersToJSON),
121
- })];
122
- case 5:
123
- response = _b.sent();
124
- contentType = response.headers.get("content-type");
125
- if (contentType && contentType.indexOf("application/json") !== -1) {
126
- return [2 /*return*/, new runtime_1.JSONApiResponse(response, function (jsonValue) { return jsonValue.map(models_1.FreeCarriageCouponFromJSON); })];
127
- }
128
- else if (contentType && contentType.indexOf("text/plain") !== -1) {
129
- return [2 /*return*/, new runtime_1.TextApiResponse(response)];
130
- }
131
- else {
132
- // TODO : Better handling of others application types
133
- return [2 /*return*/, new runtime_1.BlobWithMetaApiResponse(response)];
134
- }
135
- return [3 /*break*/, 7];
136
- case 6:
137
- response_1 = _b.sent();
138
- console.debug(response_1);
139
- throw response_1;
140
- case 7: return [2 /*return*/];
141
- }
142
- });
143
- });
144
- };
145
- /**
146
- * This endpoint allow you to create one or multiple coupons in one API call
147
- * Create free carriage coupons
148
- */
149
- ManageFreeCarriageCouponApi.prototype.createFreeCarriageCoupons = function (requestParameters) {
150
- return __awaiter(this, void 0, void 0, function () {
151
- var response;
152
- return __generator(this, function (_a) {
153
- switch (_a.label) {
154
- case 0: return [4 /*yield*/, this.createFreeCarriageCouponsRaw(requestParameters)];
155
- case 1:
156
- response = _a.sent();
157
- return [4 /*yield*/, response.value()];
158
- case 2: return [2 /*return*/, _a.sent()];
159
- }
160
- });
161
- });
162
- };
163
- /**
164
- * Remove a coupon from the system
165
- */
166
- ManageFreeCarriageCouponApi.prototype.deleteFreeCarriageCouponRaw = function (requestParameters) {
167
- return __awaiter(this, void 0, void 0, function () {
168
- var queryParameters, headerParameters, token, tokenString, _a, response, response_2;
169
- return __generator(this, function (_b) {
170
- switch (_b.label) {
171
- case 0:
172
- if (requestParameters.freeCarriageCouponId === null || requestParameters.freeCarriageCouponId === undefined) {
173
- throw new runtime_1.RequiredError('freeCarriageCouponId', 'Required parameter requestParameters.freeCarriageCouponId was null or undefined when calling deleteFreeCarriageCoupon.');
174
- }
175
- queryParameters = {};
176
- headerParameters = {};
177
- if (this.configuration && this.configuration.apiKey) {
178
- headerParameters["x-api-key"] = this.configuration.apiKey("x-api-key"); // apiKeyAuth authentication
179
- }
180
- if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 4];
181
- token = this.configuration.accessToken;
182
- if (!(typeof token === 'function')) return [3 /*break*/, 2];
183
- return [4 /*yield*/, token("bearerAuth", [])];
184
- case 1:
185
- _a = _b.sent();
186
- return [3 /*break*/, 3];
187
- case 2:
188
- _a = token;
189
- _b.label = 3;
190
- case 3:
191
- tokenString = _a;
192
- if (tokenString) {
193
- headerParameters["Authorization"] = "Bearer ".concat(tokenString);
194
- }
195
- _b.label = 4;
196
- case 4:
197
- _b.trys.push([4, 6, , 7]);
198
- return [4 /*yield*/, this.request({
199
- path: "/free-carriage-coupons/{freeCarriageCouponId}".replace("{".concat("freeCarriageCouponId", "}"), encodeURIComponent(String(requestParameters.freeCarriageCouponId))),
200
- method: 'DELETE',
201
- headers: headerParameters,
202
- query: queryParameters,
203
- })];
204
- case 5:
205
- response = _b.sent();
206
- return [2 /*return*/, new runtime_1.VoidApiResponse(response)];
207
- case 6:
208
- response_2 = _b.sent();
209
- console.debug(response_2);
210
- throw response_2;
211
- case 7: return [2 /*return*/];
212
- }
213
- });
214
- });
215
- };
216
- /**
217
- * Remove a coupon from the system
218
- */
219
- ManageFreeCarriageCouponApi.prototype.deleteFreeCarriageCoupon = function (requestParameters) {
220
- return __awaiter(this, void 0, void 0, function () {
221
- return __generator(this, function (_a) {
222
- switch (_a.label) {
223
- case 0: return [4 /*yield*/, this.deleteFreeCarriageCouponRaw(requestParameters)];
224
- case 1:
225
- _a.sent();
226
- return [2 /*return*/];
227
- }
228
- });
229
- });
230
- };
231
- return ManageFreeCarriageCouponApi;
232
- }(runtime_1.BaseAPI));
233
- exports.ManageFreeCarriageCouponApi = ManageFreeCarriageCouponApi;
@@ -1,49 +0,0 @@
1
- /**
2
- * lcdp-monolith-service
3
- * This is the REST API of LCDP orders
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 { BaseAPI, ApiResponse, BlobWithMeta } from '../runtime';
13
- import { PaginatedFreeCarriageCoupons } from '../models';
14
- export interface GetFreeCarriageCouponsRequest {
15
- ownerEq?: Array<number>;
16
- validFromGte?: Date;
17
- validFromLte?: Date;
18
- validToGte?: Date;
19
- validToLte?: Date;
20
- usedAtPr?: boolean;
21
- tagsCo?: Array<string>;
22
- tagsNco?: Array<string>;
23
- orderBy?: GetFreeCarriageCouponsOrderByEnum;
24
- p?: number;
25
- pp?: number;
26
- }
27
- /**
28
- * no description
29
- */
30
- export declare class SearchFreeCarriageCouponApi extends BaseAPI {
31
- /**
32
- * This endpoint allow you to retrieve the free carriage coupons of the system
33
- * Get free carriage coupons
34
- */
35
- getFreeCarriageCouponsRaw(requestParameters: GetFreeCarriageCouponsRequest): Promise<ApiResponse<PaginatedFreeCarriageCoupons | BlobWithMeta>>;
36
- /**
37
- * This endpoint allow you to retrieve the free carriage coupons of the system
38
- * Get free carriage coupons
39
- */
40
- getFreeCarriageCoupons(requestParameters: GetFreeCarriageCouponsRequest): Promise<PaginatedFreeCarriageCoupons | BlobWithMeta>;
41
- }
42
- /**
43
- * @export
44
- * @enum {string}
45
- */
46
- export declare enum GetFreeCarriageCouponsOrderByEnum {
47
- ASC = "CREATED_AT:ASC",
48
- DESC = "CREATED_AT:DESC"
49
- }
@@ -1,202 +0,0 @@
1
- "use strict";
2
- /* tslint:disable */
3
- /* eslint-disable */
4
- /**
5
- * lcdp-monolith-service
6
- * This is the REST API of LCDP orders
7
- *
8
- * The version of the OpenAPI document: 1.0.0
9
- * Contact: contact@lecomptoirdespharmacies.fr
10
- *
11
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
- * https://openapi-generator.tech
13
- * Do not edit the class manually.
14
- */
15
- var __extends = (this && this.__extends) || (function () {
16
- var extendStatics = function (d, b) {
17
- extendStatics = Object.setPrototypeOf ||
18
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
19
- function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
20
- return extendStatics(d, b);
21
- };
22
- return function (d, b) {
23
- if (typeof b !== "function" && b !== null)
24
- throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
25
- extendStatics(d, b);
26
- function __() { this.constructor = d; }
27
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
28
- };
29
- })();
30
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
31
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
32
- return new (P || (P = Promise))(function (resolve, reject) {
33
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
34
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
35
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
36
- step((generator = generator.apply(thisArg, _arguments || [])).next());
37
- });
38
- };
39
- var __generator = (this && this.__generator) || function (thisArg, body) {
40
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
41
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
42
- function verb(n) { return function (v) { return step([n, v]); }; }
43
- function step(op) {
44
- if (f) throw new TypeError("Generator is already executing.");
45
- while (_) try {
46
- if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
47
- if (y = 0, t) op = [op[0] & 2, t.value];
48
- switch (op[0]) {
49
- case 0: case 1: t = op; break;
50
- case 4: _.label++; return { value: op[1], done: false };
51
- case 5: _.label++; y = op[1]; op = [0]; continue;
52
- case 7: op = _.ops.pop(); _.trys.pop(); continue;
53
- default:
54
- if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
55
- if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
56
- if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
57
- if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
58
- if (t[2]) _.ops.pop();
59
- _.trys.pop(); continue;
60
- }
61
- op = body.call(thisArg, _);
62
- } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
63
- if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
64
- }
65
- };
66
- Object.defineProperty(exports, "__esModule", { value: true });
67
- exports.GetFreeCarriageCouponsOrderByEnum = exports.SearchFreeCarriageCouponApi = void 0;
68
- var runtime_1 = require("../runtime");
69
- var models_1 = require("../models");
70
- /**
71
- * no description
72
- */
73
- var SearchFreeCarriageCouponApi = /** @class */ (function (_super) {
74
- __extends(SearchFreeCarriageCouponApi, _super);
75
- function SearchFreeCarriageCouponApi() {
76
- return _super !== null && _super.apply(this, arguments) || this;
77
- }
78
- /**
79
- * This endpoint allow you to retrieve the free carriage coupons of the system
80
- * Get free carriage coupons
81
- */
82
- SearchFreeCarriageCouponApi.prototype.getFreeCarriageCouponsRaw = function (requestParameters) {
83
- return __awaiter(this, void 0, void 0, function () {
84
- var queryParameters, headerParameters, token, tokenString, _a, response, contentType, response_1;
85
- return __generator(this, function (_b) {
86
- switch (_b.label) {
87
- case 0:
88
- queryParameters = {};
89
- if (requestParameters.ownerEq) {
90
- queryParameters['owner[eq]'] = requestParameters.ownerEq;
91
- }
92
- if (requestParameters.validFromGte !== undefined) {
93
- queryParameters['validFrom[gte]'] = requestParameters.validFromGte.toISOString();
94
- }
95
- if (requestParameters.validFromLte !== undefined) {
96
- queryParameters['validFrom[lte]'] = requestParameters.validFromLte.toISOString();
97
- }
98
- if (requestParameters.validToGte !== undefined) {
99
- queryParameters['validTo[gte]'] = requestParameters.validToGte.toISOString();
100
- }
101
- if (requestParameters.validToLte !== undefined) {
102
- queryParameters['validTo[lte]'] = requestParameters.validToLte.toISOString();
103
- }
104
- if (requestParameters.usedAtPr !== undefined) {
105
- queryParameters['usedAt[pr]'] = requestParameters.usedAtPr;
106
- }
107
- if (requestParameters.tagsCo) {
108
- queryParameters['tags[co]'] = requestParameters.tagsCo;
109
- }
110
- if (requestParameters.tagsNco) {
111
- queryParameters['tags[nco]'] = requestParameters.tagsNco;
112
- }
113
- if (requestParameters.orderBy !== undefined) {
114
- queryParameters['orderBy'] = requestParameters.orderBy;
115
- }
116
- if (requestParameters.p !== undefined) {
117
- queryParameters['p'] = requestParameters.p;
118
- }
119
- if (requestParameters.pp !== undefined) {
120
- queryParameters['pp'] = requestParameters.pp;
121
- }
122
- headerParameters = {};
123
- if (this.configuration && this.configuration.apiKey) {
124
- headerParameters["x-api-key"] = this.configuration.apiKey("x-api-key"); // apiKeyAuth authentication
125
- }
126
- if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 4];
127
- token = this.configuration.accessToken;
128
- if (!(typeof token === 'function')) return [3 /*break*/, 2];
129
- return [4 /*yield*/, token("bearerAuth", [])];
130
- case 1:
131
- _a = _b.sent();
132
- return [3 /*break*/, 3];
133
- case 2:
134
- _a = token;
135
- _b.label = 3;
136
- case 3:
137
- tokenString = _a;
138
- if (tokenString) {
139
- headerParameters["Authorization"] = "Bearer ".concat(tokenString);
140
- }
141
- _b.label = 4;
142
- case 4:
143
- _b.trys.push([4, 6, , 7]);
144
- return [4 /*yield*/, this.request({
145
- path: "/free-carriage-coupons",
146
- method: 'GET',
147
- headers: headerParameters,
148
- query: queryParameters,
149
- })];
150
- case 5:
151
- response = _b.sent();
152
- contentType = response.headers.get("content-type");
153
- if (contentType && contentType.indexOf("application/json") !== -1) {
154
- return [2 /*return*/, new runtime_1.JSONApiResponse(response, function (jsonValue) { return (0, models_1.PaginatedFreeCarriageCouponsFromJSON)(jsonValue); })];
155
- }
156
- else if (contentType && contentType.indexOf("text/plain") !== -1) {
157
- return [2 /*return*/, new runtime_1.TextApiResponse(response)];
158
- }
159
- else {
160
- // TODO : Better handling of others application types
161
- return [2 /*return*/, new runtime_1.BlobWithMetaApiResponse(response)];
162
- }
163
- return [3 /*break*/, 7];
164
- case 6:
165
- response_1 = _b.sent();
166
- console.debug(response_1);
167
- throw response_1;
168
- case 7: return [2 /*return*/];
169
- }
170
- });
171
- });
172
- };
173
- /**
174
- * This endpoint allow you to retrieve the free carriage coupons of the system
175
- * Get free carriage coupons
176
- */
177
- SearchFreeCarriageCouponApi.prototype.getFreeCarriageCoupons = function (requestParameters) {
178
- return __awaiter(this, void 0, void 0, function () {
179
- var response;
180
- return __generator(this, function (_a) {
181
- switch (_a.label) {
182
- case 0: return [4 /*yield*/, this.getFreeCarriageCouponsRaw(requestParameters)];
183
- case 1:
184
- response = _a.sent();
185
- return [4 /*yield*/, response.value()];
186
- case 2: return [2 /*return*/, _a.sent()];
187
- }
188
- });
189
- });
190
- };
191
- return SearchFreeCarriageCouponApi;
192
- }(runtime_1.BaseAPI));
193
- exports.SearchFreeCarriageCouponApi = SearchFreeCarriageCouponApi;
194
- /**
195
- * @export
196
- * @enum {string}
197
- */
198
- var GetFreeCarriageCouponsOrderByEnum;
199
- (function (GetFreeCarriageCouponsOrderByEnum) {
200
- GetFreeCarriageCouponsOrderByEnum["ASC"] = "CREATED_AT:ASC";
201
- GetFreeCarriageCouponsOrderByEnum["DESC"] = "CREATED_AT:DESC";
202
- })(GetFreeCarriageCouponsOrderByEnum = exports.GetFreeCarriageCouponsOrderByEnum || (exports.GetFreeCarriageCouponsOrderByEnum = {}));
@@ -1,82 +0,0 @@
1
- /**
2
- * lcdp-monolith-service
3
- * This is the REST API of LCDP orders
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 { FreeCarriageCouponOwnerLink } from './FreeCarriageCouponOwnerLink';
13
- /**
14
- *
15
- * @export
16
- * @interface FreeCarriageCoupon
17
- */
18
- export interface FreeCarriageCoupon {
19
- /**
20
- * Id of the coupon
21
- * @type {number}
22
- * @memberof FreeCarriageCoupon
23
- */
24
- id: number;
25
- /**
26
- *
27
- * @type {FreeCarriageCouponOwnerLink}
28
- * @memberof FreeCarriageCoupon
29
- */
30
- owner: FreeCarriageCouponOwnerLink;
31
- /**
32
- * Coupon is valid starting from this date (Format uses RFC 3339, section 5.6 - null value is considered as start of universe which means coupon will is valid until validTo)
33
- * @type {Date}
34
- * @memberof FreeCarriageCoupon
35
- */
36
- validFrom: Date | null;
37
- /**
38
- * Coupon is valid until this date (Format uses RFC 3339, section 5.6 - null value is considered as infinite which means coupon will never expires)
39
- * @type {Date}
40
- * @memberof FreeCarriageCoupon
41
- */
42
- validTo: Date | null;
43
- /**
44
- * Indicate the priority of the coupon. The higher the value, the higher the priority
45
- * @type {number}
46
- * @memberof FreeCarriageCoupon
47
- */
48
- weight: number;
49
- /**
50
- * Comment about coupon
51
- * @type {string}
52
- * @memberof FreeCarriageCoupon
53
- */
54
- comment?: string | null;
55
- /**
56
- * A list of free texts to qualify the coupon
57
- * @type {Array<string>}
58
- * @memberof FreeCarriageCoupon
59
- */
60
- tags: Array<string>;
61
- /**
62
- * Creation date of this Content
63
- * @type {Date}
64
- * @memberof FreeCarriageCoupon
65
- */
66
- createdAt: Date;
67
- /**
68
- * Last update date of this Content
69
- * @type {Date}
70
- * @memberof FreeCarriageCoupon
71
- */
72
- updatedAt: Date;
73
- /**
74
- * Date when coupon was used. If null, the coupon is still unused.
75
- * @type {Date}
76
- * @memberof FreeCarriageCoupon
77
- */
78
- usedAt: Date | null;
79
- }
80
- export declare function FreeCarriageCouponFromJSON(json: any): FreeCarriageCoupon;
81
- export declare function FreeCarriageCouponFromJSONTyped(json: any, ignoreDiscriminator: boolean): FreeCarriageCoupon;
82
- export declare function FreeCarriageCouponToJSON(value?: FreeCarriageCoupon | null): any;
@@ -1,61 +0,0 @@
1
- "use strict";
2
- /* tslint:disable */
3
- /* eslint-disable */
4
- /**
5
- * lcdp-monolith-service
6
- * This is the REST API of LCDP orders
7
- *
8
- * The version of the OpenAPI document: 1.0.0
9
- * Contact: contact@lecomptoirdespharmacies.fr
10
- *
11
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
- * https://openapi-generator.tech
13
- * Do not edit the class manually.
14
- */
15
- Object.defineProperty(exports, "__esModule", { value: true });
16
- exports.FreeCarriageCouponToJSON = exports.FreeCarriageCouponFromJSONTyped = exports.FreeCarriageCouponFromJSON = void 0;
17
- var runtime_1 = require("../runtime");
18
- var FreeCarriageCouponOwnerLink_1 = require("./FreeCarriageCouponOwnerLink");
19
- function FreeCarriageCouponFromJSON(json) {
20
- return FreeCarriageCouponFromJSONTyped(json, false);
21
- }
22
- exports.FreeCarriageCouponFromJSON = FreeCarriageCouponFromJSON;
23
- function FreeCarriageCouponFromJSONTyped(json, ignoreDiscriminator) {
24
- if ((json === undefined) || (json === null)) {
25
- return json;
26
- }
27
- return {
28
- 'id': json['id'],
29
- 'owner': (0, FreeCarriageCouponOwnerLink_1.FreeCarriageCouponOwnerLinkFromJSON)(json['owner']),
30
- 'validFrom': (json['validFrom'] === null ? null : new Date(json['validFrom'])),
31
- 'validTo': (json['validTo'] === null ? null : new Date(json['validTo'])),
32
- 'weight': json['weight'],
33
- 'comment': !(0, runtime_1.exists)(json, 'comment') ? json['comment'] : json['comment'],
34
- 'tags': json['tags'],
35
- 'createdAt': (new Date(json['createdAt'])),
36
- 'updatedAt': (new Date(json['updatedAt'])),
37
- 'usedAt': (json['usedAt'] === null ? null : new Date(json['usedAt'])),
38
- };
39
- }
40
- exports.FreeCarriageCouponFromJSONTyped = FreeCarriageCouponFromJSONTyped;
41
- function FreeCarriageCouponToJSON(value) {
42
- if (value === undefined) {
43
- return undefined;
44
- }
45
- if (value === null) {
46
- return null;
47
- }
48
- return {
49
- 'id': value.id,
50
- 'owner': (0, FreeCarriageCouponOwnerLink_1.FreeCarriageCouponOwnerLinkToJSON)(value.owner),
51
- 'validFrom': (value.validFrom === null ? null : value.validFrom.toISOString()),
52
- 'validTo': (value.validTo === null ? null : value.validTo.toISOString()),
53
- 'weight': value.weight,
54
- 'comment': value.comment,
55
- 'tags': value.tags,
56
- 'createdAt': (value.createdAt.toISOString()),
57
- 'updatedAt': (value.updatedAt.toISOString()),
58
- 'usedAt': (value.usedAt === null ? null : value.usedAt.toISOString()),
59
- };
60
- }
61
- exports.FreeCarriageCouponToJSON = FreeCarriageCouponToJSON;