feat: social login providers with dynamic instances

This commit is contained in:
NGPixel
2020-08-30 01:36:17 -04:00
parent a7ddafd4aa
commit 32d67adee1
28 changed files with 147 additions and 107 deletions

View File

@@ -125,7 +125,7 @@
v-icon mdi-domain
v-list-item-content
v-list-item-title {{$t('admin:users.authProvider')}}
v-list-item-subtitle {{ user.providerKey }}
v-list-item-subtitle {{ user.providerName }} #[em.caption ({{ user.providerKey }})]
//- v-list-item-action
//- v-img(src='https://static.requarks.io/logo/wikijs.svg', alt='', contain, max-height='32', position='center right')
template(v-if='user.providerKey === `local`')
@@ -953,6 +953,7 @@ export default {
name
email
providerKey
providerName
providerId
location
jobTitle

View File

@@ -57,7 +57,7 @@
td {{ props.item.id }}
td: strong {{ props.item.name }}
td {{ props.item.email }}
td {{ props.item.providerKey }}
td {{ getStrategyName(props.item.providerKey) }}
td {{ props.item.createdAt | moment('from') }}
td
span(v-if='props.item.lastLoginAt') {{ props.item.lastLoginAt | moment('from') }}
@@ -131,6 +131,9 @@ export default {
icon: 'cached'
})
}
},
getStrategyName(key) {
return (_.find(this.strategies, ['key', key]) || {}).displayName || key
}
},
apollo: {

View File

@@ -161,7 +161,7 @@
autocomplete='off'
hide-details
)
v-card-chin
v-card-chin(v-if='user.providerKey === `local`')
v-spacer
v-btn.px-4(color='purple darken-4', dark, depressed, @click='changePassword', :loading='changePassLoading')
v-icon(left) mdi-progress-check