Client - display client secret after creation

This commit is contained in:
Sam
2022-06-07 09:47:36 +02:00
parent 03db8e8cd6
commit 78fe703494
6 changed files with 39 additions and 15 deletions

View File

@ -18,9 +18,11 @@ export const actions: ActionTree<IOAuth2State, IRootState> & IOAuth2Actions = {
.post('oauth/apps', payload)
.then((res) => {
if (res.data.status === 'created') {
context
.dispatch(OAUTH2_STORE.ACTIONS.GET_CLIENTS)
.then(() => router.push('/profile/apps'))
context.commit(
OAUTH2_STORE.MUTATIONS.SET_CLIENT,
res.data.data.client
)
router.push(`/profile/apps/${res.data.data.client.id}/created`)
} else {
handleError(context, null)
}