mp-front-cli 0.0.125 → 0.0.127
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/dist/core/errors/enrollment/error-catalog-enrollment.d.ts.map +1 -1
- package/dist/{index-0cc7a8bb.js → index-935aeed1.js} +35 -3
- package/dist/lang/common/errors/enrollment/es_MX/index.d.ts +33 -1
- package/dist/lang/common/errors/enrollment/es_MX/index.d.ts.map +1 -1
- package/dist/lang/common/errors/es_MX/index.d.ts +33 -1
- package/dist/lang/common/errors/es_MX/index.d.ts.map +1 -1
- package/dist/mp-front-cli-all.es.js +1 -1
- package/dist/mp-front-cli-core.es.js +201 -138
- package/dist/mp-front-cli-locale.es.js +1 -1
- package/package.json +2 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"error-catalog-enrollment.d.ts","sourceRoot":"","sources":["../../../../src/core/errors/enrollment/error-catalog-enrollment.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,qBAAqB,CAAA;AAE9C,eAAO,MAAM,sBAAsB,EAAE;IACnC,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,GAAG,QAAQ,CAAA;
|
|
1
|
+
{"version":3,"file":"error-catalog-enrollment.d.ts","sourceRoot":"","sources":["../../../../src/core/errors/enrollment/error-catalog-enrollment.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,qBAAqB,CAAA;AAE9C,eAAO,MAAM,sBAAsB,EAAE;IACnC,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,GAAG,QAAQ,CAAA;CA8UnC,CAAA"}
|
|
@@ -360,9 +360,41 @@ const e = {
|
|
|
360
360
|
title: "Contacta con el equipo de soporte",
|
|
361
361
|
message: "Tu dispositivo no cuenta con las características solicitadas. Por favor intenta con otro dispositivo, ID:ENROLLMENT-NOTALLOWEDBRAND-0044"
|
|
362
362
|
},
|
|
363
|
-
"ENROLLMENT-
|
|
364
|
-
title: "
|
|
365
|
-
message: "No
|
|
363
|
+
"ENROLLMENT-THEREARENTMATERIALS-0055": {
|
|
364
|
+
title: "Contacta con el equipo de soporte",
|
|
365
|
+
message: "No existen materiales para el tipo de crédito seleccionado."
|
|
366
|
+
},
|
|
367
|
+
"ENROLLMENT-THEREARENTMATERIALS-0056": {
|
|
368
|
+
title: "Contacta con el equipo de soporte",
|
|
369
|
+
message: "No existen materiales de el tipo de crédito seleccionado."
|
|
370
|
+
},
|
|
371
|
+
"ENROLLMENT-THEREARENTMATERIALS-0049": {
|
|
372
|
+
title: "Contacta con el equipo de soporte",
|
|
373
|
+
message: "No se encontraron materiales con la descripción especificada."
|
|
374
|
+
},
|
|
375
|
+
"ENROLLMENT-MATERIALNOTFOUND-0052": {
|
|
376
|
+
title: "Contacta con el equipo de soporte",
|
|
377
|
+
message: "No se encontraron materiales con la clave especificada especificada."
|
|
378
|
+
},
|
|
379
|
+
"ENROLLMENT-THEREARENTMATERIALS-0053": {
|
|
380
|
+
title: "Contacta con el equipo de soporte",
|
|
381
|
+
message: "No existen materiales con el color seleccionado."
|
|
382
|
+
},
|
|
383
|
+
"ENROLLMENT-THEREARENTMATERIALS-0054": {
|
|
384
|
+
title: "Contacta con el equipo de soporte",
|
|
385
|
+
message: "No existen materiales con el color seleccionado."
|
|
386
|
+
},
|
|
387
|
+
"ENROLLMENT-THEREARENTMATERIALS-0058": {
|
|
388
|
+
title: "Contacta con el equipo de soporte",
|
|
389
|
+
message: "No existen materiales de la marca seleccionada."
|
|
390
|
+
},
|
|
391
|
+
"ENROLLMENT-THEREARENTMATERIALS-0060": {
|
|
392
|
+
title: "Contacta con el equipo de soporte",
|
|
393
|
+
message: "No existe ningún material con los parámetros especificados."
|
|
394
|
+
},
|
|
395
|
+
"ENROLLMENT-THEREISNTIMEI-0048": {
|
|
396
|
+
title: "Contacta con el equipo de soporte",
|
|
397
|
+
message: "El IMEI / Núm. de serie especificado no existe."
|
|
366
398
|
}
|
|
367
399
|
}
|
|
368
400
|
}, a = {
|
|
@@ -152,7 +152,39 @@ declare const translation: {
|
|
|
152
152
|
title: string;
|
|
153
153
|
message: string;
|
|
154
154
|
};
|
|
155
|
-
"ENROLLMENT-
|
|
155
|
+
"ENROLLMENT-THEREARENTMATERIALS-0055": {
|
|
156
|
+
title: string;
|
|
157
|
+
message: string;
|
|
158
|
+
};
|
|
159
|
+
"ENROLLMENT-THEREARENTMATERIALS-0056": {
|
|
160
|
+
title: string;
|
|
161
|
+
message: string;
|
|
162
|
+
};
|
|
163
|
+
"ENROLLMENT-THEREARENTMATERIALS-0049": {
|
|
164
|
+
title: string;
|
|
165
|
+
message: string;
|
|
166
|
+
};
|
|
167
|
+
"ENROLLMENT-MATERIALNOTFOUND-0052": {
|
|
168
|
+
title: string;
|
|
169
|
+
message: string;
|
|
170
|
+
};
|
|
171
|
+
"ENROLLMENT-THEREARENTMATERIALS-0053": {
|
|
172
|
+
title: string;
|
|
173
|
+
message: string;
|
|
174
|
+
};
|
|
175
|
+
"ENROLLMENT-THEREARENTMATERIALS-0054": {
|
|
176
|
+
title: string;
|
|
177
|
+
message: string;
|
|
178
|
+
};
|
|
179
|
+
"ENROLLMENT-THEREARENTMATERIALS-0058": {
|
|
180
|
+
title: string;
|
|
181
|
+
message: string;
|
|
182
|
+
};
|
|
183
|
+
"ENROLLMENT-THEREARENTMATERIALS-0060": {
|
|
184
|
+
title: string;
|
|
185
|
+
message: string;
|
|
186
|
+
};
|
|
187
|
+
"ENROLLMENT-THEREISNTIMEI-0048": {
|
|
156
188
|
title: string;
|
|
157
189
|
message: string;
|
|
158
190
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/lang/common/errors/enrollment/es_MX/index.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,WAAW
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/lang/common/errors/enrollment/es_MX/index.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAqNhB,CAAA;AAED,eAAe,WAAW,CAAA"}
|
|
@@ -196,7 +196,39 @@ declare const translation: {
|
|
|
196
196
|
title: string;
|
|
197
197
|
message: string;
|
|
198
198
|
};
|
|
199
|
-
"ENROLLMENT-
|
|
199
|
+
"ENROLLMENT-THEREARENTMATERIALS-0055": {
|
|
200
|
+
title: string;
|
|
201
|
+
message: string;
|
|
202
|
+
};
|
|
203
|
+
"ENROLLMENT-THEREARENTMATERIALS-0056": {
|
|
204
|
+
title: string;
|
|
205
|
+
message: string;
|
|
206
|
+
};
|
|
207
|
+
"ENROLLMENT-THEREARENTMATERIALS-0049": {
|
|
208
|
+
title: string;
|
|
209
|
+
message: string;
|
|
210
|
+
};
|
|
211
|
+
"ENROLLMENT-MATERIALNOTFOUND-0052": {
|
|
212
|
+
title: string;
|
|
213
|
+
message: string;
|
|
214
|
+
};
|
|
215
|
+
"ENROLLMENT-THEREARENTMATERIALS-0053": {
|
|
216
|
+
title: string;
|
|
217
|
+
message: string;
|
|
218
|
+
};
|
|
219
|
+
"ENROLLMENT-THEREARENTMATERIALS-0054": {
|
|
220
|
+
title: string;
|
|
221
|
+
message: string;
|
|
222
|
+
};
|
|
223
|
+
"ENROLLMENT-THEREARENTMATERIALS-0058": {
|
|
224
|
+
title: string;
|
|
225
|
+
message: string;
|
|
226
|
+
};
|
|
227
|
+
"ENROLLMENT-THEREARENTMATERIALS-0060": {
|
|
228
|
+
title: string;
|
|
229
|
+
message: string;
|
|
230
|
+
};
|
|
231
|
+
"ENROLLMENT-THEREISNTIMEI-0048": {
|
|
200
232
|
title: string;
|
|
201
233
|
message: string;
|
|
202
234
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/lang/common/errors/es_MX/index.ts"],"names":[],"mappings":"AAIA,QAAA,MAAM,WAAW
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/lang/common/errors/es_MX/index.ts"],"names":[],"mappings":"AAIA,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAwShB,CAAA;AAED,eAAe,WAAW,CAAA"}
|
|
@@ -2,7 +2,7 @@ import { ApiMiddleware as l, ErrorCatalog as x, FetchServiceBE as f, FetchServic
|
|
|
2
2
|
import { LoadingHandler as E, MessageHandler as F, RxSubjectManager as M } from "./mp-front-cli-utils-rxjs.es.js";
|
|
3
3
|
import { S as H } from "./index-def0b487.js";
|
|
4
4
|
import "i18next";
|
|
5
|
-
import "./index-
|
|
5
|
+
import "./index-935aeed1.js";
|
|
6
6
|
import "./mp-front-cli-logger.es.js";
|
|
7
7
|
import "rxjs";
|
|
8
8
|
import "./mp-front-cli-encrypter.es.js";
|
|
@@ -1,29 +1,29 @@
|
|
|
1
1
|
var u = Object.defineProperty;
|
|
2
|
-
var f = (t,
|
|
3
|
-
var O = (t,
|
|
2
|
+
var f = (t, r, e) => r in t ? u(t, r, { enumerable: !0, configurable: !0, writable: !0, value: e }) : t[r] = e;
|
|
3
|
+
var O = (t, r, e) => (f(t, typeof r != "symbol" ? r + "" : r, e), e);
|
|
4
4
|
import { LoadingHandler as g, MessageHandler as M } from "./mp-front-cli-utils-rxjs.es.js";
|
|
5
5
|
import { RxSubjectManager as De } from "./mp-front-cli-utils-rxjs.es.js";
|
|
6
6
|
import { f as c } from "./index-def0b487.js";
|
|
7
7
|
import { S as Pe } from "./index-def0b487.js";
|
|
8
|
-
import
|
|
9
|
-
import { t as
|
|
10
|
-
import { CustomLogger as
|
|
11
|
-
import { of as
|
|
8
|
+
import v, { t as n } from "i18next";
|
|
9
|
+
import { t as w } from "./index-935aeed1.js";
|
|
10
|
+
import { CustomLogger as F } from "./mp-front-cli-logger.es.js";
|
|
11
|
+
import { of as o, switchMap as L, forkJoin as p, catchError as U, EMPTY as P, filter as h } from "rxjs";
|
|
12
12
|
import { CustomEncrypter as V } from "./mp-front-cli-encrypter.es.js";
|
|
13
13
|
import { CustomHeader as Q } from "./mp-front-cli-header.es.js";
|
|
14
|
-
import
|
|
15
|
-
import { CustomEncoder as
|
|
16
|
-
import { u as
|
|
14
|
+
import H from "querystring";
|
|
15
|
+
import { CustomEncoder as x } from "./mp-front-cli-encoder.es.js";
|
|
16
|
+
import { u as G } from "./stringify-788d71a0.js";
|
|
17
17
|
import "node-jose";
|
|
18
18
|
import "crypto";
|
|
19
19
|
const Y = {
|
|
20
20
|
es: {
|
|
21
21
|
translation: {
|
|
22
|
-
...
|
|
22
|
+
...w
|
|
23
23
|
}
|
|
24
24
|
}
|
|
25
25
|
};
|
|
26
|
-
|
|
26
|
+
v.init({
|
|
27
27
|
resources: Y,
|
|
28
28
|
lng: "es",
|
|
29
29
|
// language to use, more information here: https://www.i18next.com/overview/configuration-options#languages-namespaces-resources
|
|
@@ -302,6 +302,69 @@ const K = {
|
|
|
302
302
|
message: "errors.ENROLLMENT-IMEIFOUNDINACTIVEAPPLICATION-0041.message",
|
|
303
303
|
title: "errors.ENROLLMENT-IMEIFOUNDINACTIVEAPPLICATION-0041.title",
|
|
304
304
|
level: "warning"
|
|
305
|
+
},
|
|
306
|
+
"ENROLLMENT-THEREARENTMATERIALS-0055": {
|
|
307
|
+
code: 400,
|
|
308
|
+
type: "modal",
|
|
309
|
+
message: "errors.ENROLLMENT-THEREARENTMATERIALS-0055.message",
|
|
310
|
+
title: "errors.ENROLLMENT-THEREARENTMATERIALS-0055.title",
|
|
311
|
+
level: "warning"
|
|
312
|
+
},
|
|
313
|
+
"ENROLLMENT-THEREARENTMATERIALS-0056": {
|
|
314
|
+
code: 400,
|
|
315
|
+
type: "modal",
|
|
316
|
+
message: "errors.ENROLLMENT-THEREARENTMATERIALS-0056.message",
|
|
317
|
+
title: "errors.ENROLLMENT-THEREARENTMATERIALS-0056.title",
|
|
318
|
+
level: "warning"
|
|
319
|
+
},
|
|
320
|
+
"ENROLLMENT-THEREARENTMATERIALS-0049": {
|
|
321
|
+
code: 400,
|
|
322
|
+
type: "modal",
|
|
323
|
+
message: "errors.ENROLLMENT-THEREARENTMATERIALS-0049.message",
|
|
324
|
+
title: "errors.ENROLLMENT-THEREARENTMATERIALS-0049.title",
|
|
325
|
+
level: "warning"
|
|
326
|
+
},
|
|
327
|
+
"ENROLLMENT-MATERIALNOTFOUND-0052": {
|
|
328
|
+
code: 400,
|
|
329
|
+
type: "modal",
|
|
330
|
+
message: "errors.ENROLLMENT-MATERIALNOTFOUND-0052.message",
|
|
331
|
+
title: "errors.ENROLLMENT-MATERIALNOTFOUND-0052.title",
|
|
332
|
+
level: "warning"
|
|
333
|
+
},
|
|
334
|
+
"ENROLLMENT-THEREARENTMATERIALS-0053": {
|
|
335
|
+
code: 400,
|
|
336
|
+
type: "modal",
|
|
337
|
+
message: "errors.ENROLLMENT-THEREARENTMATERIALS-0053.message",
|
|
338
|
+
title: "errors.ENROLLMENT-THEREARENTMATERIALS-0053.title",
|
|
339
|
+
level: "warning"
|
|
340
|
+
},
|
|
341
|
+
"ENROLLMENT-THEREARENTMATERIALS-0054": {
|
|
342
|
+
code: 400,
|
|
343
|
+
type: "modal",
|
|
344
|
+
message: "errors.ENROLLMENT-THEREARENTMATERIALS-0054.message",
|
|
345
|
+
title: "errors.ENROLLMENT-THEREARENTMATERIALS-0054.title",
|
|
346
|
+
level: "warning"
|
|
347
|
+
},
|
|
348
|
+
"ENROLLMENT-THEREARENTMATERIALS-0058": {
|
|
349
|
+
code: 400,
|
|
350
|
+
type: "modal",
|
|
351
|
+
message: "errors.ENROLLMENT-THEREARENTMATERIALS-0058.message",
|
|
352
|
+
title: "errors.ENROLLMENT-THEREARENTMATERIALS-0058.title",
|
|
353
|
+
level: "warning"
|
|
354
|
+
},
|
|
355
|
+
"ENROLLMENT-THEREARENTMATERIALS-0060": {
|
|
356
|
+
code: 400,
|
|
357
|
+
type: "modal",
|
|
358
|
+
message: "errors.ENROLLMENT-THEREARENTMATERIALS-0060.message",
|
|
359
|
+
title: "errors.ENROLLMENT-THEREARENTMATERIALS-0060.title",
|
|
360
|
+
level: "warning"
|
|
361
|
+
},
|
|
362
|
+
"ENROLLMENT-THEREISNTIMEI-0048": {
|
|
363
|
+
code: 400,
|
|
364
|
+
type: "modal",
|
|
365
|
+
message: "errors.ENROLLMENT-THEREISNTIMEI-0048.message",
|
|
366
|
+
title: "errors.ENROLLMENT-THEREISNTIMEI-0048.title",
|
|
367
|
+
level: "warning"
|
|
305
368
|
}
|
|
306
369
|
}, J = {
|
|
307
370
|
"SKIPFINGERPRINT-WITHOUT-PERMISSIONS-01": {
|
|
@@ -371,7 +434,7 @@ const K = {
|
|
|
371
434
|
}, X = {
|
|
372
435
|
..._,
|
|
373
436
|
...J
|
|
374
|
-
},
|
|
437
|
+
}, i = {
|
|
375
438
|
"MP-001": {
|
|
376
439
|
code: 400,
|
|
377
440
|
type: "modal",
|
|
@@ -1190,28 +1253,28 @@ const K = {
|
|
|
1190
1253
|
...K,
|
|
1191
1254
|
...X
|
|
1192
1255
|
};
|
|
1193
|
-
class C extends
|
|
1194
|
-
get(
|
|
1195
|
-
var N,
|
|
1196
|
-
if (
|
|
1197
|
-
return this.logError(
|
|
1198
|
-
...
|
|
1199
|
-
title:
|
|
1200
|
-
message:
|
|
1256
|
+
class C extends F {
|
|
1257
|
+
get(r = "default", e = "NOT_FOUND") {
|
|
1258
|
+
var N, A;
|
|
1259
|
+
if (r instanceof Error)
|
|
1260
|
+
return this.logError(r.message), {
|
|
1261
|
+
...i.internalError,
|
|
1262
|
+
title: n(i.internalError.title),
|
|
1263
|
+
message: n(i.internalError.message),
|
|
1201
1264
|
uuid: e
|
|
1202
1265
|
};
|
|
1203
|
-
const
|
|
1204
|
-
this.logDebug("statusCode",
|
|
1205
|
-
const
|
|
1266
|
+
const E = typeof r == "string" ? r : r.code ?? r.errorType;
|
|
1267
|
+
this.logDebug("statusCode", E);
|
|
1268
|
+
const l = typeof r == "string" ? {} : { ...r };
|
|
1206
1269
|
return {
|
|
1207
|
-
...
|
|
1208
|
-
title:
|
|
1209
|
-
((N =
|
|
1210
|
-
|
|
1270
|
+
...i[E] ?? i.default,
|
|
1271
|
+
title: n(
|
|
1272
|
+
((N = i[E]) == null ? void 0 : N.title) ?? i.default.title,
|
|
1273
|
+
l
|
|
1211
1274
|
),
|
|
1212
|
-
message:
|
|
1213
|
-
((
|
|
1214
|
-
|
|
1275
|
+
message: n(
|
|
1276
|
+
((A = i[E]) == null ? void 0 : A.message) ?? i.default.message,
|
|
1277
|
+
l
|
|
1215
1278
|
),
|
|
1216
1279
|
uuid: e
|
|
1217
1280
|
};
|
|
@@ -1231,42 +1294,42 @@ class me extends V {
|
|
|
1231
1294
|
throw new C().get("SESSION_NOT_FOUND");
|
|
1232
1295
|
return this.session;
|
|
1233
1296
|
}
|
|
1234
|
-
returnData(e,
|
|
1235
|
-
const N = this.encode(
|
|
1297
|
+
returnData(e, E, l) {
|
|
1298
|
+
const N = this.encode(E, l);
|
|
1236
1299
|
e.status(200).json(N);
|
|
1237
1300
|
}
|
|
1238
|
-
returnError(e,
|
|
1239
|
-
return
|
|
1301
|
+
returnError(e, E) {
|
|
1302
|
+
return E != null && E.uuid ? e.status(520).json(E) : e.status(520).json(new C().get(E, this.uuid));
|
|
1240
1303
|
}
|
|
1241
1304
|
get(e) {
|
|
1242
|
-
return this.logDebug("get ApiMiddleware"), (
|
|
1305
|
+
return this.logDebug("get ApiMiddleware"), (E, l) => {
|
|
1243
1306
|
var N;
|
|
1244
|
-
this.logDebug("return ApiMiddleware"), this.uuid = (N =
|
|
1307
|
+
this.logDebug("return ApiMiddleware"), this.uuid = (N = E == null ? void 0 : E.body) == null ? void 0 : N.uuid, o(E).pipe(
|
|
1245
1308
|
L(
|
|
1246
|
-
(
|
|
1247
|
-
params:
|
|
1248
|
-
headers:
|
|
1309
|
+
(A) => p({
|
|
1310
|
+
params: o(this.decode(A.body)),
|
|
1311
|
+
headers: o(A.headers)
|
|
1249
1312
|
})
|
|
1250
1313
|
),
|
|
1251
1314
|
L(
|
|
1252
|
-
({ params:
|
|
1253
|
-
response: e(
|
|
1254
|
-
headers:
|
|
1255
|
-
params:
|
|
1315
|
+
({ params: A, headers: R }) => p({
|
|
1316
|
+
response: e(A, this.uuid, R),
|
|
1317
|
+
headers: o(R),
|
|
1318
|
+
params: o(A)
|
|
1256
1319
|
})
|
|
1257
1320
|
),
|
|
1258
|
-
L(({ params:
|
|
1259
|
-
`ApiMiddleware \x1B[37m <URL>: \x1B[33m ${
|
|
1260
|
-
),
|
|
1261
|
-
|
|
1321
|
+
L(({ params: A, response: R, headers: s }) => (this.logDebug(
|
|
1322
|
+
`ApiMiddleware \x1B[37m <URL>: \x1B[33m ${E.url} \x1B[37m <HEADERS>: \x1B[33m ${JSON.stringify(s)} \x1B[37m <UUID> \x1B[33m ${E.body.uuid} \x1B[37m <PARAMS> \x1B[33m ${JSON.stringify(A)} \x1B[37m <RESPONSE>: \x1B[33m ${JSON.stringify(R)}`
|
|
1323
|
+
), o(R))),
|
|
1324
|
+
U((A) => {
|
|
1262
1325
|
var R;
|
|
1263
1326
|
return this.logError(
|
|
1264
|
-
`ApiMiddleware <URL>: ${
|
|
1265
|
-
), this.returnError(
|
|
1327
|
+
`ApiMiddleware <URL>: ${E == null ? void 0 : E.url} <HEADERS>: ${JSON.stringify(E == null ? void 0 : E.headers)} <UUID> ${(R = E == null ? void 0 : E.body) == null ? void 0 : R.uuid} <PARAMS> ${JSON.stringify(E == null ? void 0 : E.body)} <ERROR>: ${JSON.stringify(A)}`
|
|
1328
|
+
), this.returnError(l, A), P;
|
|
1266
1329
|
})
|
|
1267
1330
|
).subscribe({
|
|
1268
|
-
next: (
|
|
1269
|
-
this.logDebug("ApiMiddleware subscribe next", JSON.stringify(
|
|
1331
|
+
next: (A) => {
|
|
1332
|
+
this.logDebug("ApiMiddleware subscribe next", JSON.stringify(A)), this.returnData(l, A, this.uuid);
|
|
1270
1333
|
}
|
|
1271
1334
|
});
|
|
1272
1335
|
};
|
|
@@ -1274,15 +1337,15 @@ class me extends V {
|
|
|
1274
1337
|
}
|
|
1275
1338
|
const $ = process.env.ID_FRONT ?? "NOT_AVAILABLE";
|
|
1276
1339
|
class ge extends Q {
|
|
1277
|
-
constructor(e,
|
|
1278
|
-
super(
|
|
1340
|
+
constructor(e, E, l = {}) {
|
|
1341
|
+
super(l);
|
|
1279
1342
|
O(this, "apiUrl");
|
|
1280
1343
|
O(this, "method");
|
|
1281
|
-
this.apiUrl = e, this.method =
|
|
1344
|
+
this.apiUrl = e, this.method = E ?? "POST";
|
|
1282
1345
|
}
|
|
1283
|
-
errorHandler(e,
|
|
1346
|
+
errorHandler(e, E) {
|
|
1284
1347
|
if (e != null && e.errors)
|
|
1285
|
-
throw new C().get(e.errors[0],
|
|
1348
|
+
throw new C().get(e.errors[0], E);
|
|
1286
1349
|
return !(e != null && e.errors);
|
|
1287
1350
|
}
|
|
1288
1351
|
formatParams(e) {
|
|
@@ -1293,69 +1356,69 @@ class ge extends Q {
|
|
|
1293
1356
|
}
|
|
1294
1357
|
});
|
|
1295
1358
|
}
|
|
1296
|
-
fetchData(e = {},
|
|
1359
|
+
fetchData(e = {}, E) {
|
|
1297
1360
|
return this.getHeaders().pipe(
|
|
1298
1361
|
L(
|
|
1299
|
-
(
|
|
1362
|
+
(l) => c(
|
|
1300
1363
|
this.apiUrl,
|
|
1301
1364
|
{
|
|
1302
1365
|
method: "POST",
|
|
1303
|
-
headers:
|
|
1366
|
+
headers: l,
|
|
1304
1367
|
body: this.formatParams(e),
|
|
1305
1368
|
selector: (N) => N.json()
|
|
1306
1369
|
}
|
|
1307
1370
|
).pipe(
|
|
1308
|
-
|
|
1371
|
+
U((N) => {
|
|
1309
1372
|
throw this.logError(JSON.stringify(N)), this.logError(
|
|
1310
|
-
`FetchServiceBE \x1B[37m <URL>: \x1B[33m ${this.apiUrl} \x1B[37m <UUID>: \x1B[33m ${
|
|
1311
|
-
|
|
1373
|
+
`FetchServiceBE \x1B[37m <URL>: \x1B[33m ${this.apiUrl} \x1B[37m <UUID>: \x1B[33m ${E} \x1B[37m <HEADERS>: \x1B[33m ${JSON.stringify(
|
|
1374
|
+
l
|
|
1312
1375
|
)} \x1B[37m <BODY>: \x1B[33m ${JSON.stringify(
|
|
1313
1376
|
this.formatParams(e)
|
|
1314
1377
|
)} \x1B[37m <RESPONSE>: \x1B[33m ${JSON.stringify(N)} \x1B[33m`
|
|
1315
|
-
), new C().get("default",
|
|
1378
|
+
), new C().get("default", E);
|
|
1316
1379
|
}),
|
|
1317
1380
|
L((N) => (this.logDebug(
|
|
1318
|
-
`FetchServiceBE \x1B[37m <URL>: \x1B[33m ${this.apiUrl} \x1B[37m <UUID>: \x1B[33m ${
|
|
1319
|
-
|
|
1381
|
+
`FetchServiceBE \x1B[37m <URL>: \x1B[33m ${this.apiUrl} \x1B[37m <UUID>: \x1B[33m ${E} \x1B[37m <HEADERS>: \x1B[33m ${JSON.stringify(
|
|
1382
|
+
l
|
|
1320
1383
|
)} \x1B[37m <BODY>: \x1B[33m ${JSON.stringify(
|
|
1321
1384
|
this.formatParams(e)
|
|
1322
1385
|
)} \x1B[37m <RESPONSE>: \x1B[33m ${JSON.stringify(N)} \x1B[33m`
|
|
1323
|
-
),
|
|
1386
|
+
), o(N)))
|
|
1324
1387
|
)
|
|
1325
1388
|
),
|
|
1326
|
-
h((
|
|
1389
|
+
h((l) => this.errorHandler(l, E))
|
|
1327
1390
|
);
|
|
1328
1391
|
}
|
|
1329
|
-
fetchCustomData(e = {},
|
|
1330
|
-
const
|
|
1392
|
+
fetchCustomData(e = {}, E) {
|
|
1393
|
+
const l = {
|
|
1331
1394
|
"Content-Type": "application/json"
|
|
1332
|
-
}, N =
|
|
1395
|
+
}, N = H.stringify(
|
|
1333
1396
|
e
|
|
1334
|
-
),
|
|
1335
|
-
return this.getHeaders(
|
|
1397
|
+
), A = `${this.apiUrl}?${N}`, R = this.method === "GET" ? A : this.apiUrl;
|
|
1398
|
+
return this.getHeaders(l).pipe(
|
|
1336
1399
|
L(
|
|
1337
1400
|
(s) => c(R, {
|
|
1338
1401
|
method: this.method,
|
|
1339
1402
|
headers: s,
|
|
1340
1403
|
body: this.method === "GET" ? null : JSON.stringify(e),
|
|
1341
|
-
selector: (
|
|
1404
|
+
selector: (T) => T.json()
|
|
1342
1405
|
}).pipe(
|
|
1343
|
-
|
|
1344
|
-
throw this.logError(JSON.stringify(
|
|
1345
|
-
`FetchServiceBE \x1B[37m <URL>: \x1B[33m ${R} \x1B[37m <UUID>: \x1B[33m ${
|
|
1406
|
+
U((T) => {
|
|
1407
|
+
throw this.logError(JSON.stringify(T)), this.logError(
|
|
1408
|
+
`FetchServiceBE \x1B[37m <URL>: \x1B[33m ${R} \x1B[37m <UUID>: \x1B[33m ${E} \x1B[37m <HEADERS>: \x1B[33m ${JSON.stringify(
|
|
1346
1409
|
s
|
|
1347
1410
|
)} \x1B[37m <BODY>: \x1B[33m ${JSON.stringify(
|
|
1348
1411
|
this.formatParams(e)
|
|
1349
|
-
)} \x1B[37m <RESPONSE>: \x1B[33m ${JSON.stringify(
|
|
1350
|
-
), new C().get("default",
|
|
1412
|
+
)} \x1B[37m <RESPONSE>: \x1B[33m ${JSON.stringify(T)} \x1B[33m`
|
|
1413
|
+
), new C().get("default", E);
|
|
1351
1414
|
}),
|
|
1352
|
-
L((
|
|
1353
|
-
`FetchServiceBE \x1B[37m <URL>: \x1B[33m ${R} \x1B[37m \x1B[37m <METHOD>: \x1B[33m ${this.method} <UUID>: \x1B[33m ${
|
|
1415
|
+
L((T) => (this.logDebug(
|
|
1416
|
+
`FetchServiceBE \x1B[37m <URL>: \x1B[33m ${R} \x1B[37m \x1B[37m <METHOD>: \x1B[33m ${this.method} <UUID>: \x1B[33m ${E} \x1B[37m <HEADERS>: \x1B[33m ${JSON.stringify(
|
|
1354
1417
|
s
|
|
1355
1418
|
)} \x1B[37m <BODY>: \x1B[33m ${JSON.stringify(
|
|
1356
1419
|
e
|
|
1357
|
-
)} \x1B[37m <RESPONSE>: \x1B[33m ${JSON.stringify(
|
|
1358
|
-
), T
|
|
1420
|
+
)} \x1B[37m <RESPONSE>: \x1B[33m ${JSON.stringify(T)} \x1B[33m`
|
|
1421
|
+
), o(T)))
|
|
1359
1422
|
)
|
|
1360
1423
|
)
|
|
1361
1424
|
);
|
|
@@ -1368,98 +1431,98 @@ function W(t) {
|
|
|
1368
1431
|
function k(t) {
|
|
1369
1432
|
if (!W(t))
|
|
1370
1433
|
throw TypeError("Invalid UUID");
|
|
1371
|
-
let
|
|
1434
|
+
let r;
|
|
1372
1435
|
const e = new Uint8Array(16);
|
|
1373
|
-
return e[0] = (
|
|
1436
|
+
return e[0] = (r = parseInt(t.slice(0, 8), 16)) >>> 24, e[1] = r >>> 16 & 255, e[2] = r >>> 8 & 255, e[3] = r & 255, e[4] = (r = parseInt(t.slice(9, 13), 16)) >>> 8, e[5] = r & 255, e[6] = (r = parseInt(t.slice(14, 18), 16)) >>> 8, e[7] = r & 255, e[8] = (r = parseInt(t.slice(19, 23), 16)) >>> 8, e[9] = r & 255, e[10] = (r = parseInt(t.slice(24, 36), 16)) / 1099511627776 & 255, e[11] = r / 4294967296 & 255, e[12] = r >>> 24 & 255, e[13] = r >>> 16 & 255, e[14] = r >>> 8 & 255, e[15] = r & 255, e;
|
|
1374
1437
|
}
|
|
1375
1438
|
function j(t) {
|
|
1376
1439
|
t = unescape(encodeURIComponent(t));
|
|
1377
|
-
const
|
|
1440
|
+
const r = [];
|
|
1378
1441
|
for (let e = 0; e < t.length; ++e)
|
|
1379
|
-
|
|
1380
|
-
return
|
|
1442
|
+
r.push(t.charCodeAt(e));
|
|
1443
|
+
return r;
|
|
1381
1444
|
}
|
|
1382
1445
|
const Z = "6ba7b810-9dad-11d1-80b4-00c04fd430c8", z = "6ba7b811-9dad-11d1-80b4-00c04fd430c8";
|
|
1383
|
-
function q(t,
|
|
1384
|
-
function
|
|
1446
|
+
function q(t, r, e) {
|
|
1447
|
+
function E(l, N, A, R) {
|
|
1385
1448
|
var s;
|
|
1386
|
-
if (typeof
|
|
1449
|
+
if (typeof l == "string" && (l = j(l)), typeof N == "string" && (N = k(N)), ((s = N) === null || s === void 0 ? void 0 : s.length) !== 16)
|
|
1387
1450
|
throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");
|
|
1388
|
-
let
|
|
1389
|
-
if (
|
|
1451
|
+
let T = new Uint8Array(16 + l.length);
|
|
1452
|
+
if (T.set(N), T.set(l, N.length), T = e(T), T[6] = T[6] & 15 | r, T[8] = T[8] & 63 | 128, A) {
|
|
1390
1453
|
R = R || 0;
|
|
1391
|
-
for (let
|
|
1392
|
-
|
|
1393
|
-
return
|
|
1454
|
+
for (let I = 0; I < 16; ++I)
|
|
1455
|
+
A[R + I] = T[I];
|
|
1456
|
+
return A;
|
|
1394
1457
|
}
|
|
1395
|
-
return
|
|
1458
|
+
return G(T);
|
|
1396
1459
|
}
|
|
1397
1460
|
try {
|
|
1398
|
-
|
|
1461
|
+
E.name = t;
|
|
1399
1462
|
} catch {
|
|
1400
1463
|
}
|
|
1401
|
-
return
|
|
1464
|
+
return E.DNS = Z, E.URL = z, E;
|
|
1402
1465
|
}
|
|
1403
|
-
function ee(t,
|
|
1466
|
+
function ee(t, r, e, E) {
|
|
1404
1467
|
switch (t) {
|
|
1405
1468
|
case 0:
|
|
1406
|
-
return
|
|
1469
|
+
return r & e ^ ~r & E;
|
|
1407
1470
|
case 1:
|
|
1408
|
-
return
|
|
1471
|
+
return r ^ e ^ E;
|
|
1409
1472
|
case 2:
|
|
1410
|
-
return
|
|
1473
|
+
return r & e ^ r & E ^ e & E;
|
|
1411
1474
|
case 3:
|
|
1412
|
-
return
|
|
1475
|
+
return r ^ e ^ E;
|
|
1413
1476
|
}
|
|
1414
1477
|
}
|
|
1415
|
-
function D(t,
|
|
1416
|
-
return t <<
|
|
1478
|
+
function D(t, r) {
|
|
1479
|
+
return t << r | t >>> 32 - r;
|
|
1417
1480
|
}
|
|
1418
|
-
function
|
|
1419
|
-
const
|
|
1481
|
+
function Ee(t) {
|
|
1482
|
+
const r = [1518500249, 1859775393, 2400959708, 3395469782], e = [1732584193, 4023233417, 2562383102, 271733878, 3285377520];
|
|
1420
1483
|
if (typeof t == "string") {
|
|
1421
|
-
const
|
|
1484
|
+
const A = unescape(encodeURIComponent(t));
|
|
1422
1485
|
t = [];
|
|
1423
|
-
for (let R = 0; R <
|
|
1424
|
-
t.push(
|
|
1486
|
+
for (let R = 0; R < A.length; ++R)
|
|
1487
|
+
t.push(A.charCodeAt(R));
|
|
1425
1488
|
} else
|
|
1426
1489
|
Array.isArray(t) || (t = Array.prototype.slice.call(t));
|
|
1427
1490
|
t.push(128);
|
|
1428
|
-
const
|
|
1429
|
-
for (let
|
|
1491
|
+
const E = t.length / 4 + 2, l = Math.ceil(E / 16), N = new Array(l);
|
|
1492
|
+
for (let A = 0; A < l; ++A) {
|
|
1430
1493
|
const R = new Uint32Array(16);
|
|
1431
1494
|
for (let s = 0; s < 16; ++s)
|
|
1432
|
-
R[s] = t[
|
|
1433
|
-
N[
|
|
1495
|
+
R[s] = t[A * 64 + s * 4] << 24 | t[A * 64 + s * 4 + 1] << 16 | t[A * 64 + s * 4 + 2] << 8 | t[A * 64 + s * 4 + 3];
|
|
1496
|
+
N[A] = R;
|
|
1434
1497
|
}
|
|
1435
|
-
N[
|
|
1436
|
-
for (let
|
|
1498
|
+
N[l - 1][14] = (t.length - 1) * 8 / Math.pow(2, 32), N[l - 1][14] = Math.floor(N[l - 1][14]), N[l - 1][15] = (t.length - 1) * 8 & 4294967295;
|
|
1499
|
+
for (let A = 0; A < l; ++A) {
|
|
1437
1500
|
const R = new Uint32Array(80);
|
|
1438
|
-
for (let
|
|
1439
|
-
R[
|
|
1440
|
-
for (let
|
|
1441
|
-
R[
|
|
1442
|
-
let s = e[0],
|
|
1443
|
-
for (let
|
|
1444
|
-
const d = Math.floor(
|
|
1445
|
-
S = m, m =
|
|
1501
|
+
for (let a = 0; a < 16; ++a)
|
|
1502
|
+
R[a] = N[A][a];
|
|
1503
|
+
for (let a = 16; a < 80; ++a)
|
|
1504
|
+
R[a] = D(R[a - 3] ^ R[a - 8] ^ R[a - 14] ^ R[a - 16], 1);
|
|
1505
|
+
let s = e[0], T = e[1], I = e[2], m = e[3], S = e[4];
|
|
1506
|
+
for (let a = 0; a < 80; ++a) {
|
|
1507
|
+
const d = Math.floor(a / 20), y = D(s, 5) + ee(d, T, I, m) + S + r[d] + R[a] >>> 0;
|
|
1508
|
+
S = m, m = I, I = D(T, 30) >>> 0, T = s, s = y;
|
|
1446
1509
|
}
|
|
1447
|
-
e[0] = e[0] + s >>> 0, e[1] = e[1] +
|
|
1510
|
+
e[0] = e[0] + s >>> 0, e[1] = e[1] + T >>> 0, e[2] = e[2] + I >>> 0, e[3] = e[3] + m >>> 0, e[4] = e[4] + S >>> 0;
|
|
1448
1511
|
}
|
|
1449
1512
|
return [e[0] >> 24 & 255, e[0] >> 16 & 255, e[0] >> 8 & 255, e[0] & 255, e[1] >> 24 & 255, e[1] >> 16 & 255, e[1] >> 8 & 255, e[1] & 255, e[2] >> 24 & 255, e[2] >> 16 & 255, e[2] >> 8 & 255, e[2] & 255, e[3] >> 24 & 255, e[3] >> 16 & 255, e[3] >> 8 & 255, e[3] & 255, e[4] >> 24 & 255, e[4] >> 16 & 255, e[4] >> 8 & 255, e[4] & 255];
|
|
1450
1513
|
}
|
|
1451
|
-
const
|
|
1452
|
-
class
|
|
1453
|
-
constructor(e,
|
|
1514
|
+
const re = q("v5", 80, Ee), B = re;
|
|
1515
|
+
class ne extends x {
|
|
1516
|
+
constructor(e, E = "POST", l = {}) {
|
|
1454
1517
|
super();
|
|
1455
1518
|
O(this, "apiUrl");
|
|
1456
1519
|
O(this, "method");
|
|
1457
1520
|
O(this, "headers");
|
|
1458
1521
|
O(this, "isLoadingEnabled", !0);
|
|
1459
1522
|
O(this, "errorResponse");
|
|
1460
|
-
this.apiUrl = e, this.method =
|
|
1523
|
+
this.apiUrl = e, this.method = E, this.headers = {
|
|
1461
1524
|
"Content-Type": "application/json",
|
|
1462
|
-
...
|
|
1525
|
+
...l
|
|
1463
1526
|
};
|
|
1464
1527
|
}
|
|
1465
1528
|
setIsLoadingEnabled(e) {
|
|
@@ -1469,7 +1532,7 @@ class Ue extends G {
|
|
|
1469
1532
|
this.errorResponse = e;
|
|
1470
1533
|
}
|
|
1471
1534
|
fetchData(e = {}) {
|
|
1472
|
-
const
|
|
1535
|
+
const E = (/* @__PURE__ */ new Date()).toISOString(), l = B(E, B.URL), N = this.encode({ ...e }, l);
|
|
1473
1536
|
g.getInstance().setSubject(this.isLoadingEnabled);
|
|
1474
1537
|
const R = new URLSearchParams(window.location.search).get("flow") ?? "N/A";
|
|
1475
1538
|
return c(this.apiUrl, {
|
|
@@ -1478,18 +1541,18 @@ class Ue extends G {
|
|
|
1478
1541
|
body: N,
|
|
1479
1542
|
selector: (s) => s.json()
|
|
1480
1543
|
}).pipe(
|
|
1481
|
-
L((s) =>
|
|
1544
|
+
L((s) => o(this.decode(s))),
|
|
1482
1545
|
L((s) => s.code && (s.type === "modal" || s.type === "message") ? (this.logError(
|
|
1483
1546
|
`FetchServiceFE <URL>: ${this.apiUrl} <HEADERS>: ${JSON.stringify(this.headers)} <PARAMS> ${JSON.stringify(e)} <BODY> ${N} <RESPONSE>: ${JSON.stringify(s)}`
|
|
1484
|
-
), g.getInstance().setSubject(!1), M.getInstance().setSubject(s), this.errorResponse ?
|
|
1547
|
+
), g.getInstance().setSubject(!1), M.getInstance().setSubject(s), this.errorResponse ? o(this.errorResponse) : P) : o(s)),
|
|
1485
1548
|
L((s) => (g.getInstance().setSubject(!1), this.logDebug(
|
|
1486
1549
|
`FetchServiceFE <URL>: ${this.apiUrl} <HEADERS>: ${JSON.stringify(this.headers)} <PARAMS> ${JSON.stringify(e)} <BODY> ${N} <RESPONSE>: ${JSON.stringify(s)}`
|
|
1487
|
-
),
|
|
1488
|
-
|
|
1550
|
+
), o(s))),
|
|
1551
|
+
U((s) => (this.logError(
|
|
1489
1552
|
`FetchServiceFE <URL>: ${this.apiUrl} <HEADERS>: ${JSON.stringify(this.headers)} <PARAMS> ${JSON.stringify(e)} <BODY> ${N} <RESPONSE>: ${JSON.stringify(s)}`
|
|
1490
1553
|
), g.getInstance().setSubject(!1), M.getInstance().setSubject(
|
|
1491
|
-
new C().get(s,
|
|
1492
|
-
), this.errorResponse ?
|
|
1554
|
+
new C().get(s, l)
|
|
1555
|
+
), this.errorResponse ? o(this.errorResponse) : P))
|
|
1493
1556
|
);
|
|
1494
1557
|
}
|
|
1495
1558
|
}
|
|
@@ -1497,7 +1560,7 @@ export {
|
|
|
1497
1560
|
me as ApiMiddleware,
|
|
1498
1561
|
C as ErrorCatalog,
|
|
1499
1562
|
ge as FetchServiceBE,
|
|
1500
|
-
|
|
1563
|
+
ne as FetchServiceFE,
|
|
1501
1564
|
g as LoadingHandler,
|
|
1502
1565
|
M as MessageHandler,
|
|
1503
1566
|
De as RxSubjectManager,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "mp-front-cli",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.127",
|
|
4
4
|
"private": false,
|
|
5
5
|
"type": "module",
|
|
6
6
|
"scripts": {
|
|
@@ -74,7 +74,6 @@
|
|
|
74
74
|
"@types/uuid": "9.0.8",
|
|
75
75
|
"husky": "^9.0.11",
|
|
76
76
|
"lodash": "4.17.21",
|
|
77
|
-
"mp-front-cli": "file:",
|
|
78
77
|
"uuid": "9.0.1"
|
|
79
78
|
},
|
|
80
79
|
"devDependencies": {
|
|
@@ -89,4 +88,4 @@
|
|
|
89
88
|
"vite-plugin-dts": "3.7.1",
|
|
90
89
|
"vite-tsconfig-paths": "4.2.2"
|
|
91
90
|
}
|
|
92
|
-
}
|
|
91
|
+
}
|