diff --git a/amadeus/static/js/socket.js b/amadeus/static/js/socket.js index c49689f..1262063 100644 --- a/amadeus/static/js/socket.js +++ b/amadeus/static/js/socket.js @@ -26,9 +26,10 @@ if (socket.readyState == WebSocket.OPEN) socket.onopen(); function muralNotificationPost(content) { var page = window.location.pathname, - render = (content.paths.indexOf(page) != -1); + render = (content.paths.indexOf(page) != -1), + is_resource = (page.indexOf("resource") != -1); - if ((render && page.indexOf(content.post_type) != -1) || (render && content.post_type == "general")) { + if ((render && page.indexOf(content.post_type) != -1) || (render && content.post_type == "general") || (render && is_resource)) { if (content.accordion) { var section = $(content.container); @@ -136,6 +137,7 @@ function muralNotificationMuralDelete(content) { function muralNotificationComment(content) { var page = window.location.pathname, render = (content.paths.indexOf(page) != -1), + is_resource = (page.indexOf("resource") != -1), checker = "general"; switch (content.post_type) { @@ -147,7 +149,7 @@ function muralNotificationComment(content) { break; } - if ((render && page.indexOf(checker) != -1) || (render && content.post_type == "generalpost" && page.indexOf("categories") == -1 && page.indexOf("subjects") == -1)) { + if ((render && page.indexOf(checker) != -1) || (render && content.post_type == "generalpost" && page.indexOf("categories") == -1 && page.indexOf("subjects") == -1) || (render && is_resource)) { var section = $(content.container); if (section.is(":visible") || section.is(":hidden")) { diff --git a/mural/templates/mural/resource_view.html b/mural/templates/mural/resource_view.html index c1aa188..9fdb9cd 100644 --- a/mural/templates/mural/resource_view.html +++ b/mural/templates/mural/resource_view.html @@ -17,10 +17,10 @@ {% subject_permissions request.user subject as has_subject_permissions %} {% if subject.visible %} -