@geode/opengeodeweb-front 10.6.2 → 10.7.0-rc.1
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/.eslintrc.cjs +1 -1
- package/.oxlintrc.json +3 -22
- package/app/assets/geode_objects.js +26 -26
- package/app/components/Carousel.vue +62 -66
- package/app/components/CrsSelector.vue +48 -52
- package/app/components/DeleteDialog.vue +21 -37
- package/app/components/DragAndDrop.vue +35 -41
- package/app/components/ExtensionSelector.vue +50 -63
- package/app/components/FeedBack/ErrorBanner.vue +7 -10
- package/app/components/FeedBack/Snackers.vue +12 -14
- package/app/components/FetchingData.vue +1 -6
- package/app/components/FileSelector.vue +41 -47
- package/app/components/FileUploader.vue +62 -79
- package/app/components/GlassCard.vue +19 -19
- package/app/components/HybridRenderingView.vue +37 -38
- package/app/components/InfraConnected.vue +3 -3
- package/app/components/Inspector/InspectionButton.vue +27 -31
- package/app/components/Inspector/ResultPanel.vue +13 -24
- package/app/components/Launcher.vue +13 -13
- package/app/components/Loading.vue +63 -69
- package/app/components/MissingFilesSelector.vue +53 -73
- package/app/components/ObjectSelector.vue +81 -99
- package/app/components/PackagesVersions.vue +27 -30
- package/app/components/Recaptcha.vue +60 -71
- package/app/components/RemoteRenderingView.vue +102 -108
- package/app/components/Screenshot.vue +36 -42
- package/app/components/SearchBar.vue +5 -5
- package/app/components/Step.vue +37 -44
- package/app/components/Stepper.vue +29 -35
- package/app/components/VeaseViewToolbar.vue +69 -78
- package/app/components/ViewToolbar.vue +41 -45
- package/app/components/Viewer/BreadCrumb.vue +18 -30
- package/app/components/Viewer/ContextMenu.vue +176 -179
- package/app/components/Viewer/ContextMenuItem.vue +105 -117
- package/app/components/Viewer/EdgedCurve/PointsOptions.vue +6 -9
- package/app/components/Viewer/EdgedCurve/SpecificEdgesOptions.vue +82 -93
- package/app/components/Viewer/Generic/Mesh/CellsOptions.vue +84 -99
- package/app/components/Viewer/Generic/Mesh/EdgesOptions.vue +83 -98
- package/app/components/Viewer/Generic/Mesh/PointsOptions.vue +62 -73
- package/app/components/Viewer/Generic/Mesh/PolygonsOptions.vue +84 -108
- package/app/components/Viewer/Generic/Mesh/PolyhedraOptions.vue +82 -105
- package/app/components/Viewer/Generic/Model/EdgesOptions.vue +19 -23
- package/app/components/Viewer/Generic/Model/PointsOptions.vue +26 -30
- package/app/components/Viewer/Grid/2D/CellsOptions.vue +5 -5
- package/app/components/Viewer/Grid/2D/EdgesOptions.vue +6 -9
- package/app/components/Viewer/Grid/2D/PointsOptions.vue +6 -9
- package/app/components/Viewer/Grid/3D/CellsOptions.vue +5 -5
- package/app/components/Viewer/Grid/3D/EdgesOptions.vue +6 -9
- package/app/components/Viewer/Grid/3D/FacetsOptions.vue +5 -5
- package/app/components/Viewer/Grid/3D/PointsOptions.vue +6 -9
- package/app/components/Viewer/HybridSolid/EdgesOptions.vue +6 -9
- package/app/components/Viewer/HybridSolid/PointsOptions.vue +6 -9
- package/app/components/Viewer/HybridSolid/PolygonsOptions.vue +6 -9
- package/app/components/Viewer/HybridSolid/PolyhedraOptions.vue +6 -9
- package/app/components/Viewer/Options/AttributeColorBar.vue +8 -8
- package/app/components/Viewer/Options/AttributeSelector.vue +73 -78
- package/app/components/Viewer/Options/ColorMapList.vue +115 -140
- package/app/components/Viewer/Options/ColorMapPicker.vue +128 -142
- package/app/components/Viewer/Options/ColorPicker.vue +9 -9
- package/app/components/Viewer/Options/ColoringTypeSelector.vue +77 -91
- package/app/components/Viewer/Options/TextureItem.vue +54 -58
- package/app/components/Viewer/Options/TexturesSelector.vue +22 -26
- package/app/components/Viewer/Options/VisibilitySwitch.vue +1 -1
- package/app/components/Viewer/PointSet/SpecificPointsOptions.vue +61 -68
- package/app/components/Viewer/PolygonalSurface/EdgesOptions.vue +6 -9
- package/app/components/Viewer/PolygonalSurface/PointsOptions.vue +6 -9
- package/app/components/Viewer/PolygonalSurface/SpecificPolygonsOptions.vue +83 -103
- package/app/components/Viewer/Solid/EdgesOptions.vue +6 -9
- package/app/components/Viewer/Solid/PointsOptions.vue +6 -9
- package/app/components/Viewer/Solid/PolygonsOptions.vue +6 -9
- package/app/components/Viewer/Solid/SpecificPolyhedraOptions.vue +82 -105
- package/app/components/Viewer/TetrahedralSolid/TetrahedraOptions.vue +5 -5
- package/app/components/Viewer/TetrahedralSolid/TrianglesOptions.vue +5 -5
- package/app/components/Viewer/Tree/ObjectTree.vue +80 -89
- package/app/components/Viewer/TreeComponent.vue +43 -49
- package/app/components/Viewer/TreeObject.vue +48 -50
- package/app/components/Viewer/TriangulatedSurface/EdgesOptions.vue +6 -9
- package/app/components/Viewer/TriangulatedSurface/PointsOptions.vue +5 -5
- package/app/components/Viewer/TriangulatedSurface/TrianglesOptions.vue +5 -5
- package/app/components/Wrapper.vue +8 -8
- package/app/components/ZScaling.vue +18 -27
- package/app/composables/project_manager.js +57 -67
- package/app/composables/run_function_when_microservices_connected.js +8 -8
- package/app/plugins/auto_store_register.js +11 -13
- package/app/stores/app.js +118 -138
- package/app/stores/data.js +52 -68
- package/app/stores/data_style.js +36 -36
- package/app/stores/feedback.js +17 -20
- package/app/stores/geode.js +54 -55
- package/app/stores/hybrid_viewer.js +164 -177
- package/app/stores/infra.js +45 -55
- package/app/stores/lambda.js +26 -26
- package/app/stores/menu.js +78 -85
- package/app/stores/treeview.js +57 -65
- package/app/stores/viewer.js +92 -104
- package/app/utils/colormap.js +3 -3
- package/app/utils/config.js +16 -22
- package/app/utils/default_styles.js +50 -62
- package/app/utils/extension.js +44 -44
- package/app/utils/file_import_workflow.js +50 -64
- package/app/utils/local/app_mode.js +2 -2
- package/app/utils/local/cleanup.js +66 -72
- package/app/utils/local/microservices.js +61 -71
- package/app/utils/local/path.js +16 -19
- package/app/utils/local/scripts.js +22 -22
- package/app/utils/recaptcha.js +6 -6
- package/app/utils/server.js +21 -24
- package/app/utils/status.js +2 -2
- package/app/utils/treeview.js +4 -4
- package/app/utils/validate_schema.js +7 -7
- package/commitlint.config.js +2 -2
- package/eslint.config.js +4 -4
- package/internal/database/database.js +38 -46
- package/internal/database/extended_database.js +9 -10
- package/internal/database/tables/data.js +2 -3
- package/internal/database/tables/model_components.js +1 -1
- package/internal/database/tables/model_components_relation.js +1 -1
- package/internal/stores/data_style/mesh/cells/cell.js +47 -63
- package/internal/stores/data_style/mesh/cells/color.js +11 -16
- package/internal/stores/data_style/mesh/cells/common.js +6 -6
- package/internal/stores/data_style/mesh/cells/index.js +37 -47
- package/internal/stores/data_style/mesh/cells/textures.js +11 -12
- package/internal/stores/data_style/mesh/cells/vertex.js +47 -58
- package/internal/stores/data_style/mesh/cells/visibility.js +11 -16
- package/internal/stores/data_style/mesh/edges/color.js +11 -16
- package/internal/stores/data_style/mesh/edges/common.js +6 -6
- package/internal/stores/data_style/mesh/edges/edge.js +47 -63
- package/internal/stores/data_style/mesh/edges/index.js +38 -52
- package/internal/stores/data_style/mesh/edges/vertex.js +47 -58
- package/internal/stores/data_style/mesh/edges/visibility.js +11 -16
- package/internal/stores/data_style/mesh/edges/width.js +11 -16
- package/internal/stores/data_style/mesh/index.js +34 -34
- package/internal/stores/data_style/mesh/points/color.js +11 -16
- package/internal/stores/data_style/mesh/points/common.js +6 -6
- package/internal/stores/data_style/mesh/points/index.js +35 -49
- package/internal/stores/data_style/mesh/points/size.js +11 -16
- package/internal/stores/data_style/mesh/points/vertex.js +47 -58
- package/internal/stores/data_style/mesh/points/visibility.js +11 -16
- package/internal/stores/data_style/mesh/polygons/color.js +11 -16
- package/internal/stores/data_style/mesh/polygons/common.js +6 -6
- package/internal/stores/data_style/mesh/polygons/index.js +36 -45
- package/internal/stores/data_style/mesh/polygons/polygon.js +45 -56
- package/internal/stores/data_style/mesh/polygons/textures.js +11 -16
- package/internal/stores/data_style/mesh/polygons/vertex.js +47 -58
- package/internal/stores/data_style/mesh/polygons/visibility.js +11 -16
- package/internal/stores/data_style/mesh/polyhedra/color.js +11 -16
- package/internal/stores/data_style/mesh/polyhedra/common.js +6 -6
- package/internal/stores/data_style/mesh/polyhedra/index.js +29 -42
- package/internal/stores/data_style/mesh/polyhedra/polyhedron.js +43 -47
- package/internal/stores/data_style/mesh/polyhedra/vertex.js +47 -58
- package/internal/stores/data_style/mesh/polyhedra/visibility.js +11 -17
- package/internal/stores/data_style/model/blocks/color.js +21 -24
- package/internal/stores/data_style/model/blocks/common.js +6 -6
- package/internal/stores/data_style/model/blocks/index.js +13 -17
- package/internal/stores/data_style/model/blocks/visibility.js +21 -24
- package/internal/stores/data_style/model/corners/color.js +21 -24
- package/internal/stores/data_style/model/corners/common.js +6 -6
- package/internal/stores/data_style/model/corners/index.js +14 -18
- package/internal/stores/data_style/model/corners/visibility.js +21 -25
- package/internal/stores/data_style/model/edges/common.js +4 -4
- package/internal/stores/data_style/model/edges/index.js +7 -7
- package/internal/stores/data_style/model/edges/visibility.js +11 -15
- package/internal/stores/data_style/model/index.js +84 -100
- package/internal/stores/data_style/model/lines/color.js +21 -24
- package/internal/stores/data_style/model/lines/common.js +6 -6
- package/internal/stores/data_style/model/lines/index.js +13 -17
- package/internal/stores/data_style/model/lines/visibility.js +21 -24
- package/internal/stores/data_style/model/points/common.js +4 -4
- package/internal/stores/data_style/model/points/index.js +9 -9
- package/internal/stores/data_style/model/points/size.js +11 -11
- package/internal/stores/data_style/model/points/visibility.js +11 -15
- package/internal/stores/data_style/model/surfaces/color.js +21 -24
- package/internal/stores/data_style/model/surfaces/common.js +6 -6
- package/internal/stores/data_style/model/surfaces/index.js +14 -22
- package/internal/stores/data_style/model/surfaces/visibility.js +18 -22
- package/internal/stores/data_style/state.js +11 -11
- package/internal/utils/api_fetch.js +24 -34
- package/internal/utils/upload_file.js +19 -24
- package/internal/utils/viewer_call.js +23 -36
- package/nuxt.config.js +7 -11
- package/package.json +3 -3
- package/scripts/generate_geode_objects.js +14 -16
- package/server/api/app/kill.post.js +4 -4
- package/server/api/app/project_folder_path.post.js +11 -11
- package/server/api/app/run_back.post.js +12 -12
- package/server/api/app/run_viewer.post.js +12 -12
- package/server/api/extensions/run.post.js +34 -41
- package/server/api/extensions/upload.put.js +48 -62
- package/tests/integration/setup.js +43 -53
- package/tests/integration/stores/data_style/mesh/cells.nuxt.test.js +90 -116
- package/tests/integration/stores/data_style/mesh/edges.nuxt.test.js +81 -107
- package/tests/integration/stores/data_style/mesh/index.nuxt.test.js +38 -41
- package/tests/integration/stores/data_style/mesh/points.nuxt.test.js +85 -101
- package/tests/integration/stores/data_style/mesh/polygons.nuxt.test.js +89 -113
- package/tests/integration/stores/data_style/mesh/polyhedra.nuxt.test.js +81 -105
- package/tests/integration/stores/data_style/model/blocks.nuxt.test.js +56 -73
- package/tests/integration/stores/data_style/model/corners.nuxt.test.js +59 -76
- package/tests/integration/stores/data_style/model/edges.nuxt.test.js +39 -42
- package/tests/integration/stores/data_style/model/index.nuxt.test.js +31 -34
- package/tests/integration/stores/data_style/model/lines.nuxt.test.js +60 -73
- package/tests/integration/stores/data_style/model/points.nuxt.test.js +52 -55
- package/tests/integration/stores/data_style/model/surfaces.nuxt.test.js +59 -80
- package/tests/integration/stores/viewer.nuxt.test.js +35 -38
- package/tests/setup_indexeddb.js +2 -2
- package/tests/unit/components/CrsSelector.nuxt.test.js +28 -28
- package/tests/unit/components/ExtensionSelector.nuxt.test.js +33 -35
- package/tests/unit/components/FeedBack/ErrorsBanner.nuxt.test.js +23 -23
- package/tests/unit/components/FeedBack/Snackers.nuxt.test.js +18 -18
- package/tests/unit/components/FileSelector.nuxt.test.js +57 -59
- package/tests/unit/components/FileUploader.nuxt.test.js +35 -39
- package/tests/unit/components/Inspector/InspectionButton.nuxt.test.js +28 -28
- package/tests/unit/components/Inspector/ResultPanel.nuxt.test.js +22 -27
- package/tests/unit/components/Launcher.nuxt.test.js +20 -22
- package/tests/unit/components/MissingFilesSelector.nuxt.test.js +37 -37
- package/tests/unit/components/ObjectSelector.nuxt.test.js +62 -62
- package/tests/unit/components/PackagesVersions.nuxt.test.js +16 -16
- package/tests/unit/components/Step.nuxt.test.js +18 -19
- package/tests/unit/components/Stepper.nuxt.test.js +18 -18
- package/tests/unit/composables/api_fetch.nuxt.test.js +34 -36
- package/tests/unit/composables/project_manager.nuxt.test.js +93 -112
- package/tests/unit/composables/run_function_when_microservices_connected.nuxt.test.js +36 -36
- package/tests/unit/composables/upload_file.nuxt.test.js +27 -29
- package/tests/unit/plugins/project_load.nuxt.test.js +31 -33
- package/tests/unit/stores/app.nuxt.test.js +90 -92
- package/tests/unit/stores/feedback.nuxt.test.js +47 -57
- package/tests/unit/stores/geode.nuxt.test.js +111 -115
- package/tests/unit/stores/infra.nuxt.test.js +148 -148
- package/tests/unit/stores/lambda.nuxt.test.js +72 -74
- package/tests/unit/stores/treeview.nuxt.test.js +19 -21
- package/tests/unit/stores/viewer.nuxt.test.js +109 -122
- package/tests/unit/utils/recaptcha.nuxt.test.js +25 -29
- package/tests/unit/utils/validate_schema.nuxt.test.js +17 -17
- package/tests/utils.js +11 -11
- package/tests/vitest.config.js +9 -9
- package/vuetify_config.js +2 -2
- package/.prettierrc +0 -4
package/app/stores/data.js
CHANGED
|
@@ -1,53 +1,51 @@
|
|
|
1
1
|
// Third party imports
|
|
2
|
-
import { liveQuery } from "dexie"
|
|
3
|
-
import { useObservable } from "@vueuse/rxjs"
|
|
4
|
-
import viewer_schemas from "@geode/opengeodeweb-viewer/opengeodeweb_viewer_schemas.json"
|
|
2
|
+
import { liveQuery } from "dexie";
|
|
3
|
+
import { useObservable } from "@vueuse/rxjs";
|
|
4
|
+
import viewer_schemas from "@geode/opengeodeweb-viewer/opengeodeweb_viewer_schemas.json";
|
|
5
5
|
|
|
6
6
|
// Local imports
|
|
7
|
-
import { database } from "@ogw_internal/database/database.js"
|
|
8
|
-
import { useViewerStore } from "@ogw_front/stores/viewer"
|
|
7
|
+
import { database } from "@ogw_internal/database/database.js";
|
|
8
|
+
import { useViewerStore } from "@ogw_front/stores/viewer";
|
|
9
9
|
|
|
10
|
-
const viewer_generic_schemas = viewer_schemas.opengeodeweb_viewer.generic
|
|
10
|
+
const viewer_generic_schemas = viewer_schemas.opengeodeweb_viewer.generic;
|
|
11
11
|
|
|
12
12
|
export const useDataStore = defineStore("data", () => {
|
|
13
|
-
const viewerStore = useViewerStore()
|
|
13
|
+
const viewerStore = useViewerStore();
|
|
14
14
|
|
|
15
15
|
function item(id) {
|
|
16
|
-
return database.data.get(id)
|
|
16
|
+
return database.data.get(id);
|
|
17
17
|
}
|
|
18
18
|
|
|
19
19
|
function refItem(id) {
|
|
20
20
|
return useObservable(
|
|
21
21
|
liveQuery(() => database.data.get(id)),
|
|
22
22
|
{ initialValue: {} },
|
|
23
|
-
)
|
|
23
|
+
);
|
|
24
24
|
}
|
|
25
25
|
|
|
26
26
|
function refAllItems() {
|
|
27
27
|
return useObservable(
|
|
28
28
|
liveQuery(() => database.data.toArray()),
|
|
29
29
|
{ initialValue: [] },
|
|
30
|
-
)
|
|
30
|
+
);
|
|
31
31
|
}
|
|
32
32
|
|
|
33
33
|
async function formatedMeshComponents(modelId) {
|
|
34
|
-
const items = await database.model_components
|
|
35
|
-
.where({ id: modelId })
|
|
36
|
-
.toArray()
|
|
34
|
+
const items = await database.model_components.where({ id: modelId }).toArray();
|
|
37
35
|
const componentTitles = {
|
|
38
36
|
Corner: "Corners",
|
|
39
37
|
Line: "Lines",
|
|
40
38
|
Surface: "Surfaces",
|
|
41
39
|
Block: "Blocks",
|
|
42
|
-
}
|
|
40
|
+
};
|
|
43
41
|
|
|
44
|
-
const componentsByType = {}
|
|
42
|
+
const componentsByType = {};
|
|
45
43
|
for (const component_item of items) {
|
|
46
44
|
if (componentTitles[component_item.type]) {
|
|
47
45
|
if (!componentsByType[component_item.type]) {
|
|
48
|
-
componentsByType[component_item.type] = []
|
|
46
|
+
componentsByType[component_item.type] = [];
|
|
49
47
|
}
|
|
50
|
-
componentsByType[component_item.type].push(component_item)
|
|
48
|
+
componentsByType[component_item.type].push(component_item);
|
|
51
49
|
}
|
|
52
50
|
}
|
|
53
51
|
|
|
@@ -61,22 +59,20 @@ export const useDataStore = defineStore("data", () => {
|
|
|
61
59
|
title: meshComponent.name,
|
|
62
60
|
category: meshComponent.type,
|
|
63
61
|
})),
|
|
64
|
-
}))
|
|
62
|
+
}));
|
|
65
63
|
}
|
|
66
64
|
|
|
67
65
|
async function meshComponentType(modelId, geode_id) {
|
|
68
|
-
const component = await database.model_components
|
|
69
|
-
|
|
70
|
-
.first()
|
|
71
|
-
return component?.type
|
|
66
|
+
const component = await database.model_components.where({ id: modelId, geode_id }).first();
|
|
67
|
+
return component?.type;
|
|
72
68
|
}
|
|
73
69
|
|
|
74
70
|
async function registerObject(id) {
|
|
75
|
-
return await viewerStore.request(viewer_generic_schemas.register, { id })
|
|
71
|
+
return await viewerStore.request(viewer_generic_schemas.register, { id });
|
|
76
72
|
}
|
|
77
73
|
|
|
78
74
|
async function deregisterObject(id) {
|
|
79
|
-
return await viewerStore.request(viewer_generic_schemas.deregister, { id })
|
|
75
|
+
return await viewerStore.request(viewer_generic_schemas.deregister, { id });
|
|
80
76
|
}
|
|
81
77
|
|
|
82
78
|
function addItem(new_item) {
|
|
@@ -88,12 +84,12 @@ export const useDataStore = defineStore("data", () => {
|
|
|
88
84
|
visible: true,
|
|
89
85
|
created_at: new Date().toISOString(),
|
|
90
86
|
binary_light_viewable: new_item.binary_light_viewable,
|
|
91
|
-
}
|
|
92
|
-
return database.data.put(itemData)
|
|
87
|
+
};
|
|
88
|
+
return database.data.put(itemData);
|
|
93
89
|
}
|
|
94
90
|
|
|
95
91
|
function addComponents(new_item) {
|
|
96
|
-
const allComponents = []
|
|
92
|
+
const allComponents = [];
|
|
97
93
|
function addModelComponents(components) {
|
|
98
94
|
for (const component of components) {
|
|
99
95
|
allComponents.push({
|
|
@@ -102,16 +98,16 @@ export const useDataStore = defineStore("data", () => {
|
|
|
102
98
|
type: component.type,
|
|
103
99
|
viewer_id: component.viewer_id,
|
|
104
100
|
name: component.name,
|
|
105
|
-
})
|
|
101
|
+
});
|
|
106
102
|
}
|
|
107
103
|
}
|
|
108
|
-
addModelComponents(new_item.mesh_components)
|
|
109
|
-
addModelComponents(new_item.collection_components)
|
|
110
|
-
return database.model_components.bulkPut(allComponents)
|
|
104
|
+
addModelComponents(new_item.mesh_components);
|
|
105
|
+
addModelComponents(new_item.collection_components);
|
|
106
|
+
return database.model_components.bulkPut(allComponents);
|
|
111
107
|
}
|
|
112
108
|
|
|
113
109
|
function addComponentRelations(new_item) {
|
|
114
|
-
const relations = []
|
|
110
|
+
const relations = [];
|
|
115
111
|
function addModelComponentRelations(components, parent, type) {
|
|
116
112
|
for (const child of components) {
|
|
117
113
|
relations.push({
|
|
@@ -119,93 +115,81 @@ export const useDataStore = defineStore("data", () => {
|
|
|
119
115
|
parent,
|
|
120
116
|
child,
|
|
121
117
|
type,
|
|
122
|
-
})
|
|
118
|
+
});
|
|
123
119
|
}
|
|
124
120
|
}
|
|
125
121
|
for (const component of new_item.mesh_components) {
|
|
126
122
|
if (component.boundaries) {
|
|
127
|
-
addModelComponentRelations(
|
|
128
|
-
component.boundaries,
|
|
129
|
-
component.geode_id,
|
|
130
|
-
"boundary",
|
|
131
|
-
)
|
|
123
|
+
addModelComponentRelations(component.boundaries, component.geode_id, "boundary");
|
|
132
124
|
}
|
|
133
125
|
if (component.internals) {
|
|
134
|
-
addModelComponentRelations(
|
|
135
|
-
component.internals,
|
|
136
|
-
component.geode_id,
|
|
137
|
-
"internal",
|
|
138
|
-
)
|
|
126
|
+
addModelComponentRelations(component.internals, component.geode_id, "internal");
|
|
139
127
|
}
|
|
140
128
|
}
|
|
141
129
|
for (const component of new_item.collection_components) {
|
|
142
130
|
if (component.items) {
|
|
143
|
-
addModelComponentRelations(
|
|
144
|
-
component.items,
|
|
145
|
-
component.geode_id,
|
|
146
|
-
"collection",
|
|
147
|
-
)
|
|
131
|
+
addModelComponentRelations(component.items, component.geode_id, "collection");
|
|
148
132
|
}
|
|
149
133
|
}
|
|
150
|
-
return database.model_components_relation.bulkPut(relations)
|
|
134
|
+
return database.model_components_relation.bulkPut(relations);
|
|
151
135
|
}
|
|
152
136
|
|
|
153
137
|
async function deleteItem(id) {
|
|
154
|
-
await database.data.delete(id)
|
|
155
|
-
await deleteModelComponents(id)
|
|
138
|
+
await database.data.delete(id);
|
|
139
|
+
await deleteModelComponents(id);
|
|
156
140
|
}
|
|
157
141
|
|
|
158
142
|
async function updateItem(id, changes) {
|
|
159
|
-
await database.data.update(id, changes)
|
|
143
|
+
await database.data.update(id, changes);
|
|
160
144
|
}
|
|
161
145
|
|
|
162
146
|
async function deleteModelComponents(modelId) {
|
|
163
|
-
await database.model_components.where({ id: modelId }).delete()
|
|
164
|
-
await database.model_components_relation.where({ id: modelId }).delete()
|
|
147
|
+
await database.model_components.where({ id: modelId }).delete();
|
|
148
|
+
await database.model_components_relation.where({ id: modelId }).delete();
|
|
165
149
|
}
|
|
166
150
|
|
|
167
151
|
async function getMeshComponentGeodeIds(modelId, component_type) {
|
|
168
152
|
const components = await database.model_components
|
|
169
153
|
.where({ id: modelId, type: component_type })
|
|
170
|
-
.toArray()
|
|
171
|
-
return components.map((component) => component.geode_id)
|
|
154
|
+
.toArray();
|
|
155
|
+
return components.map((component) => component.geode_id);
|
|
172
156
|
}
|
|
173
157
|
|
|
174
158
|
async function getCornersGeodeIds(modelId) {
|
|
175
|
-
return await getMeshComponentGeodeIds(modelId, "Corner")
|
|
159
|
+
return await getMeshComponentGeodeIds(modelId, "Corner");
|
|
176
160
|
}
|
|
177
161
|
|
|
178
162
|
async function getLinesGeodeIds(modelId) {
|
|
179
|
-
return await getMeshComponentGeodeIds(modelId, "Line")
|
|
163
|
+
return await getMeshComponentGeodeIds(modelId, "Line");
|
|
180
164
|
}
|
|
181
165
|
|
|
182
166
|
async function getSurfacesGeodeIds(modelId) {
|
|
183
|
-
return await getMeshComponentGeodeIds(modelId, "Surface")
|
|
167
|
+
return await getMeshComponentGeodeIds(modelId, "Surface");
|
|
184
168
|
}
|
|
185
169
|
|
|
186
170
|
async function getBlocksGeodeIds(modelId) {
|
|
187
|
-
return await getMeshComponentGeodeIds(modelId, "Block")
|
|
171
|
+
return await getMeshComponentGeodeIds(modelId, "Block");
|
|
188
172
|
}
|
|
189
173
|
|
|
190
174
|
async function getMeshComponentsViewerIds(modelId, meshComponentGeodeIds) {
|
|
191
175
|
const components = await database.model_components
|
|
192
176
|
.where("[id+geode_id]")
|
|
193
177
|
.anyOf(meshComponentGeodeIds.map((geode_id) => [modelId, geode_id]))
|
|
194
|
-
.toArray()
|
|
195
|
-
return components.map((component) => component.viewer_id)
|
|
178
|
+
.toArray();
|
|
179
|
+
return components.map((component) => component.viewer_id);
|
|
196
180
|
}
|
|
197
181
|
|
|
198
182
|
async function exportStores() {
|
|
199
|
-
const items = await database.data.toArray()
|
|
200
|
-
return { items }
|
|
183
|
+
const items = await database.data.toArray();
|
|
184
|
+
return { items };
|
|
201
185
|
}
|
|
202
186
|
|
|
203
187
|
async function importStores(_snapshot) {
|
|
204
|
-
await clear()
|
|
188
|
+
await clear();
|
|
205
189
|
}
|
|
206
190
|
|
|
207
191
|
async function clear() {
|
|
208
|
-
await database.data.clear()
|
|
192
|
+
await database.data.clear();
|
|
209
193
|
}
|
|
210
194
|
|
|
211
195
|
return {
|
|
@@ -229,5 +213,5 @@ export const useDataStore = defineStore("data", () => {
|
|
|
229
213
|
exportStores,
|
|
230
214
|
importStores,
|
|
231
215
|
clear,
|
|
232
|
-
}
|
|
233
|
-
})
|
|
216
|
+
};
|
|
217
|
+
});
|
package/app/stores/data_style.js
CHANGED
|
@@ -1,78 +1,78 @@
|
|
|
1
|
-
import { getDefaultStyle } from "@ogw_front/utils/default_styles"
|
|
2
|
-
import { useDataStore } from "@ogw_front/stores/data"
|
|
3
|
-
import { useDataStyleStateStore } from "@ogw_internal/stores/data_style/state"
|
|
4
|
-
import { useMeshStyle } from "@ogw_internal/stores/data_style/mesh/index"
|
|
5
|
-
import { useModelStyle } from "@ogw_internal/stores/data_style/model/index"
|
|
1
|
+
import { getDefaultStyle } from "@ogw_front/utils/default_styles";
|
|
2
|
+
import { useDataStore } from "@ogw_front/stores/data";
|
|
3
|
+
import { useDataStyleStateStore } from "@ogw_internal/stores/data_style/state";
|
|
4
|
+
import { useMeshStyle } from "@ogw_internal/stores/data_style/mesh/index";
|
|
5
|
+
import { useModelStyle } from "@ogw_internal/stores/data_style/model/index";
|
|
6
6
|
|
|
7
7
|
export const useDataStyleStore = defineStore("dataStyle", () => {
|
|
8
|
-
const dataStyleState = useDataStyleStateStore()
|
|
9
|
-
const meshStyleStore = useMeshStyle()
|
|
10
|
-
const modelStyleStore = useModelStyle()
|
|
11
|
-
const dataStore = useDataStore()
|
|
8
|
+
const dataStyleState = useDataStyleStateStore();
|
|
9
|
+
const meshStyleStore = useMeshStyle();
|
|
10
|
+
const modelStyleStore = useModelStyle();
|
|
11
|
+
const dataStore = useDataStore();
|
|
12
12
|
|
|
13
13
|
function addDataStyle(id, geode_object) {
|
|
14
|
-
dataStyleState.styles[id] = getDefaultStyle(geode_object)
|
|
14
|
+
dataStyleState.styles[id] = getDefaultStyle(geode_object);
|
|
15
15
|
}
|
|
16
16
|
|
|
17
17
|
async function setVisibility(id, visibility) {
|
|
18
|
-
const item = await dataStore.item(id)
|
|
19
|
-
const viewer_type = item?.viewer_type
|
|
18
|
+
const item = await dataStore.item(id);
|
|
19
|
+
const viewer_type = item?.viewer_type;
|
|
20
20
|
if (!viewer_type) {
|
|
21
|
-
throw new Error(`Item not found or not loaded: ${id}`)
|
|
21
|
+
throw new Error(`Item not found or not loaded: ${id}`);
|
|
22
22
|
}
|
|
23
23
|
|
|
24
24
|
if (viewer_type === "mesh") {
|
|
25
|
-
return meshStyleStore.setMeshVisibility(id, visibility)
|
|
25
|
+
return meshStyleStore.setMeshVisibility(id, visibility);
|
|
26
26
|
}
|
|
27
27
|
if (viewer_type === "model") {
|
|
28
|
-
return modelStyleStore.setModelVisibility(id, visibility)
|
|
28
|
+
return modelStyleStore.setModelVisibility(id, visibility);
|
|
29
29
|
}
|
|
30
|
-
throw new Error("Unknown viewer_type")
|
|
30
|
+
throw new Error("Unknown viewer_type");
|
|
31
31
|
}
|
|
32
32
|
|
|
33
33
|
async function applyDefaultStyle(id) {
|
|
34
|
-
const item = await dataStore.item(id)
|
|
35
|
-
const viewer_type = item?.viewer_type
|
|
34
|
+
const item = await dataStore.item(id);
|
|
35
|
+
const viewer_type = item?.viewer_type;
|
|
36
36
|
if (!viewer_type) {
|
|
37
|
-
throw new Error(`Item not found or not loaded: ${id}`)
|
|
37
|
+
throw new Error(`Item not found or not loaded: ${id}`);
|
|
38
38
|
}
|
|
39
39
|
if (viewer_type === "mesh") {
|
|
40
|
-
return meshStyleStore.applyMeshStyle(id)
|
|
40
|
+
return meshStyleStore.applyMeshStyle(id);
|
|
41
41
|
}
|
|
42
42
|
if (viewer_type === "model") {
|
|
43
|
-
return modelStyleStore.applyModelStyle(id)
|
|
43
|
+
return modelStyleStore.applyModelStyle(id);
|
|
44
44
|
}
|
|
45
|
-
throw new Error(`Unknown viewer_type: ${viewer_type}`)
|
|
45
|
+
throw new Error(`Unknown viewer_type: ${viewer_type}`);
|
|
46
46
|
}
|
|
47
47
|
|
|
48
48
|
function exportStores() {
|
|
49
|
-
return { styles: dataStyleState.styles }
|
|
49
|
+
return { styles: dataStyleState.styles };
|
|
50
50
|
}
|
|
51
51
|
|
|
52
52
|
function importStores(snapshot) {
|
|
53
|
-
const stylesSnapshot = snapshot.styles || {}
|
|
53
|
+
const stylesSnapshot = snapshot.styles || {};
|
|
54
54
|
for (const id of Object.keys(dataStyleState.styles)) {
|
|
55
|
-
delete dataStyleState.styles[id]
|
|
55
|
+
delete dataStyleState.styles[id];
|
|
56
56
|
}
|
|
57
57
|
for (const [id, style] of Object.entries(stylesSnapshot)) {
|
|
58
|
-
dataStyleState.styles[id] = style
|
|
58
|
+
dataStyleState.styles[id] = style;
|
|
59
59
|
}
|
|
60
60
|
}
|
|
61
61
|
|
|
62
62
|
function applyAllStylesFromState() {
|
|
63
|
-
const ids = Object.keys(dataStyleState.styles || {})
|
|
63
|
+
const ids = Object.keys(dataStyleState.styles || {});
|
|
64
64
|
const promises = ids.map(async (id) => {
|
|
65
|
-
const meta = await dataStore.item(id)
|
|
66
|
-
const viewerType = meta?.viewer_type
|
|
67
|
-
const style = dataStyleState.styles[id]
|
|
65
|
+
const meta = await dataStore.item(id);
|
|
66
|
+
const viewerType = meta?.viewer_type;
|
|
67
|
+
const style = dataStyleState.styles[id];
|
|
68
68
|
if (style && viewerType === "mesh") {
|
|
69
|
-
return meshStyleStore.applyMeshStyle(id)
|
|
69
|
+
return meshStyleStore.applyMeshStyle(id);
|
|
70
70
|
}
|
|
71
71
|
if (style && viewerType === "model") {
|
|
72
|
-
return modelStyleStore.applyModelStyle(id)
|
|
72
|
+
return modelStyleStore.applyModelStyle(id);
|
|
73
73
|
}
|
|
74
|
-
})
|
|
75
|
-
return Promise.all(promises)
|
|
74
|
+
});
|
|
75
|
+
return Promise.all(promises);
|
|
76
76
|
}
|
|
77
77
|
|
|
78
78
|
return {
|
|
@@ -88,5 +88,5 @@ export const useDataStyleStore = defineStore("dataStyle", () => {
|
|
|
88
88
|
exportStores,
|
|
89
89
|
importStores,
|
|
90
90
|
applyAllStylesFromState,
|
|
91
|
-
}
|
|
92
|
-
})
|
|
91
|
+
};
|
|
92
|
+
});
|
package/app/stores/feedback.js
CHANGED
|
@@ -1,18 +1,17 @@
|
|
|
1
|
-
import { v4 as uuidv4 } from "uuid"
|
|
1
|
+
import { v4 as uuidv4 } from "uuid";
|
|
2
2
|
|
|
3
|
-
const MILLISECONDS_IN_SECOND = 1000
|
|
4
|
-
const DEFAULT_FEEDBACKS_TIMEOUT_SECONDS = 10
|
|
3
|
+
const MILLISECONDS_IN_SECOND = 1000;
|
|
4
|
+
const DEFAULT_FEEDBACKS_TIMEOUT_SECONDS = 10;
|
|
5
5
|
|
|
6
6
|
export const useFeedbackStore = defineStore("feedback", {
|
|
7
7
|
state: () => ({
|
|
8
8
|
feedbacks: [],
|
|
9
9
|
server_error: false,
|
|
10
|
-
feedbacks_timeout_miliseconds:
|
|
11
|
-
DEFAULT_FEEDBACKS_TIMEOUT_SECONDS * MILLISECONDS_IN_SECOND,
|
|
10
|
+
feedbacks_timeout_miliseconds: DEFAULT_FEEDBACKS_TIMEOUT_SECONDS * MILLISECONDS_IN_SECOND,
|
|
12
11
|
}),
|
|
13
12
|
actions: {
|
|
14
13
|
async add_error(code, route, name, description) {
|
|
15
|
-
const feedbackId = uuidv4()
|
|
14
|
+
const feedbackId = uuidv4();
|
|
16
15
|
await this.feedbacks.push({
|
|
17
16
|
id: feedbackId,
|
|
18
17
|
type: "error",
|
|
@@ -20,29 +19,27 @@ export const useFeedbackStore = defineStore("feedback", {
|
|
|
20
19
|
route,
|
|
21
20
|
name,
|
|
22
21
|
description,
|
|
23
|
-
})
|
|
22
|
+
});
|
|
24
23
|
setTimeout(() => {
|
|
25
|
-
this.delete_feedback(feedbackId)
|
|
26
|
-
}, this.feedbacks_timeout_miliseconds)
|
|
24
|
+
this.delete_feedback(feedbackId);
|
|
25
|
+
}, this.feedbacks_timeout_miliseconds);
|
|
27
26
|
},
|
|
28
27
|
async add_success(description) {
|
|
29
|
-
const feedbackId = uuidv4()
|
|
28
|
+
const feedbackId = uuidv4();
|
|
30
29
|
await this.feedbacks.push({
|
|
31
30
|
id: feedbackId,
|
|
32
31
|
type: "success",
|
|
33
32
|
description,
|
|
34
|
-
})
|
|
33
|
+
});
|
|
35
34
|
setTimeout(() => {
|
|
36
|
-
this.delete_feedback(feedbackId)
|
|
37
|
-
}, this.feedbacks_timeout_miliseconds)
|
|
35
|
+
this.delete_feedback(feedbackId);
|
|
36
|
+
}, this.feedbacks_timeout_miliseconds);
|
|
38
37
|
},
|
|
39
|
-
|
|
40
|
-
this.feedbacks = this.feedbacks.filter(
|
|
41
|
-
(feedback) => feedback.id !== feedbackId,
|
|
42
|
-
)
|
|
38
|
+
delete_feedback(feedbackId) {
|
|
39
|
+
this.feedbacks = this.feedbacks.filter((feedback) => feedback.id !== feedbackId);
|
|
43
40
|
},
|
|
44
|
-
|
|
45
|
-
this.server_error = false
|
|
41
|
+
delete_server_error() {
|
|
42
|
+
this.server_error = false;
|
|
46
43
|
},
|
|
47
44
|
},
|
|
48
|
-
})
|
|
45
|
+
});
|
package/app/stores/geode.js
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { Status } from "@ogw_front/utils/status"
|
|
2
|
-
import { api_fetch } from "@ogw_internal/utils/api_fetch"
|
|
3
|
-
import { appMode } from "@ogw_front/utils/local/app_mode"
|
|
4
|
-
import back_schemas from "@geode/opengeodeweb-back/opengeodeweb_back_schemas.json"
|
|
5
|
-
import { upload_file } from "@ogw_internal/utils/upload_file.js"
|
|
6
|
-
import { useAppStore } from "@ogw_front/stores/app"
|
|
7
|
-
import { useFeedbackStore } from "@ogw_front/stores/feedback"
|
|
8
|
-
import { useInfraStore } from "@ogw_front/stores/infra"
|
|
1
|
+
import { Status } from "@ogw_front/utils/status";
|
|
2
|
+
import { api_fetch } from "@ogw_internal/utils/api_fetch";
|
|
3
|
+
import { appMode } from "@ogw_front/utils/local/app_mode";
|
|
4
|
+
import back_schemas from "@geode/opengeodeweb-back/opengeodeweb_back_schemas.json";
|
|
5
|
+
import { upload_file } from "@ogw_internal/utils/upload_file.js";
|
|
6
|
+
import { useAppStore } from "@ogw_front/stores/app";
|
|
7
|
+
import { useFeedbackStore } from "@ogw_front/stores/feedback";
|
|
8
|
+
import { useInfraStore } from "@ogw_front/stores/infra";
|
|
9
9
|
|
|
10
|
-
const MILLISECONDS_IN_SECOND = 1000
|
|
11
|
-
const DEFAULT_PING_INTERVAL_SECONDS = 10
|
|
10
|
+
const MILLISECONDS_IN_SECOND = 1000;
|
|
11
|
+
const DEFAULT_PING_INTERVAL_SECONDS = 10;
|
|
12
12
|
|
|
13
13
|
export const useGeodeStore = defineStore("geode", {
|
|
14
14
|
state: () => ({
|
|
@@ -19,69 +19,68 @@ export const useGeodeStore = defineStore("geode", {
|
|
|
19
19
|
getters: {
|
|
20
20
|
protocol() {
|
|
21
21
|
if (useInfraStore().app_mode === appMode.CLOUD) {
|
|
22
|
-
return "https"
|
|
22
|
+
return "https";
|
|
23
23
|
}
|
|
24
|
-
return "http"
|
|
24
|
+
return "http";
|
|
25
25
|
},
|
|
26
26
|
port() {
|
|
27
27
|
if (useInfraStore().app_mode === appMode.CLOUD) {
|
|
28
|
-
return "443"
|
|
28
|
+
return "443";
|
|
29
29
|
}
|
|
30
|
-
return this.default_local_port
|
|
30
|
+
return this.default_local_port;
|
|
31
31
|
},
|
|
32
32
|
base_url() {
|
|
33
|
-
const infraStore = useInfraStore()
|
|
34
|
-
let geode_url = `${this.protocol}://${infraStore.domain_name}:${this.port}
|
|
33
|
+
const infraStore = useInfraStore();
|
|
34
|
+
let geode_url = `${this.protocol}://${infraStore.domain_name}:${this.port}`;
|
|
35
35
|
if (infraStore.app_mode === appMode.CLOUD) {
|
|
36
36
|
if (infraStore.ID === "") {
|
|
37
|
-
throw new Error("ID must not be empty in cloud mode")
|
|
37
|
+
throw new Error("ID must not be empty in cloud mode");
|
|
38
38
|
}
|
|
39
|
-
geode_url += `/${infraStore.ID}/geode
|
|
39
|
+
geode_url += `/${infraStore.ID}/geode`;
|
|
40
40
|
}
|
|
41
|
-
return geode_url
|
|
41
|
+
return geode_url;
|
|
42
42
|
},
|
|
43
43
|
is_busy() {
|
|
44
|
-
return this.request_counter > 0
|
|
44
|
+
return this.request_counter > 0;
|
|
45
45
|
},
|
|
46
46
|
},
|
|
47
47
|
actions: {
|
|
48
48
|
set_ping() {
|
|
49
|
-
this.ping()
|
|
49
|
+
this.ping();
|
|
50
50
|
setInterval(() => {
|
|
51
|
-
this.ping()
|
|
52
|
-
}, DEFAULT_PING_INTERVAL_SECONDS * MILLISECONDS_IN_SECOND)
|
|
51
|
+
this.ping();
|
|
52
|
+
}, DEFAULT_PING_INTERVAL_SECONDS * MILLISECONDS_IN_SECOND);
|
|
53
53
|
},
|
|
54
54
|
ping() {
|
|
55
|
-
const
|
|
56
|
-
const feedbackStore = useFeedbackStore()
|
|
55
|
+
const feedbackStore = useFeedbackStore();
|
|
57
56
|
return this.request(
|
|
58
57
|
back_schemas.opengeodeweb_back.ping,
|
|
59
58
|
{},
|
|
60
59
|
{
|
|
61
60
|
request_error_function: () => {
|
|
62
|
-
feedbackStore.$patch({ server_error: true })
|
|
63
|
-
|
|
61
|
+
feedbackStore.$patch({ server_error: true });
|
|
62
|
+
this.status = Status.NOT_CONNECTED;
|
|
64
63
|
},
|
|
65
64
|
response_function: () => {
|
|
66
|
-
feedbackStore.$patch({ server_error: false })
|
|
67
|
-
|
|
65
|
+
feedbackStore.$patch({ server_error: false });
|
|
66
|
+
this.status = Status.CONNECTED;
|
|
68
67
|
},
|
|
69
68
|
response_error_function: () => {
|
|
70
|
-
feedbackStore.$patch({ server_error: true })
|
|
71
|
-
|
|
69
|
+
feedbackStore.$patch({ server_error: true });
|
|
70
|
+
this.status = Status.NOT_CONNECTED;
|
|
72
71
|
},
|
|
73
72
|
},
|
|
74
|
-
)
|
|
73
|
+
);
|
|
75
74
|
},
|
|
76
75
|
start_request() {
|
|
77
|
-
this.request_counter += 1
|
|
76
|
+
this.request_counter += 1;
|
|
78
77
|
},
|
|
79
78
|
stop_request() {
|
|
80
|
-
this.request_counter -= 1
|
|
79
|
+
this.request_counter -= 1;
|
|
81
80
|
},
|
|
82
81
|
launch(args) {
|
|
83
|
-
console.log("[GEODE] Launching back microservice...", { args })
|
|
84
|
-
const appStore = useAppStore()
|
|
82
|
+
console.log("[GEODE] Launching back microservice...", { args });
|
|
83
|
+
const appStore = useAppStore();
|
|
85
84
|
const schema = {
|
|
86
85
|
$id: "/api/app/run_back",
|
|
87
86
|
methods: ["POST"],
|
|
@@ -89,26 +88,26 @@ export const useGeodeStore = defineStore("geode", {
|
|
|
89
88
|
properties: {},
|
|
90
89
|
required: [],
|
|
91
90
|
additionalProperties: true,
|
|
92
|
-
}
|
|
91
|
+
};
|
|
93
92
|
|
|
94
|
-
const params = { args }
|
|
93
|
+
const params = { args };
|
|
95
94
|
|
|
96
|
-
console.log("[GEODE] params", params)
|
|
95
|
+
console.log("[GEODE] params", params);
|
|
97
96
|
return appStore.request(schema, params, {
|
|
98
97
|
response_function: (response) => {
|
|
99
|
-
console.log(`[GEODE] Back launched on port ${response.port}`)
|
|
100
|
-
this.default_local_port = response.port
|
|
98
|
+
console.log(`[GEODE] Back launched on port ${response.port}`);
|
|
99
|
+
this.default_local_port = response.port;
|
|
101
100
|
},
|
|
102
|
-
})
|
|
101
|
+
});
|
|
103
102
|
},
|
|
104
103
|
connect() {
|
|
105
|
-
console.log("[GEODE] Connecting to geode microservice...")
|
|
106
|
-
this.set_ping()
|
|
107
|
-
return Promise.resolve()
|
|
104
|
+
console.log("[GEODE] Connecting to geode microservice...");
|
|
105
|
+
this.set_ping();
|
|
106
|
+
return Promise.resolve();
|
|
108
107
|
},
|
|
109
108
|
request(schema, params, callbacks = {}) {
|
|
110
|
-
console.log("[GEODE] Request:", schema.$id)
|
|
111
|
-
const start = Date.now()
|
|
109
|
+
console.log("[GEODE] Request:", schema.$id);
|
|
110
|
+
const start = Date.now();
|
|
112
111
|
|
|
113
112
|
return api_fetch(
|
|
114
113
|
this,
|
|
@@ -122,16 +121,16 @@ export const useGeodeStore = defineStore("geode", {
|
|
|
122
121
|
"in",
|
|
123
122
|
(Date.now() - start) / MILLISECONDS_IN_SECOND,
|
|
124
123
|
"s",
|
|
125
|
-
)
|
|
124
|
+
);
|
|
126
125
|
if (callbacks.response_function) {
|
|
127
|
-
await callbacks.response_function(response)
|
|
126
|
+
await callbacks.response_function(response);
|
|
128
127
|
}
|
|
129
128
|
},
|
|
130
129
|
},
|
|
131
|
-
)
|
|
130
|
+
);
|
|
132
131
|
},
|
|
133
132
|
upload(file, callbacks = {}) {
|
|
134
|
-
const route = back_schemas.opengeodeweb_back.upload_file.$id
|
|
133
|
+
const route = back_schemas.opengeodeweb_back.upload_file.$id;
|
|
135
134
|
return upload_file(
|
|
136
135
|
this,
|
|
137
136
|
{
|
|
@@ -141,16 +140,16 @@ export const useGeodeStore = defineStore("geode", {
|
|
|
141
140
|
{
|
|
142
141
|
...callbacks,
|
|
143
142
|
response_function: async (response) => {
|
|
144
|
-
console.log("[GEODE] Request completed:", route)
|
|
143
|
+
console.log("[GEODE] Request completed:", route);
|
|
145
144
|
if (callbacks.response_function) {
|
|
146
|
-
await callbacks.response_function(response)
|
|
145
|
+
await callbacks.response_function(response);
|
|
147
146
|
}
|
|
148
147
|
},
|
|
149
148
|
},
|
|
150
|
-
)
|
|
149
|
+
);
|
|
151
150
|
},
|
|
152
151
|
},
|
|
153
152
|
share: {
|
|
154
153
|
omit: ["status"],
|
|
155
154
|
},
|
|
156
|
-
})
|
|
155
|
+
});
|