Commit d6ffd9b1 authored by Robert Lyon's avatar Robert Lyon

Bug 1826956: Problem with unread mails

This patch fixes the js problem:
 - Marking read emails in inbox was not updating the status
 - Marking read emails in inbox block was not updating the status

Also fixes php problem:
 - Marking read user messages in the inbox block

behatnotneeded

Change-Id: Icba09033812a6dbdaf017561a11cb40cad5dc782
Signed-off-by: Robert Lyon's avatarRobert Lyon <robertl@catalyst.net.nz>
parent bfec8984
......@@ -171,8 +171,9 @@ jQuery(function($) {
notificationList.html(data.data.html);
}
else if (self) {
$(self).removeClass('panel-primary js-panel-unread').addClass('card');
$(self).removeClass('text-weight-bold js-card-unread').addClass('card');
$(self).find('.control').removeClass('control');
$(self).find('.unread').removeClass('unread'); // for inbox block
}
$('#selectall').attr('checked', false); // Need to uncheck bulk checkbox
}
......@@ -203,7 +204,7 @@ jQuery(function($) {
}
});
$('.js-panel-unread').on('show.bs.collapse', function(e) {
$('.js-card-unread').on('show.bs.collapse', function(e) {
markthisread(e, this, paginatorData);
});
}
......
......@@ -7,7 +7,7 @@
{foreach from=$items item=i}
<div class="has-attachment card collapsible list-group-item{if !$i->read} js-card-unread{/if}" data-requesturl="{$WWWROOT}module/multirecipientnotification/indexin.json.php">
{if $i->message}
<a class="collapsed link-block{if !$i->read} unread{/if}" data-toggle="collapse" href="#message_content_{$i->type}_{$i->id}" data-id="{$i->id}" aria-expanded="false">
<a class="collapsed link-block{if !$i->read} unread{/if}" data-toggle="collapse" href="#message_content_{$i->type}_{$i->id}" data-id="{$i->id}" data-list="{$i->table}" aria-expanded="false">
{if $i->type == 'usermessage'}
<span class="icon icon-envelope text-default left" role="presentation" aria-hidden="true"></span>
{elseif $i->type == 'institutionmessage'}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment