feat(web): support desktop notifications, add global inbox polling

Fixes #1234, fixes #3382, fixes #4295
This commit is contained in:
Francis Lachapelle
2020-07-29 16:31:19 -04:00
parent 7efcb58b6e
commit 8205acc5d5
11 changed files with 394 additions and 169 deletions
@@ -55,6 +55,11 @@
});
};
this.onDesktopNotificationsChange = function() {
if (this.preferences.defaults.SOGoDesktopNotifications)
this.preferences.authorizeNotifications();
};
this.resetContactsCategories = function(form) {
this.preferences.defaults.SOGoContactsCategories = $window.defaultContactsCategories;
form.$setDirty();
@@ -466,7 +471,9 @@
if (this.passwords.newPasswordConfirmation && this.passwords.newPasswordConfirmation.length &&
this.passwords.newPassword != this.passwords.newPasswordConfirmation) {
form.newPasswordConfirmation.$setValidity('newPasswordMismatch', false);
} else {
return false;
}
else {
form.newPasswordConfirmation.$setValidity('newPasswordMismatch', true);
}
if (this.passwords.newPassword && this.passwords.newPassword.length > 0 &&