fix notifications again after recent changes

This commit is contained in:
Mario Vavti 2017-11-15 09:01:57 +01:00
parent 3c3c0ed342
commit f50ae07560

View File

@ -26,7 +26,6 @@
} }
</style> </style>
{{if $module == 'display'}}
<script> <script>
var notifications_parent; var notifications_parent;
$(document).ready(function() { $(document).ready(function() {
@ -44,6 +43,7 @@
}); });
}); });
{{if $module == 'display'}}
$(document).on('click', '.notification', function(e) { $(document).on('click', '.notification', function(e) {
var b64mid = $(this).data('b64mid'); var b64mid = $(this).data('b64mid');
var path = $(this)[0].pathname.substr(1,7); var path = $(this)[0].pathname.substr(1,7);
@ -60,11 +60,12 @@
liveUpdate(); liveUpdate();
if($('#notifications_wrapper').hasClass('fs')) if($('#notifications_wrapper').hasClass('fs'))
$('#notifications_wrapper').prependTo('#' + notifications_parent).removeClass('fs'); //var notifications_parent is defined in redbasic.js $('#notifications_wrapper').prependTo('#' + notifications_parent).removeClass('fs');
} }
}); });
</script>
{{/if}} {{/if}}
</script>
{{if $notifications}} {{if $notifications}}
<div id="notifications_wrapper"> <div id="notifications_wrapper">