diff --git a/ui/src/admin/actions/chronograf.js b/ui/src/admin/actions/chronograf.js index be33dbeae..4a807a836 100644 --- a/ui/src/admin/actions/chronograf.js +++ b/ui/src/admin/actions/chronograf.js @@ -165,13 +165,14 @@ export const deleteUserAsync = ( ) => async dispatch => { dispatch(removeUser(user)) try { + console.log(user) await deleteUserAJAX(user) dispatch( publishAutoDismissingNotification( 'success', - `User removed from ${isAbsoluteDelete + `${user.name} has been removed from ${isAbsoluteDelete ? 'all organizations and deleted' - : 'organization'}: ${user.scheme}::${user.provider}::${user.name}` + : 'the current organization'}` ) ) } catch (error) { diff --git a/ui/src/shared/actions/auth.js b/ui/src/shared/actions/auth.js index 5e9913f4d..d5d2258eb 100644 --- a/ui/src/shared/actions/auth.js +++ b/ui/src/shared/actions/auth.js @@ -5,7 +5,7 @@ import {getLinksAsync} from 'shared/actions/links' import {publishAutoDismissingNotification} from 'shared/dispatchers' import {errorThrown} from 'shared/actions/errors' -import {LONG_NOTIFICATION_DISMISS_DELAY} from 'shared/constants' +import {NOTIFICATION_DISMISS_DELAY} from 'shared/constants' export const authExpired = auth => ({ type: 'AUTH_EXPIRED', @@ -96,7 +96,7 @@ export const meChangeOrganizationAsync = ( 'success', `Now logged in to '${me.currentOrganization .name}' as '${currentRole.name}'`, - LONG_NOTIFICATION_DISMISS_DELAY + NOTIFICATION_DISMISS_DELAY ) ) dispatch(meChangeOrganizationCompleted()) diff --git a/ui/src/shared/constants/index.js b/ui/src/shared/constants/index.js index d0b2e890b..63d64e782 100644 --- a/ui/src/shared/constants/index.js +++ b/ui/src/shared/constants/index.js @@ -386,8 +386,7 @@ export const HEARTBEAT_INTERVAL = 10000 // ms export const PRESENTATION_MODE_ANIMATION_DELAY = 0 // In milliseconds. export const PRESENTATION_MODE_NOTIFICATION_DELAY = 2000 // In milliseconds. -export const SHORT_NOTIFICATION_DISMISS_DELAY = 2000 // in milliseconds -export const LONG_NOTIFICATION_DISMISS_DELAY = 4000 // in milliseconds +export const NOTIFICATION_DISMISS_DELAY = 4000 // in milliseconds export const REVERT_STATE_DELAY = 1500 // ms diff --git a/ui/src/shared/dispatchers/index.js b/ui/src/shared/dispatchers/index.js index 3ffce9dbd..9a813330e 100644 --- a/ui/src/shared/dispatchers/index.js +++ b/ui/src/shared/dispatchers/index.js @@ -5,7 +5,7 @@ import { import {delayEnablePresentationMode} from 'shared/actions/app' import {PRESENTATION_MODE_NOTIFICATION_DELAY} from 'shared/constants' -import {SHORT_NOTIFICATION_DISMISS_DELAY} from 'shared/constants' +import {NOTIFICATION_DISMISS_DELAY} from 'shared/constants' export function delayDismissNotification(type, delay) { return dispatch => { @@ -16,7 +16,7 @@ export function delayDismissNotification(type, delay) { export const publishAutoDismissingNotification = ( type, message, - delay = SHORT_NOTIFICATION_DISMISS_DELAY + delay = NOTIFICATION_DISMISS_DELAY ) => dispatch => { dispatch(publishNotification(type, message)) dispatch(delayDismissNotification(type, delay))