LT-102: Send a email which includes password reset link if Forgot Password option is selected

- Add custom Reset Password template  and reset password
- Show the first error instead showing all errors of invalidated input values in Sign Up and changePassword templates
This commit is contained in:
Aysel Afsar committed 2016-03-16 10:28:07 -04:00
1 parent 28ba53b328
commit a5d4c6d0eb
8 files changed
+205 -26

No files matched your search

@@ -30,13 +30,18 @@ Template.entrySignUp.helpers({
}
},
entryErrorMessages: function () {
var errorMessages = [];
Object.keys(ActiveEntry.errorMessages.all()).forEach(function(key) {
if (key !== "signInError" && ActiveEntry.errorMessages.get(key)) {
errorMessages.push(ActiveEntry.errorMessages.get(key));
}
var allErrorMessages = Object.keys(ActiveEntry.errorMessages.all()).filter(function(key) {
return key !== "signInError" && ActiveEntry.errorMessages.get(key);
});
return errorMessages;
if (allErrorMessages.length > 0) {
var errorMessage = ActiveEntry.errorMessages.get(allErrorMessages[0]);
if (errorMessage) {
return [errorMessage];
}
}
return;
},
getButtonText: function () {
if (ActiveEntry.errorMessages.get('signInError')) {