UX: after successfully submitting the forgot password form, show a new modal with a message and OK button

This commit is contained in:
Neil Lalonde 2015-11-20 17:49:17 -05:00
parent fa83e717f7
commit 4a49fbf44c

View file

@ -25,14 +25,17 @@ export default Ember.Controller.extend(ModalFunctionality, {
if (data.user_found === true) {
key += '_found';
}
self.set('accountEmailOrUsername', '');
bootbox.alert(I18n.t(key, {email: escaped, username: escaped}));
self.send("closeModal");
} else {
if (data.user_found === false) {
key += '_not_found';
extraClass = 'error';
}
if (data.user_found === false) {
key += '_not_found';
extraClass = 'error';
self.flash(I18n.t(key, {email: escaped, username: escaped}), extraClass);
}
self.flash(I18n.t(key, {email: escaped, username: escaped}), extraClass);
};
var fail = function(e) {