@lcdp/api-react-rest-client 2.6.2-develop.8356314138 → 2.6.2
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/order/src/models/OrderJournal.d.ts +0 -24
- package/order/src/models/OrderJournal.js +0 -8
- package/package.json +1 -1
- package/sale-offer/src/models/SaleOffer.d.ts +17 -17
- package/sale-offer/src/models/SaleOffer.js +19 -18
- package/statistic/src/apis/index.d.ts +0 -1
- package/statistic/src/apis/index.js +0 -1
- package/statistic/src/models/index.d.ts +0 -3
- package/statistic/src/models/index.js +0 -3
- package/user/src/models/User.d.ts +8 -21
- package/user/src/models/User.js +8 -13
- package/user/src/models/index.d.ts +0 -2
- package/user/src/models/index.js +0 -2
- package/statistic/src/apis/SearchUserStatisticsApi.d.ts +0 -42
- package/statistic/src/apis/SearchUserStatisticsApi.js +0 -248
- package/statistic/src/models/PaginatedUserStatistics.d.ts +0 -29
- package/statistic/src/models/PaginatedUserStatistics.js +0 -50
- package/statistic/src/models/PaginatedUserStatisticsAllOf.d.ts +0 -28
- package/statistic/src/models/PaginatedUserStatisticsAllOf.js +0 -42
- package/statistic/src/models/UserStatistic.d.ts +0 -70
- package/statistic/src/models/UserStatistic.js +0 -57
- package/third-party/index.d.ts +0 -1
- package/third-party/index.js +0 -17
- package/third-party/src/apis/ManageThirdPartyLinkApi.d.ts +0 -29
- package/third-party/src/apis/ManageThirdPartyLinkApi.js +0 -163
- package/third-party/src/apis/index.d.ts +0 -1
- package/third-party/src/apis/index.js +0 -17
- package/third-party/src/index.d.ts +0 -3
- package/third-party/src/index.js +0 -19
- package/third-party/src/models/RestError.d.ts +0 -87
- package/third-party/src/models/RestError.js +0 -99
- package/third-party/src/models/ThirdPartyLink.d.ts +0 -27
- package/third-party/src/models/ThirdPartyLink.js +0 -42
- package/third-party/src/models/ThirdPartyLinkCreationParameters.d.ts +0 -33
- package/third-party/src/models/ThirdPartyLinkCreationParameters.js +0 -43
- package/third-party/src/models/index.d.ts +0 -3
- package/third-party/src/models/index.js +0 -19
- package/third-party/src/runtime.d.ts +0 -149
- package/third-party/src/runtime.js +0 -480
- package/user/src/models/UserStatisticLink.d.ts +0 -58
- package/user/src/models/UserStatisticLink.js +0 -50
- package/user/src/models/UserStatisticLinkAllOf.d.ts +0 -57
- package/user/src/models/UserStatisticLinkAllOf.js +0 -52
|
@@ -1,149 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* lcdp-monolith-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
|
-
export declare const BASE_PATH = "/api/v1";
|
|
13
|
-
/**
|
|
14
|
-
* This is the base class for all generated API classes.
|
|
15
|
-
*/
|
|
16
|
-
export declare class BaseAPI {
|
|
17
|
-
protected configuration: Configuration;
|
|
18
|
-
private middleware;
|
|
19
|
-
constructor(configuration?: Configuration);
|
|
20
|
-
withMiddleware<T extends BaseAPI>(this: T, ...middlewares: Middleware[]): T;
|
|
21
|
-
withPreMiddleware<T extends BaseAPI>(this: T, ...preMiddlewares: Array<Middleware['pre']>): T;
|
|
22
|
-
withPostMiddleware<T extends BaseAPI>(this: T, ...postMiddlewares: Array<Middleware['post']>): T;
|
|
23
|
-
protected request(context: RequestOpts): Promise<Response>;
|
|
24
|
-
private createFetchParams;
|
|
25
|
-
private fetchApi;
|
|
26
|
-
/**
|
|
27
|
-
* Create a shallow clone of `this` by constructing a new instance
|
|
28
|
-
* and then shallow cloning data members.
|
|
29
|
-
*/
|
|
30
|
-
private clone;
|
|
31
|
-
}
|
|
32
|
-
export declare class RequiredError extends Error {
|
|
33
|
-
field: string;
|
|
34
|
-
name: "RequiredError";
|
|
35
|
-
constructor(field: string, msg?: string);
|
|
36
|
-
}
|
|
37
|
-
export declare const COLLECTION_FORMATS: {
|
|
38
|
-
csv: string;
|
|
39
|
-
ssv: string;
|
|
40
|
-
tsv: string;
|
|
41
|
-
pipes: string;
|
|
42
|
-
};
|
|
43
|
-
export declare type FetchAPI = WindowOrWorkerGlobalScope['fetch'];
|
|
44
|
-
export interface ConfigurationParameters {
|
|
45
|
-
basePath?: string;
|
|
46
|
-
fetchApi?: FetchAPI;
|
|
47
|
-
middleware?: Middleware[];
|
|
48
|
-
queryParamsStringify?: (params: HTTPQuery) => string;
|
|
49
|
-
username?: string;
|
|
50
|
-
password?: string;
|
|
51
|
-
apiKey?: string | ((name: string) => string);
|
|
52
|
-
accessToken?: string | ((name?: string, scopes?: string[]) => Promise<string>);
|
|
53
|
-
headers?: HTTPHeaders;
|
|
54
|
-
credentials?: RequestCredentials;
|
|
55
|
-
referrerPolicy?: ReferrerPolicy;
|
|
56
|
-
}
|
|
57
|
-
export declare class Configuration {
|
|
58
|
-
private configuration;
|
|
59
|
-
constructor(configuration?: ConfigurationParameters);
|
|
60
|
-
get basePath(): string;
|
|
61
|
-
get fetchApi(): FetchAPI;
|
|
62
|
-
get middleware(): Middleware[];
|
|
63
|
-
get queryParamsStringify(): (params: HTTPQuery) => string;
|
|
64
|
-
get username(): string | undefined;
|
|
65
|
-
get password(): string | undefined;
|
|
66
|
-
get apiKey(): ((name: string) => string) | undefined;
|
|
67
|
-
get accessToken(): ((name: string, scopes?: string[]) => Promise<string>) | undefined;
|
|
68
|
-
get headers(): HTTPHeaders | undefined;
|
|
69
|
-
get credentials(): RequestCredentials | undefined;
|
|
70
|
-
get referrerPolicy(): ReferrerPolicy | undefined;
|
|
71
|
-
}
|
|
72
|
-
export declare type Json = any;
|
|
73
|
-
export declare type HTTPMethod = 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE' | 'OPTIONS' | 'HEAD';
|
|
74
|
-
export declare type HTTPHeaders = {
|
|
75
|
-
[key: string]: string;
|
|
76
|
-
};
|
|
77
|
-
export declare type HTTPQuery = {
|
|
78
|
-
[key: string]: string | number | null | boolean | Array<string | number | null | boolean> | HTTPQuery;
|
|
79
|
-
};
|
|
80
|
-
export declare type HTTPBody = Json | FormData | URLSearchParams;
|
|
81
|
-
export declare type ModelPropertyNaming = 'camelCase' | 'snake_case' | 'PascalCase' | 'original';
|
|
82
|
-
export interface FetchParams {
|
|
83
|
-
url: string;
|
|
84
|
-
init: RequestInit;
|
|
85
|
-
}
|
|
86
|
-
export interface RequestOpts {
|
|
87
|
-
path: string;
|
|
88
|
-
method: HTTPMethod;
|
|
89
|
-
headers: HTTPHeaders;
|
|
90
|
-
query?: HTTPQuery;
|
|
91
|
-
body?: HTTPBody;
|
|
92
|
-
}
|
|
93
|
-
export declare function exists(json: any, key: string): boolean;
|
|
94
|
-
export declare function querystring(params: HTTPQuery, prefix?: string): string;
|
|
95
|
-
export declare function mapValues(data: any, fn: (item: any) => any): {};
|
|
96
|
-
export declare function canConsumeForm(consumes: Consume[]): boolean;
|
|
97
|
-
export declare function toDateISOString(date: Date): string;
|
|
98
|
-
export interface Consume {
|
|
99
|
-
contentType: string;
|
|
100
|
-
}
|
|
101
|
-
export interface RequestContext {
|
|
102
|
-
fetch: FetchAPI;
|
|
103
|
-
url: string;
|
|
104
|
-
init: RequestInit;
|
|
105
|
-
}
|
|
106
|
-
export interface ResponseContext {
|
|
107
|
-
fetch: FetchAPI;
|
|
108
|
-
url: string;
|
|
109
|
-
init: RequestInit;
|
|
110
|
-
response: Response;
|
|
111
|
-
}
|
|
112
|
-
export interface Middleware {
|
|
113
|
-
pre?(context: RequestContext): Promise<FetchParams | void>;
|
|
114
|
-
post?(context: ResponseContext): Promise<Response | void>;
|
|
115
|
-
}
|
|
116
|
-
export interface ApiResponse<T> {
|
|
117
|
-
raw: Response;
|
|
118
|
-
value(): Promise<T>;
|
|
119
|
-
}
|
|
120
|
-
export interface ResponseTransformer<T> {
|
|
121
|
-
(json: any): T;
|
|
122
|
-
}
|
|
123
|
-
export declare class JSONApiResponse<T> {
|
|
124
|
-
raw: Response;
|
|
125
|
-
private transformer;
|
|
126
|
-
constructor(raw: Response, transformer?: ResponseTransformer<T>);
|
|
127
|
-
value(): Promise<T>;
|
|
128
|
-
}
|
|
129
|
-
export declare class VoidApiResponse {
|
|
130
|
-
raw: Response;
|
|
131
|
-
constructor(raw: Response);
|
|
132
|
-
value(): Promise<void>;
|
|
133
|
-
}
|
|
134
|
-
export interface BlobWithMeta {
|
|
135
|
-
blob: Blob;
|
|
136
|
-
filename: string;
|
|
137
|
-
}
|
|
138
|
-
export declare function instanceOfBlobWithMeta(object: any): object is BlobWithMeta;
|
|
139
|
-
export declare class BlobWithMetaApiResponse {
|
|
140
|
-
raw: Response;
|
|
141
|
-
constructor(raw: Response);
|
|
142
|
-
value(): Promise<BlobWithMeta>;
|
|
143
|
-
private extractFilename;
|
|
144
|
-
}
|
|
145
|
-
export declare class TextApiResponse {
|
|
146
|
-
raw: Response;
|
|
147
|
-
constructor(raw: Response);
|
|
148
|
-
value(): Promise<string>;
|
|
149
|
-
}
|
|
@@ -1,480 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/* tslint:disable */
|
|
3
|
-
/* eslint-disable */
|
|
4
|
-
/**
|
|
5
|
-
* lcdp-monolith-service
|
|
6
|
-
* This is the REST API of LCDP products
|
|
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 __assign = (this && this.__assign) || function () {
|
|
31
|
-
__assign = Object.assign || function(t) {
|
|
32
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
33
|
-
s = arguments[i];
|
|
34
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
35
|
-
t[p] = s[p];
|
|
36
|
-
}
|
|
37
|
-
return t;
|
|
38
|
-
};
|
|
39
|
-
return __assign.apply(this, arguments);
|
|
40
|
-
};
|
|
41
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
42
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
43
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
44
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
45
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
46
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
47
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
48
|
-
});
|
|
49
|
-
};
|
|
50
|
-
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
51
|
-
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
52
|
-
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
53
|
-
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
54
|
-
function step(op) {
|
|
55
|
-
if (f) throw new TypeError("Generator is already executing.");
|
|
56
|
-
while (_) try {
|
|
57
|
-
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;
|
|
58
|
-
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
59
|
-
switch (op[0]) {
|
|
60
|
-
case 0: case 1: t = op; break;
|
|
61
|
-
case 4: _.label++; return { value: op[1], done: false };
|
|
62
|
-
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
63
|
-
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
64
|
-
default:
|
|
65
|
-
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
66
|
-
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
67
|
-
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
68
|
-
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
69
|
-
if (t[2]) _.ops.pop();
|
|
70
|
-
_.trys.pop(); continue;
|
|
71
|
-
}
|
|
72
|
-
op = body.call(thisArg, _);
|
|
73
|
-
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
74
|
-
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
75
|
-
}
|
|
76
|
-
};
|
|
77
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
78
|
-
exports.TextApiResponse = exports.BlobWithMetaApiResponse = exports.instanceOfBlobWithMeta = exports.VoidApiResponse = exports.JSONApiResponse = exports.toDateISOString = exports.canConsumeForm = exports.mapValues = exports.querystring = exports.exists = exports.Configuration = exports.COLLECTION_FORMATS = exports.RequiredError = exports.BaseAPI = exports.BASE_PATH = void 0;
|
|
79
|
-
exports.BASE_PATH = "/api/v1";
|
|
80
|
-
var isBlob = function (value) { return typeof Blob !== 'undefined' && value instanceof Blob; };
|
|
81
|
-
/**
|
|
82
|
-
* This is the base class for all generated API classes.
|
|
83
|
-
*/
|
|
84
|
-
var BaseAPI = /** @class */ (function () {
|
|
85
|
-
function BaseAPI(configuration) {
|
|
86
|
-
if (configuration === void 0) { configuration = new Configuration(); }
|
|
87
|
-
var _this = this;
|
|
88
|
-
this.configuration = configuration;
|
|
89
|
-
this.fetchApi = function (url, init) { return __awaiter(_this, void 0, void 0, function () {
|
|
90
|
-
var fetchParams, _i, _a, middleware, response, _b, _c, middleware;
|
|
91
|
-
return __generator(this, function (_d) {
|
|
92
|
-
switch (_d.label) {
|
|
93
|
-
case 0:
|
|
94
|
-
fetchParams = { url: url, init: init };
|
|
95
|
-
_i = 0, _a = this.middleware;
|
|
96
|
-
_d.label = 1;
|
|
97
|
-
case 1:
|
|
98
|
-
if (!(_i < _a.length)) return [3 /*break*/, 4];
|
|
99
|
-
middleware = _a[_i];
|
|
100
|
-
if (!middleware.pre) return [3 /*break*/, 3];
|
|
101
|
-
return [4 /*yield*/, middleware.pre(__assign({ fetch: this.fetchApi }, fetchParams))];
|
|
102
|
-
case 2:
|
|
103
|
-
fetchParams = (_d.sent()) || fetchParams;
|
|
104
|
-
_d.label = 3;
|
|
105
|
-
case 3:
|
|
106
|
-
_i++;
|
|
107
|
-
return [3 /*break*/, 1];
|
|
108
|
-
case 4: return [4 /*yield*/, this.configuration.fetchApi(fetchParams.url, fetchParams.init)];
|
|
109
|
-
case 5:
|
|
110
|
-
response = _d.sent();
|
|
111
|
-
_b = 0, _c = this.middleware;
|
|
112
|
-
_d.label = 6;
|
|
113
|
-
case 6:
|
|
114
|
-
if (!(_b < _c.length)) return [3 /*break*/, 9];
|
|
115
|
-
middleware = _c[_b];
|
|
116
|
-
if (!middleware.post) return [3 /*break*/, 8];
|
|
117
|
-
return [4 /*yield*/, middleware.post({
|
|
118
|
-
fetch: this.fetchApi,
|
|
119
|
-
url: url,
|
|
120
|
-
init: init,
|
|
121
|
-
response: response.clone(),
|
|
122
|
-
})];
|
|
123
|
-
case 7:
|
|
124
|
-
response = (_d.sent()) || response;
|
|
125
|
-
_d.label = 8;
|
|
126
|
-
case 8:
|
|
127
|
-
_b++;
|
|
128
|
-
return [3 /*break*/, 6];
|
|
129
|
-
case 9: return [2 /*return*/, response];
|
|
130
|
-
}
|
|
131
|
-
});
|
|
132
|
-
}); };
|
|
133
|
-
this.middleware = configuration.middleware;
|
|
134
|
-
}
|
|
135
|
-
BaseAPI.prototype.withMiddleware = function () {
|
|
136
|
-
var _a;
|
|
137
|
-
var middlewares = [];
|
|
138
|
-
for (var _i = 0; _i < arguments.length; _i++) {
|
|
139
|
-
middlewares[_i] = arguments[_i];
|
|
140
|
-
}
|
|
141
|
-
var next = this.clone();
|
|
142
|
-
next.middleware = (_a = next.middleware).concat.apply(_a, middlewares);
|
|
143
|
-
return next;
|
|
144
|
-
};
|
|
145
|
-
BaseAPI.prototype.withPreMiddleware = function () {
|
|
146
|
-
var preMiddlewares = [];
|
|
147
|
-
for (var _i = 0; _i < arguments.length; _i++) {
|
|
148
|
-
preMiddlewares[_i] = arguments[_i];
|
|
149
|
-
}
|
|
150
|
-
var middlewares = preMiddlewares.map(function (pre) { return ({ pre: pre }); });
|
|
151
|
-
return this.withMiddleware.apply(this, middlewares);
|
|
152
|
-
};
|
|
153
|
-
BaseAPI.prototype.withPostMiddleware = function () {
|
|
154
|
-
var postMiddlewares = [];
|
|
155
|
-
for (var _i = 0; _i < arguments.length; _i++) {
|
|
156
|
-
postMiddlewares[_i] = arguments[_i];
|
|
157
|
-
}
|
|
158
|
-
var middlewares = postMiddlewares.map(function (post) { return ({ post: post }); });
|
|
159
|
-
return this.withMiddleware.apply(this, middlewares);
|
|
160
|
-
};
|
|
161
|
-
BaseAPI.prototype.request = function (context) {
|
|
162
|
-
return __awaiter(this, void 0, void 0, function () {
|
|
163
|
-
var _a, url, init, response;
|
|
164
|
-
return __generator(this, function (_b) {
|
|
165
|
-
switch (_b.label) {
|
|
166
|
-
case 0:
|
|
167
|
-
_a = this.createFetchParams(context), url = _a.url, init = _a.init;
|
|
168
|
-
return [4 /*yield*/, this.fetchApi(url, init)];
|
|
169
|
-
case 1:
|
|
170
|
-
response = _b.sent();
|
|
171
|
-
if (response.status >= 200 && response.status < 300) {
|
|
172
|
-
return [2 /*return*/, response];
|
|
173
|
-
}
|
|
174
|
-
throw response;
|
|
175
|
-
}
|
|
176
|
-
});
|
|
177
|
-
});
|
|
178
|
-
};
|
|
179
|
-
BaseAPI.prototype.createFetchParams = function (context) {
|
|
180
|
-
var url = this.configuration.basePath + context.path;
|
|
181
|
-
if (context.query !== undefined && Object.keys(context.query).length !== 0) {
|
|
182
|
-
// only add the querystring to the URL if there are query parameters.
|
|
183
|
-
// this is done to avoid urls ending with a "?" character which buggy webservers
|
|
184
|
-
// do not handle correctly sometimes.
|
|
185
|
-
url += '?' + this.configuration.queryParamsStringify(context.query);
|
|
186
|
-
}
|
|
187
|
-
var body = (context.body instanceof FormData || context.body instanceof URLSearchParams || isBlob(context.body))
|
|
188
|
-
? context.body
|
|
189
|
-
: JSON.stringify(context.body);
|
|
190
|
-
var headers = Object.assign({}, this.configuration.headers, context.headers);
|
|
191
|
-
Object.keys(headers).forEach(function (key) { return headers[key] === undefined ? delete headers[key] : {}; });
|
|
192
|
-
var init = {
|
|
193
|
-
method: context.method,
|
|
194
|
-
headers: headers,
|
|
195
|
-
body: body,
|
|
196
|
-
credentials: this.configuration.credentials,
|
|
197
|
-
referrerPolicy: this.configuration.referrerPolicy,
|
|
198
|
-
};
|
|
199
|
-
return { url: url, init: init };
|
|
200
|
-
};
|
|
201
|
-
/**
|
|
202
|
-
* Create a shallow clone of `this` by constructing a new instance
|
|
203
|
-
* and then shallow cloning data members.
|
|
204
|
-
*/
|
|
205
|
-
BaseAPI.prototype.clone = function () {
|
|
206
|
-
var constructor = this.constructor;
|
|
207
|
-
var next = new constructor(this.configuration);
|
|
208
|
-
next.middleware = this.middleware.slice();
|
|
209
|
-
return next;
|
|
210
|
-
};
|
|
211
|
-
return BaseAPI;
|
|
212
|
-
}());
|
|
213
|
-
exports.BaseAPI = BaseAPI;
|
|
214
|
-
;
|
|
215
|
-
var RequiredError = /** @class */ (function (_super) {
|
|
216
|
-
__extends(RequiredError, _super);
|
|
217
|
-
function RequiredError(field, msg) {
|
|
218
|
-
var _this = _super.call(this, msg) || this;
|
|
219
|
-
_this.field = field;
|
|
220
|
-
_this.name = "RequiredError";
|
|
221
|
-
return _this;
|
|
222
|
-
}
|
|
223
|
-
return RequiredError;
|
|
224
|
-
}(Error));
|
|
225
|
-
exports.RequiredError = RequiredError;
|
|
226
|
-
exports.COLLECTION_FORMATS = {
|
|
227
|
-
csv: ",",
|
|
228
|
-
ssv: " ",
|
|
229
|
-
tsv: "\t",
|
|
230
|
-
pipes: "|",
|
|
231
|
-
};
|
|
232
|
-
var Configuration = /** @class */ (function () {
|
|
233
|
-
function Configuration(configuration) {
|
|
234
|
-
if (configuration === void 0) { configuration = {}; }
|
|
235
|
-
this.configuration = configuration;
|
|
236
|
-
}
|
|
237
|
-
Object.defineProperty(Configuration.prototype, "basePath", {
|
|
238
|
-
get: function () {
|
|
239
|
-
return this.configuration.basePath != null ? this.configuration.basePath : exports.BASE_PATH;
|
|
240
|
-
},
|
|
241
|
-
enumerable: false,
|
|
242
|
-
configurable: true
|
|
243
|
-
});
|
|
244
|
-
Object.defineProperty(Configuration.prototype, "fetchApi", {
|
|
245
|
-
get: function () {
|
|
246
|
-
return this.configuration.fetchApi || window.fetch.bind(window);
|
|
247
|
-
},
|
|
248
|
-
enumerable: false,
|
|
249
|
-
configurable: true
|
|
250
|
-
});
|
|
251
|
-
Object.defineProperty(Configuration.prototype, "middleware", {
|
|
252
|
-
get: function () {
|
|
253
|
-
return this.configuration.middleware || [];
|
|
254
|
-
},
|
|
255
|
-
enumerable: false,
|
|
256
|
-
configurable: true
|
|
257
|
-
});
|
|
258
|
-
Object.defineProperty(Configuration.prototype, "queryParamsStringify", {
|
|
259
|
-
get: function () {
|
|
260
|
-
return this.configuration.queryParamsStringify || querystring;
|
|
261
|
-
},
|
|
262
|
-
enumerable: false,
|
|
263
|
-
configurable: true
|
|
264
|
-
});
|
|
265
|
-
Object.defineProperty(Configuration.prototype, "username", {
|
|
266
|
-
get: function () {
|
|
267
|
-
return this.configuration.username;
|
|
268
|
-
},
|
|
269
|
-
enumerable: false,
|
|
270
|
-
configurable: true
|
|
271
|
-
});
|
|
272
|
-
Object.defineProperty(Configuration.prototype, "password", {
|
|
273
|
-
get: function () {
|
|
274
|
-
return this.configuration.password;
|
|
275
|
-
},
|
|
276
|
-
enumerable: false,
|
|
277
|
-
configurable: true
|
|
278
|
-
});
|
|
279
|
-
Object.defineProperty(Configuration.prototype, "apiKey", {
|
|
280
|
-
get: function () {
|
|
281
|
-
var apiKey = this.configuration.apiKey;
|
|
282
|
-
if (apiKey) {
|
|
283
|
-
return typeof apiKey === 'function' ? apiKey : function () { return apiKey; };
|
|
284
|
-
}
|
|
285
|
-
return undefined;
|
|
286
|
-
},
|
|
287
|
-
enumerable: false,
|
|
288
|
-
configurable: true
|
|
289
|
-
});
|
|
290
|
-
Object.defineProperty(Configuration.prototype, "accessToken", {
|
|
291
|
-
get: function () {
|
|
292
|
-
var accessToken = this.configuration.accessToken;
|
|
293
|
-
if (accessToken) {
|
|
294
|
-
return typeof accessToken === 'function' ? accessToken : function () { return Promise.resolve(accessToken); };
|
|
295
|
-
}
|
|
296
|
-
return undefined;
|
|
297
|
-
},
|
|
298
|
-
enumerable: false,
|
|
299
|
-
configurable: true
|
|
300
|
-
});
|
|
301
|
-
Object.defineProperty(Configuration.prototype, "headers", {
|
|
302
|
-
get: function () {
|
|
303
|
-
return this.configuration.headers;
|
|
304
|
-
},
|
|
305
|
-
enumerable: false,
|
|
306
|
-
configurable: true
|
|
307
|
-
});
|
|
308
|
-
Object.defineProperty(Configuration.prototype, "credentials", {
|
|
309
|
-
get: function () {
|
|
310
|
-
var _a;
|
|
311
|
-
return (_a = this.configuration.credentials) !== null && _a !== void 0 ? _a : "omit";
|
|
312
|
-
},
|
|
313
|
-
enumerable: false,
|
|
314
|
-
configurable: true
|
|
315
|
-
});
|
|
316
|
-
Object.defineProperty(Configuration.prototype, "referrerPolicy", {
|
|
317
|
-
get: function () {
|
|
318
|
-
var _a;
|
|
319
|
-
return (_a = this.configuration.referrerPolicy) !== null && _a !== void 0 ? _a : "origin";
|
|
320
|
-
},
|
|
321
|
-
enumerable: false,
|
|
322
|
-
configurable: true
|
|
323
|
-
});
|
|
324
|
-
return Configuration;
|
|
325
|
-
}());
|
|
326
|
-
exports.Configuration = Configuration;
|
|
327
|
-
function exists(json, key) {
|
|
328
|
-
var value = json[key];
|
|
329
|
-
return value !== null && value !== undefined;
|
|
330
|
-
}
|
|
331
|
-
exports.exists = exists;
|
|
332
|
-
function querystring(params, prefix) {
|
|
333
|
-
if (prefix === void 0) { prefix = ''; }
|
|
334
|
-
return Object.keys(params)
|
|
335
|
-
.map(function (key) {
|
|
336
|
-
var fullKey = prefix + (prefix.length ? "[".concat(key, "]") : key);
|
|
337
|
-
var value = params[key];
|
|
338
|
-
if (value instanceof Array) {
|
|
339
|
-
var multiValue = value.map(function (singleValue) { return encodeURIComponent(String(singleValue)); })
|
|
340
|
-
.join("&".concat(encodeURIComponent(fullKey), "="));
|
|
341
|
-
return "".concat(encodeURIComponent(fullKey), "=").concat(multiValue);
|
|
342
|
-
}
|
|
343
|
-
if (value instanceof Object) {
|
|
344
|
-
return querystring(value, fullKey);
|
|
345
|
-
}
|
|
346
|
-
return "".concat(encodeURIComponent(fullKey), "=").concat(encodeURIComponent(String(value)));
|
|
347
|
-
})
|
|
348
|
-
.filter(function (part) { return part.length > 0; })
|
|
349
|
-
.join('&');
|
|
350
|
-
}
|
|
351
|
-
exports.querystring = querystring;
|
|
352
|
-
function mapValues(data, fn) {
|
|
353
|
-
return Object.keys(data).reduce(function (acc, key) {
|
|
354
|
-
var _a;
|
|
355
|
-
return (__assign(__assign({}, acc), (_a = {}, _a[key] = fn(data[key]), _a)));
|
|
356
|
-
}, {});
|
|
357
|
-
}
|
|
358
|
-
exports.mapValues = mapValues;
|
|
359
|
-
function canConsumeForm(consumes) {
|
|
360
|
-
for (var _i = 0, consumes_1 = consumes; _i < consumes_1.length; _i++) {
|
|
361
|
-
var consume = consumes_1[_i];
|
|
362
|
-
if ('multipart/form-data' === consume.contentType) {
|
|
363
|
-
return true;
|
|
364
|
-
}
|
|
365
|
-
}
|
|
366
|
-
return false;
|
|
367
|
-
}
|
|
368
|
-
exports.canConsumeForm = canConsumeForm;
|
|
369
|
-
function toDateISOString(date) {
|
|
370
|
-
if (date === undefined) {
|
|
371
|
-
return undefined;
|
|
372
|
-
}
|
|
373
|
-
if (date === null) {
|
|
374
|
-
return null;
|
|
375
|
-
}
|
|
376
|
-
return date.toLocaleDateString('ja-JP', {
|
|
377
|
-
year: 'numeric',
|
|
378
|
-
month: '2-digit',
|
|
379
|
-
day: '2-digit'
|
|
380
|
-
}).replace(/\//gi, '-');
|
|
381
|
-
}
|
|
382
|
-
exports.toDateISOString = toDateISOString;
|
|
383
|
-
var JSONApiResponse = /** @class */ (function () {
|
|
384
|
-
function JSONApiResponse(raw, transformer) {
|
|
385
|
-
if (transformer === void 0) { transformer = function (jsonValue) { return jsonValue; }; }
|
|
386
|
-
this.raw = raw;
|
|
387
|
-
this.transformer = transformer;
|
|
388
|
-
}
|
|
389
|
-
JSONApiResponse.prototype.value = function () {
|
|
390
|
-
return __awaiter(this, void 0, void 0, function () {
|
|
391
|
-
var _a;
|
|
392
|
-
return __generator(this, function (_b) {
|
|
393
|
-
switch (_b.label) {
|
|
394
|
-
case 0:
|
|
395
|
-
_a = this.transformer;
|
|
396
|
-
return [4 /*yield*/, this.raw.json()];
|
|
397
|
-
case 1: return [2 /*return*/, _a.apply(this, [_b.sent()])];
|
|
398
|
-
}
|
|
399
|
-
});
|
|
400
|
-
});
|
|
401
|
-
};
|
|
402
|
-
return JSONApiResponse;
|
|
403
|
-
}());
|
|
404
|
-
exports.JSONApiResponse = JSONApiResponse;
|
|
405
|
-
var VoidApiResponse = /** @class */ (function () {
|
|
406
|
-
function VoidApiResponse(raw) {
|
|
407
|
-
this.raw = raw;
|
|
408
|
-
}
|
|
409
|
-
VoidApiResponse.prototype.value = function () {
|
|
410
|
-
return __awaiter(this, void 0, void 0, function () {
|
|
411
|
-
return __generator(this, function (_a) {
|
|
412
|
-
return [2 /*return*/, undefined];
|
|
413
|
-
});
|
|
414
|
-
});
|
|
415
|
-
};
|
|
416
|
-
return VoidApiResponse;
|
|
417
|
-
}());
|
|
418
|
-
exports.VoidApiResponse = VoidApiResponse;
|
|
419
|
-
function instanceOfBlobWithMeta(object) {
|
|
420
|
-
return 'filename' in object && 'blob' in object;
|
|
421
|
-
}
|
|
422
|
-
exports.instanceOfBlobWithMeta = instanceOfBlobWithMeta;
|
|
423
|
-
var BlobWithMetaApiResponse = /** @class */ (function () {
|
|
424
|
-
function BlobWithMetaApiResponse(raw) {
|
|
425
|
-
this.raw = raw;
|
|
426
|
-
}
|
|
427
|
-
BlobWithMetaApiResponse.prototype.value = function () {
|
|
428
|
-
return __awaiter(this, void 0, void 0, function () {
|
|
429
|
-
var _a;
|
|
430
|
-
return __generator(this, function (_b) {
|
|
431
|
-
switch (_b.label) {
|
|
432
|
-
case 0:
|
|
433
|
-
_a = {};
|
|
434
|
-
return [4 /*yield*/, this.raw.blob()];
|
|
435
|
-
case 1: return [2 /*return*/, (_a.blob = _b.sent(),
|
|
436
|
-
_a.filename = this.extractFilename(this.raw.headers),
|
|
437
|
-
_a)];
|
|
438
|
-
}
|
|
439
|
-
});
|
|
440
|
-
});
|
|
441
|
-
};
|
|
442
|
-
;
|
|
443
|
-
BlobWithMetaApiResponse.prototype.extractFilename = function (headers) {
|
|
444
|
-
var headerName = 'Content-Disposition';
|
|
445
|
-
if (headers.has(headerName)) {
|
|
446
|
-
var headerValue = headers.get(headerName);
|
|
447
|
-
var filenameRegex = /filename\*?=['"]?(?:UTF-\d['"]*)?([^;\r\n"']*)['"]?;?/;
|
|
448
|
-
var matches = filenameRegex.exec(headerValue);
|
|
449
|
-
if (matches != null && matches[1]) {
|
|
450
|
-
return matches[1];
|
|
451
|
-
}
|
|
452
|
-
else {
|
|
453
|
-
return undefined;
|
|
454
|
-
}
|
|
455
|
-
}
|
|
456
|
-
else {
|
|
457
|
-
return undefined;
|
|
458
|
-
}
|
|
459
|
-
};
|
|
460
|
-
return BlobWithMetaApiResponse;
|
|
461
|
-
}());
|
|
462
|
-
exports.BlobWithMetaApiResponse = BlobWithMetaApiResponse;
|
|
463
|
-
var TextApiResponse = /** @class */ (function () {
|
|
464
|
-
function TextApiResponse(raw) {
|
|
465
|
-
this.raw = raw;
|
|
466
|
-
}
|
|
467
|
-
TextApiResponse.prototype.value = function () {
|
|
468
|
-
return __awaiter(this, void 0, void 0, function () {
|
|
469
|
-
return __generator(this, function (_a) {
|
|
470
|
-
switch (_a.label) {
|
|
471
|
-
case 0: return [4 /*yield*/, this.raw.text()];
|
|
472
|
-
case 1: return [2 /*return*/, _a.sent()];
|
|
473
|
-
}
|
|
474
|
-
});
|
|
475
|
-
});
|
|
476
|
-
};
|
|
477
|
-
;
|
|
478
|
-
return TextApiResponse;
|
|
479
|
-
}());
|
|
480
|
-
exports.TextApiResponse = TextApiResponse;
|
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* lcdp-monolith-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 { HttpLink } from './HttpLink';
|
|
13
|
-
/**
|
|
14
|
-
*
|
|
15
|
-
* @export
|
|
16
|
-
* @interface UserStatisticLink
|
|
17
|
-
*/
|
|
18
|
-
export interface UserStatisticLink extends HttpLink {
|
|
19
|
-
/**
|
|
20
|
-
* Number of sales
|
|
21
|
-
* @type {number}
|
|
22
|
-
* @memberof UserStatisticLink
|
|
23
|
-
*/
|
|
24
|
-
numberOfSales?: number;
|
|
25
|
-
/**
|
|
26
|
-
* Rate of sales that have at least one removed or refunded item
|
|
27
|
-
* @type {number}
|
|
28
|
-
* @memberof UserStatisticLink
|
|
29
|
-
*/
|
|
30
|
-
salesErrorRate?: number;
|
|
31
|
-
/**
|
|
32
|
-
* Rate of sales that have been canceled, ignoring cancellation issued by the buyer without any reason
|
|
33
|
-
* @type {number}
|
|
34
|
-
* @memberof UserStatisticLink
|
|
35
|
-
*/
|
|
36
|
-
salesCanceledRate?: number;
|
|
37
|
-
/**
|
|
38
|
-
* Rate of sales that are associated to a litigation
|
|
39
|
-
* @type {number}
|
|
40
|
-
* @memberof UserStatisticLink
|
|
41
|
-
*/
|
|
42
|
-
salesLitigationRate?: number;
|
|
43
|
-
/**
|
|
44
|
-
* Average delay of responsiveness for sales (delay between order created by buyer and accepted/modified/canceled by seller or administrator)
|
|
45
|
-
* @type {number}
|
|
46
|
-
* @memberof UserStatisticLink
|
|
47
|
-
*/
|
|
48
|
-
salesResponsivenessDelay?: number;
|
|
49
|
-
/**
|
|
50
|
-
* Average delay of delivery for sales
|
|
51
|
-
* @type {number}
|
|
52
|
-
* @memberof UserStatisticLink
|
|
53
|
-
*/
|
|
54
|
-
deliveryDelay?: number;
|
|
55
|
-
}
|
|
56
|
-
export declare function UserStatisticLinkFromJSON(json: any): UserStatisticLink;
|
|
57
|
-
export declare function UserStatisticLinkFromJSONTyped(json: any, ignoreDiscriminator: boolean): UserStatisticLink;
|
|
58
|
-
export declare function UserStatisticLinkToJSON(value?: UserStatisticLink | null): any;
|