From 6c9d1dbb3d5a08674898450481400385543e4b03 Mon Sep 17 00:00:00 2001 From: yuri Date: Tue, 14 Jun 2016 11:43:31 +0300 Subject: [PATCH] fix notification sounds --- client/src/views/notification/badge.js | 6 +++++- client/src/views/popup-notification.js | 2 ++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/client/src/views/notification/badge.js b/client/src/views/notification/badge.js index 52dc8d2a32..3410815ef5 100644 --- a/client/src/views/notification/badge.js +++ b/client/src/views/notification/badge.js @@ -50,7 +50,9 @@ Espo.define('views/notification/badge', 'view', function (Dep) { }, setup: function () { - this.soundPath = this.getConfig().get('notificationSound') || this.soundPath; + this.soundPath = this.getBasePath() + (this.getConfig().get('notificationSound') || this.soundPath); + + this.notificationSoundsDisabled = this.getConfig().get('notificationSoundsDisabled'); this.once('remove', function () { if (this.timeout) { @@ -105,6 +107,8 @@ Espo.define('views/notification/badge', 'view', function (Dep) { }, playSound: function () { + if (this.notificationSoundsDisabled) return; + var html = '' + '