Use server URL from ocis-web config.json

This commit is contained in:
Benedikt Kulmann
2020-07-02 08:05:47 +02:00
parent 69693c5f8f
commit 6f57e42859
2 changed files with 4 additions and 6 deletions

View File

@@ -12,10 +12,7 @@ const appInfo = {
id: 'settings',
icon: 'application',
isFileEditor: false,
extensions: [],
config: {
url: 'https://localhost:9200'
}
extensions: []
}
const routes = [

View File

@@ -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
}