From 6f57e4285980d5c75adc054bdf6a3483f3588e21 Mon Sep 17 00:00:00 2001 From: Benedikt Kulmann Date: Thu, 2 Jul 2020 08:05:47 +0200 Subject: [PATCH] Use server URL from ocis-web config.json --- ui/app.js | 5 +---- ui/store/index.js | 5 +++-- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/ui/app.js b/ui/app.js index 4c2559db09..bad84494ff 100644 --- a/ui/app.js +++ b/ui/app.js @@ -12,10 +12,7 @@ const appInfo = { id: 'settings', icon: 'application', isFileEditor: false, - extensions: [], - config: { - url: 'https://localhost:9200' - } + extensions: [] } const routes = [ diff --git a/ui/store/index.js b/ui/store/index.js index 6b835b28c1..787e04fa12 100644 --- a/ui/store/index.js +++ b/ui/store/index.js @@ -48,6 +48,7 @@ const mutations = { } const actions = { + // Used by ocis-web. loadConfig ({ commit }, config) { commit('LOAD_CONFIG', config) }, @@ -60,7 +61,7 @@ const actions = { async fetchSettingsBundles ({ commit, dispatch, getters, rootGetters }) { injectAuthToken(rootGetters) const response = await BundleService_ListSettingsBundles({ - $domain: getters.config.url, + $domain: rootGetters.configuration.server, body: {} }) if (response.status === 201) { @@ -100,7 +101,7 @@ const actions = { async saveSettingsValue ({ commit, dispatch, getters, rootGetters }, payload) { injectAuthToken(rootGetters) const response = await ValueService_SaveSettingsValue({ - $domain: getters.config.url, + $domain: rootGetters.configuration.server, body: { settingsValue: payload }