Fix setting auth config from api in state
continuous-integration/drone/pr Build is passing
Details
continuous-integration/drone/pr Build is passing
Details
This commit is contained in:
parent
ab0c30013b
commit
2429ba4e4a
|
@ -1,3 +1,5 @@
|
|||
import Vue from 'vue'
|
||||
|
||||
import {CONFIG} from '../mutation-types'
|
||||
import {HTTPFactory} from '@/http-common'
|
||||
import {objectToCamelCase} from '@/helpers/case'
|
||||
|
@ -23,7 +25,7 @@ export default {
|
|||
caldavEnabled: false,
|
||||
auth: {
|
||||
local: {
|
||||
enabled: false,
|
||||
enabled: true,
|
||||
},
|
||||
openidConnect: {
|
||||
enabled: false,
|
||||
|
@ -47,7 +49,11 @@ export default {
|
|||
state.legal.imprintUrl = config.legal.imprint_url
|
||||
state.legal.privacyPolicyUrl = config.legal.privacy_policy_url
|
||||
state.caldavEnabled = config.caldav_enabled
|
||||
state.auth = objectToCamelCase(config.auth)
|
||||
const auth = objectToCamelCase(config.auth)
|
||||
state.auth.local.enabled = auth.local.enabled
|
||||
state.auth.openidConnect.enabled = auth.openidConnect.enabled
|
||||
state.auth.openidConnect.redirectUrl = auth.openidConnect.redirectUrl
|
||||
Vue.set(state.auth.openidConnect, 'providers', auth.openidConnect.providers)
|
||||
},
|
||||
},
|
||||
actions: {
|
||||
|
|
Reference in New Issue