prostgles-server 3.0.115 → 3.0.117
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/JSONBValidation/validate_jsonb_schema_sql.js +2 -2
- package/dist/JSONBValidation/validation.js +1 -1
- package/lib/JSONBValidation/validate_jsonb_schema_sql.js +2 -2
- package/lib/JSONBValidation/validate_jsonb_schema_sql.ts +2 -2
- package/lib/JSONBValidation/validation.js +1 -1
- package/lib/JSONBValidation/validation.ts +1 -1
- package/package.json +1 -1
- package/tests/client/PID.txt +1 -1
- package/tests/isomorphic_queries.ts +1 -1
- package/tests/server/package-lock.json +1 -1
|
@@ -34,9 +34,9 @@ DECLARE
|
|
|
34
34
|
"isArray": { "type": "boolean", "optional": true },
|
|
35
35
|
"filter": { "optional": true, "type": "any" },
|
|
36
36
|
"isFullRow": { "optional": true, "type": {
|
|
37
|
-
"displayColumns": { "optional": true, "type": "string[]" }
|
|
38
|
-
"searchColumns": { "optional": true, "type": "string[]" }
|
|
37
|
+
"displayColumns": { "optional": true, "type": "string[]" }
|
|
39
38
|
}},
|
|
39
|
+
"searchColumns": { "optional": true, "type": "string[]" },
|
|
40
40
|
"showInRowCard": { "optional": true, "type": "any" }
|
|
41
41
|
}
|
|
42
42
|
|
|
@@ -94,7 +94,7 @@ function getJSONBSchemaTSTypes(schema, colOpts, outerLeading = "", tables) {
|
|
|
94
94
|
else if (fieldType?.lookup) {
|
|
95
95
|
const l = fieldType.lookup;
|
|
96
96
|
if (l.type === "data-def") {
|
|
97
|
-
return `${fieldType.nullable ? `null |` : ""} { "table": string; "column": string; filter?: Record<string, any>; isArray?: boolean;
|
|
97
|
+
return `${fieldType.nullable ? `null |` : ""} { "table": string; "column": string; filter?: Record<string, any>; isArray?: boolean; searchColumns?: string[]; isFullRow?: { displayColumns?: string[]; }; showInRowCard?: Record<string, any>; }`;
|
|
98
98
|
}
|
|
99
99
|
const isSChema = l.type === "schema";
|
|
100
100
|
let type = isSChema ? (l.object === "table" ? "string" : `{ "table": string; "column": string; }`) : "";
|
|
@@ -34,9 +34,9 @@ DECLARE
|
|
|
34
34
|
"isArray": { "type": "boolean", "optional": true },
|
|
35
35
|
"filter": { "optional": true, "type": "any" },
|
|
36
36
|
"isFullRow": { "optional": true, "type": {
|
|
37
|
-
"displayColumns": { "optional": true, "type": "string[]" }
|
|
38
|
-
"searchColumns": { "optional": true, "type": "string[]" }
|
|
37
|
+
"displayColumns": { "optional": true, "type": "string[]" }
|
|
39
38
|
}},
|
|
39
|
+
"searchColumns": { "optional": true, "type": "string[]" },
|
|
40
40
|
"showInRowCard": { "optional": true, "type": "any" }
|
|
41
41
|
}
|
|
42
42
|
|
|
@@ -33,9 +33,9 @@ DECLARE
|
|
|
33
33
|
"isArray": { "type": "boolean", "optional": true },
|
|
34
34
|
"filter": { "optional": true, "type": "any" },
|
|
35
35
|
"isFullRow": { "optional": true, "type": {
|
|
36
|
-
"displayColumns": { "optional": true, "type": "string[]" }
|
|
37
|
-
"searchColumns": { "optional": true, "type": "string[]" }
|
|
36
|
+
"displayColumns": { "optional": true, "type": "string[]" }
|
|
38
37
|
}},
|
|
38
|
+
"searchColumns": { "optional": true, "type": "string[]" },
|
|
39
39
|
"showInRowCard": { "optional": true, "type": "any" }
|
|
40
40
|
}
|
|
41
41
|
|
|
@@ -94,7 +94,7 @@ function getJSONBSchemaTSTypes(schema, colOpts, outerLeading = "", tables) {
|
|
|
94
94
|
else if (fieldType?.lookup) {
|
|
95
95
|
const l = fieldType.lookup;
|
|
96
96
|
if (l.type === "data-def") {
|
|
97
|
-
return `${fieldType.nullable ? `null |` : ""} { "table": string; "column": string; filter?: Record<string, any>; isArray?: boolean;
|
|
97
|
+
return `${fieldType.nullable ? `null |` : ""} { "table": string; "column": string; filter?: Record<string, any>; isArray?: boolean; searchColumns?: string[]; isFullRow?: { displayColumns?: string[]; }; showInRowCard?: Record<string, any>; }`;
|
|
98
98
|
}
|
|
99
99
|
const isSChema = l.type === "schema";
|
|
100
100
|
let type = isSChema ? (l.object === "table" ? "string" : `{ "table": string; "column": string; }`) : "";
|
|
@@ -98,7 +98,7 @@ export function getJSONBSchemaTSTypes(schema: JSONB.JSONBSchema, colOpts: ColOpt
|
|
|
98
98
|
|
|
99
99
|
const l = fieldType.lookup;
|
|
100
100
|
if(l.type === "data-def"){
|
|
101
|
-
return `${fieldType.nullable ? `null |` : ""} { "table": string; "column": string; filter?: Record<string, any>; isArray?: boolean;
|
|
101
|
+
return `${fieldType.nullable ? `null |` : ""} { "table": string; "column": string; filter?: Record<string, any>; isArray?: boolean; searchColumns?: string[]; isFullRow?: { displayColumns?: string[]; }; showInRowCard?: Record<string, any>; }`;
|
|
102
102
|
}
|
|
103
103
|
|
|
104
104
|
const isSChema = l.type === "schema";
|
package/package.json
CHANGED
package/tests/client/PID.txt
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
188717
|
|
@@ -685,7 +685,7 @@ export default async function isomorphic(db: Required<DBHandlerServer> | Require
|
|
|
685
685
|
await db.tjson.insert!({ colOneOf: "a", json: { a: true, arr: "22"} });
|
|
686
686
|
throw "Should have failed"
|
|
687
687
|
} catch(e){
|
|
688
|
-
console.log("Perfect
|
|
688
|
+
console.log("Perfect fail")
|
|
689
689
|
// Perfect
|
|
690
690
|
}
|
|
691
691
|
});
|