@xuda.io/xuda-worker-bundle-min 1.3.418 → 1.3.419
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/index.js +18 -7
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -382,7 +382,11 @@ func.common.db = async function (
|
|
|
382
382
|
}
|
|
383
383
|
|
|
384
384
|
if (doc.stat < 3) {
|
|
385
|
-
return await func.common.perform_rpi_request(
|
|
385
|
+
return await func.common.perform_rpi_request(
|
|
386
|
+
SESSION_ID,
|
|
387
|
+
serviceP,
|
|
388
|
+
opt
|
|
389
|
+
);
|
|
386
390
|
}
|
|
387
391
|
return await func.db.pouch[serviceP](SESSION_ID, dataP);
|
|
388
392
|
} catch (err) {}
|
|
@@ -398,7 +402,8 @@ func.common.db = async function (
|
|
|
398
402
|
} catch (err) {
|
|
399
403
|
const json = await func.common.perform_rpi_request(
|
|
400
404
|
SESSION_ID,
|
|
401
|
-
serviceP
|
|
405
|
+
serviceP,
|
|
406
|
+
opt
|
|
402
407
|
);
|
|
403
408
|
if (json.opt) {
|
|
404
409
|
try {
|
|
@@ -428,7 +433,7 @@ func.common.db = async function (
|
|
|
428
433
|
await db.get(dataP.row_id);
|
|
429
434
|
return await func.db.pouch[serviceP](SESSION_ID, dataP);
|
|
430
435
|
} catch (err) {
|
|
431
|
-
return await func.common.perform_rpi_request(SESSION_ID, serviceP);
|
|
436
|
+
return await func.common.perform_rpi_request(SESSION_ID, serviceP, opt);
|
|
432
437
|
}
|
|
433
438
|
};
|
|
434
439
|
const create_dbs_pouch = async function (db) {
|
|
@@ -436,7 +441,7 @@ func.common.db = async function (
|
|
|
436
441
|
try {
|
|
437
442
|
return await func.db.pouch[serviceP](SESSION_ID, dataP);
|
|
438
443
|
} catch (err) {
|
|
439
|
-
return await func.common.perform_rpi_request(SESSION_ID, serviceP);
|
|
444
|
+
return await func.common.perform_rpi_request(SESSION_ID, serviceP, opt);
|
|
440
445
|
}
|
|
441
446
|
};
|
|
442
447
|
|
|
@@ -489,7 +494,8 @@ func.common.db = async function (
|
|
|
489
494
|
try {
|
|
490
495
|
const json = await func.common.perform_rpi_request(
|
|
491
496
|
SESSION_ID,
|
|
492
|
-
serviceP
|
|
497
|
+
serviceP,
|
|
498
|
+
opt
|
|
493
499
|
);
|
|
494
500
|
return success_callback(json, true);
|
|
495
501
|
} catch (err) {
|
|
@@ -501,7 +507,8 @@ func.common.db = async function (
|
|
|
501
507
|
try {
|
|
502
508
|
const json = await func.common.perform_rpi_request(
|
|
503
509
|
SESSION_ID,
|
|
504
|
-
serviceP
|
|
510
|
+
serviceP,
|
|
511
|
+
opt
|
|
505
512
|
);
|
|
506
513
|
return success_callback(json, true);
|
|
507
514
|
} catch (err) {
|
|
@@ -1038,7 +1045,11 @@ func.api.call_api_program = async function (prog_id, params) {
|
|
|
1038
1045
|
return await api_utils.call_api_program(prog_id, params, null);
|
|
1039
1046
|
};
|
|
1040
1047
|
|
|
1041
|
-
func.common.perform_rpi_request = async function (
|
|
1048
|
+
func.common.perform_rpi_request = async function (
|
|
1049
|
+
SESSION_ID,
|
|
1050
|
+
serviceP,
|
|
1051
|
+
opt = {}
|
|
1052
|
+
) {
|
|
1042
1053
|
var url = func.common.get_url(SESSION_ID, "rpi", "");
|
|
1043
1054
|
var _session = SESSION_OBJ[SESSION_ID];
|
|
1044
1055
|
const app_id = _session.APP_ID;
|