@geode/opengeodeweb-front 0.0.13 → 0.0.14
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/stores/cloud.js +19 -0
package/package.json
CHANGED
package/stores/cloud.js
CHANGED
|
@@ -9,6 +9,25 @@ export const use_cloud_store = defineStore('cloud', {
|
|
|
9
9
|
is_connexion_launched: false,
|
|
10
10
|
request_counter: 0
|
|
11
11
|
}),
|
|
12
|
+
getters: {
|
|
13
|
+
geode_url: (state) => {
|
|
14
|
+
const public_runtime_config = useRuntimeConfig().public
|
|
15
|
+
var geode_url = `${public_runtime_config.GEODE_PROTOCOL}://${public_runtime_config.API_URL}:${public_runtime_config.GEODE_PORT}`
|
|
16
|
+
if (process.env.NODE_ENV == 'production') {
|
|
17
|
+
geode_url = geode_url + `/${state.ID}`
|
|
18
|
+
// /!\ ADD /geode LATER /!\
|
|
19
|
+
}
|
|
20
|
+
return geode_url
|
|
21
|
+
},
|
|
22
|
+
viewer_url: (state) => {
|
|
23
|
+
const public_runtime_config = useRuntimeConfig().public
|
|
24
|
+
var viewer_url = `${public_runtime_config.VIEWER_PROTOCOL}://${public_runtime_config.API_URL}:${public_runtime_config.VIEWER_PORT}`
|
|
25
|
+
if (process.env.NODE_ENV == 'production') {
|
|
26
|
+
viewer_url = viewer_url + `/${state.ID}/viewer`
|
|
27
|
+
}
|
|
28
|
+
return viewer_url
|
|
29
|
+
},
|
|
30
|
+
},
|
|
12
31
|
actions: {
|
|
13
32
|
async create_connexion () {
|
|
14
33
|
if (this.is_connexion_launched) { return }
|