mirror of
https://github.com/zulip/zulip.git
synced 2025-11-15 11:22:04 +00:00
Pass global stream notification settings between frontend and backend.
(imported from commit 28ec021e8e5166d3b270c81c5a4ad543d2185aa5)
This commit is contained in:
@@ -1084,6 +1084,17 @@ $(function () {
|
||||
var message = "Updated notification settings!";
|
||||
var result = $.parseJSON(xhr.responseText);
|
||||
|
||||
// Stream notification settings.
|
||||
|
||||
if (result.enable_stream_desktop_notifications !== undefined) {
|
||||
page_params.stream_desktop_notifications_enabled = result.enable_stream_desktop_notifications;
|
||||
}
|
||||
if (result.enable_stream_sounds !== undefined) {
|
||||
page_params.stream_sounds_enabled = result.enable_stream_sounds;
|
||||
}
|
||||
|
||||
// PM and @-mention notification settings.
|
||||
|
||||
if (result.enable_desktop_notifications !== undefined) {
|
||||
page_params.desktop_notifications_enabled = result.enable_desktop_notifications;
|
||||
}
|
||||
@@ -1099,6 +1110,8 @@ $(function () {
|
||||
page_params.enable_offline_push_notifications = result.enable_offline_push_notifications;
|
||||
}
|
||||
|
||||
// Other notification settings.
|
||||
|
||||
if (result.enable_digest_emails !== undefined) {
|
||||
page_params.enable_digest_emails = result.enable_digest_emails;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user