mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2026-07-27 19:51:37 +00:00
Clean up server init and save sso settings
This commit is contained in:
parent
61bf30e08a
commit
4616ef91e6
5 changed files with 88 additions and 2912 deletions
|
|
@ -82,17 +82,17 @@ export default {
|
|||
user: {
|
||||
createNewUser: false,
|
||||
isActive: true,
|
||||
settings: {
|
||||
mobileOrderBy: 'recent',
|
||||
mobileOrderDesc: true,
|
||||
mobileFilterBy: 'all',
|
||||
orderBy: 'book.title',
|
||||
orderDesc: false,
|
||||
filterBy: 'all',
|
||||
playbackRate: 1,
|
||||
bookshelfCoverSize: 120,
|
||||
collapseSeries: false
|
||||
},
|
||||
// settings: {
|
||||
// mobileOrderBy: 'recent',
|
||||
// mobileOrderDesc: true,
|
||||
// mobileFilterBy: 'all',
|
||||
// orderBy: 'book.title',
|
||||
// orderDesc: false,
|
||||
// filterBy: 'all',
|
||||
// playbackRate: 1,
|
||||
// bookshelfCoverSize: 120,
|
||||
// collapseSeries: false
|
||||
// },
|
||||
permissions: {
|
||||
download: false,
|
||||
update: false,
|
||||
|
|
@ -106,7 +106,6 @@ export default {
|
|||
},
|
||||
watch: {
|
||||
SSOSettings(newVal, oldVal) {
|
||||
console.log('SSO Settings set', newVal, oldVal)
|
||||
if (newVal && !oldVal) {
|
||||
this.initSSOSettings()
|
||||
}
|
||||
|
|
@ -160,8 +159,14 @@ export default {
|
|||
methods: {
|
||||
saveSSOSettings() {
|
||||
this.updatingSSOSettings = true
|
||||
|
||||
var user = JSON.parse(JSON.stringify(this.user))
|
||||
var updatePayload = {
|
||||
oidc: { ...this.oidc },
|
||||
user
|
||||
}
|
||||
this.$store
|
||||
.dispatch('settings/updateSSOSettings', { oidc: this.oidc, user: this.user })
|
||||
.dispatch('settings/updateSSOSettings', updatePayload)
|
||||
.then((payload) => {
|
||||
console.log('Update SSO settings success', payload)
|
||||
this.updatingSSOSettings = false
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue