mirror of
https://github.com/owntone/owntone-server.git
synced 2025-07-21 14:31:19 -04:00
[web] Change the settings API calls
This commit is contained in:
parent
a229474da7
commit
c34c5eb585
@ -1,10 +1,12 @@
|
||||
import api from '@/api'
|
||||
|
||||
const BASE_URL = './api/settings'
|
||||
|
||||
export default {
|
||||
state() {
|
||||
return api.get('./api/settings')
|
||||
return api.get(BASE_URL)
|
||||
},
|
||||
update(categoryName, option) {
|
||||
return api.put(`./api/settings/${categoryName}/${option.name}`, option)
|
||||
update(option) {
|
||||
return api.put(`${BASE_URL}/${option.category}/${option.name}`, option)
|
||||
}
|
||||
}
|
||||
|
@ -61,7 +61,7 @@ export default {
|
||||
value
|
||||
}
|
||||
settings
|
||||
.update(this.category, setting)
|
||||
.update(setting)
|
||||
.then(() => {
|
||||
window.clearTimeout(this.timerId)
|
||||
this.settingsStore.update(setting)
|
||||
|
Loading…
x
Reference in New Issue
Block a user