mirror of
https://github.com/koel/koel
synced 2024-12-24 19:43:06 +00:00
17 lines
367 B
TypeScript
17 lines
367 B
TypeScript
import { reactive } from 'vue'
|
|
import { httpService } from '@/services'
|
|
|
|
export const settingStore = {
|
|
state: reactive<Settings>({
|
|
media_path: ''
|
|
}),
|
|
|
|
init (settings: Settings) {
|
|
Object.assign(this.state, settings)
|
|
},
|
|
|
|
async update (settings: Settings) {
|
|
await httpService.put('settings', settings)
|
|
Object.assign(this.state, settings)
|
|
}
|
|
}
|