goby-database 2.1.14 → 2.1.16
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/index.d.ts +1 -1
- package/dist/index.js +3 -3
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -97,7 +97,7 @@ export default class Project {
|
|
|
97
97
|
}): (DataProperty | RelationProperty);
|
|
98
98
|
retrieve_windows(): ApplicationWindow[];
|
|
99
99
|
retrieve_workspace_contents(id: number): {
|
|
100
|
-
|
|
100
|
+
blocks: WorkspaceBlock[];
|
|
101
101
|
items: unknown[];
|
|
102
102
|
};
|
|
103
103
|
action_config_window({ type, open, metadata, id }: {
|
package/dist/index.js
CHANGED
|
@@ -938,8 +938,8 @@ export default class Project {
|
|
|
938
938
|
}
|
|
939
939
|
retrieve_workspace_contents(id) {
|
|
940
940
|
// get the workspace table
|
|
941
|
-
let
|
|
942
|
-
let
|
|
941
|
+
let blocks_sql = this.db.prepare(`SELECT * FROM workspace_${id}`).all();
|
|
942
|
+
let blocks = blocks_sql.map(a => (Object.assign(Object.assign({}, a), { metadata: JSON.parse(a.metadata) })));
|
|
943
943
|
// for(let block of blocks) block.metadata=JSON.parse(block.metadata);
|
|
944
944
|
// get any relevant root items
|
|
945
945
|
let items = this.db.prepare(`SELECT system_root.*
|
|
@@ -950,7 +950,7 @@ export default class Project {
|
|
|
950
950
|
`).all();
|
|
951
951
|
// get any relevant classes (going to hold off from this for now)
|
|
952
952
|
return {
|
|
953
|
-
|
|
953
|
+
blocks,
|
|
954
954
|
items
|
|
955
955
|
};
|
|
956
956
|
}
|