@xuda.io/xuda-dbs-plugin-xuda 1.0.157 → 1.0.159
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/package.json +1 -1
- package/server.js +4 -4
- package/studio.mjs +4 -4
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@xuda.io/xuda-dbs-plugin-xuda",
|
3
|
-
"version": "1.0.
|
3
|
+
"version": "1.0.159",
|
4
4
|
"description": "Xuda Database Socket for Xuda's proprietary structure powered by CouchDB",
|
5
5
|
"scripts": {
|
6
6
|
"pub": "npm version patch --force && npm publish --access public"
|
package/server.js
CHANGED
@@ -957,15 +957,15 @@ exports.create = async (params, setup_doc, resolve, reject) => {
|
|
957
957
|
return doc;
|
958
958
|
};
|
959
959
|
|
960
|
-
const get_uuid = function (
|
961
|
-
return "
|
960
|
+
const get_uuid = function (table_id) {
|
961
|
+
return "dbs-" + table_id + "_" + crypto.randomUUID();
|
962
962
|
};
|
963
963
|
const batch = async function () {
|
964
964
|
var docs = [];
|
965
965
|
try {
|
966
966
|
for await (var val of e.table_data) {
|
967
967
|
var doc = {
|
968
|
-
_id: get_uuid(e.
|
968
|
+
_id: get_uuid(e.table_id),
|
969
969
|
docType: "database",
|
970
970
|
user: e.uid,
|
971
971
|
app_id: e.app_id,
|
@@ -1001,7 +1001,7 @@ exports.create = async (params, setup_doc, resolve, reject) => {
|
|
1001
1001
|
};
|
1002
1002
|
const single = async function () {
|
1003
1003
|
var doc = {
|
1004
|
-
_id: get_uuid(e.
|
1004
|
+
_id: get_uuid(e.table_id),
|
1005
1005
|
docType: "database",
|
1006
1006
|
user: e.uid,
|
1007
1007
|
app_id: e.app_id,
|
package/studio.mjs
CHANGED
@@ -1004,15 +1004,15 @@ export const create = async (params, resolve, reject) => {
|
|
1004
1004
|
|
1005
1005
|
return doc;
|
1006
1006
|
};
|
1007
|
-
const get_uuid = function (
|
1008
|
-
return "
|
1007
|
+
const get_uuid = function (table_id) {
|
1008
|
+
return "dbs-" + table_id + "_" + crypto.randomUUID();
|
1009
1009
|
};
|
1010
1010
|
const batch = async function () {
|
1011
1011
|
var docs = [];
|
1012
1012
|
try {
|
1013
1013
|
for await (var val of e.table_data) {
|
1014
1014
|
var doc = {
|
1015
|
-
_id: get_uuid(e.
|
1015
|
+
_id: get_uuid(e.table_id),
|
1016
1016
|
docType: "database",
|
1017
1017
|
user: e.uid,
|
1018
1018
|
app_id: e.app_id,
|
@@ -1049,7 +1049,7 @@ export const create = async (params, resolve, reject) => {
|
|
1049
1049
|
};
|
1050
1050
|
const single = async function () {
|
1051
1051
|
var doc = {
|
1052
|
-
_id: get_uuid(e.
|
1052
|
+
_id: get_uuid(e.table_id),
|
1053
1053
|
docType: "database",
|
1054
1054
|
user: e.uid,
|
1055
1055
|
app_id: e.app_id,
|