File tree Expand file tree Collapse file tree 4 files changed +7
-10
lines changed Expand file tree Collapse file tree 4 files changed +7
-10
lines changed Original file line number Diff line number Diff line change @@ -10,15 +10,17 @@ export default function useMeshStyle() {
1010 const edgesStyleStore = useMeshEdgesStyle ( )
1111 const polygonsStyleStore = useMeshPolygonsStyle ( )
1212 const polyhedraStyleStore = useMeshPolyhedraStyle ( )
13+ const hybridViewerStore = useHybridViewerStore ( )
1314
1415 function setMeshVisibility ( id , visibility ) {
15- viewer_call (
16+ return viewer_call (
1617 {
1718 schema : viewer_schemas . opengeodeweb_viewer . mesh . visibility ,
1819 params : { id, visibility } ,
1920 } ,
2021 {
2122 response_function : ( ) => {
23+ hybridViewerStore . setVisibility ( id , visibility )
2224 dataStyleStore . styles [ id ] . visibility = visibility
2325 console . log ( "setMeshVisibility" , dataStyleStore . styles [ id ] . visibility )
2426 } ,
Original file line number Diff line number Diff line change @@ -9,13 +9,6 @@ export function useModelEdgesStyle() {
99 }
1010
1111 function setModelEdgesVisibility ( id , visibility ) {
12- // if (!dataStyleStore.styles[id]) {
13- // dataStyleStore.styles[id] = {}
14- // }
15- // if (!dataStyleStore.styles[id].edges) {
16- // dataStyleStore.styles[id].edges = {}
17- // }
18-
1912 return viewer_call (
2013 {
2114 schema : model_edges_schemas . visibility ,
Original file line number Diff line number Diff line change @@ -16,6 +16,7 @@ export default function useModelStyle() {
1616 const blocksStyleStore = useBlocksStyle ( )
1717 const modelEdgesStore = useModelEdgesStyle ( )
1818 const modelPointsStore = useModelPointsStyle ( )
19+ const hybridViewerStore = useHybridViewerStore ( )
1920
2021 /** Getters **/
2122 function modelVisibility ( id ) {
@@ -62,14 +63,15 @@ export default function useModelStyle() {
6263 }
6364
6465 function setModelVisibility ( id , visibility ) {
65- viewer_call (
66+ return viewer_call (
6667 {
6768 schema : viewer_schemas . opengeodeweb_viewer . model . visibility ,
6869 params : { id, visibility } ,
6970 } ,
7071 {
7172 response_function : ( ) => {
7273 dataStyleStore . styles [ id ] . visibility = visibility
74+ hybridViewerStore . setVisibility ( id , visibility )
7375 console . log ( "setModelVisibility" , visibility )
7476 } ,
7577 } ,
Original file line number Diff line number Diff line change @@ -43,7 +43,7 @@ export const useDataBaseStore = defineStore("dataBase", () => {
4343
4444 /** Actions **/
4545 async function registerObject ( id , file_name , viewer_object ) {
46- await viewer_call ( {
46+ return viewer_call ( {
4747 schema : viewer_schemas . opengeodeweb_viewer . generic . register ,
4848 params : { id, file_name, viewer_object } ,
4949 } )
You can’t perform that action at this time.
0 commit comments