scinote-web/app/views/system_notifications/_notification.html.erb
aignatov-bio 35268252c8
After reading What’s new notification and reloading the page, gift status is unseen again [SCI 3051] (#1504)
* Change relative path to absolute to mark_as_read and make clickable whole system notification with hover effecr
2019-02-20 13:15:16 +01:00

26 lines
858 B
Plaintext

<%= link_to system_notification_path(notification.id, format: :json), class: "modal-system-notification", remote: true do %>
<div
class="system-notification"
data-new="<%= notification.seen_at ? 0 : 1 %>"
data-unread="<%= notification.read_at ? 0 : 1 %>"
data-system-notification-id="<%= notification.id %>"
>
<div class="status-block">
<div class="status-icon <%= notification.seen_at ? "seen" : "" %>">
<i class="fas fa-gift"></i>
</div>
</div>
<div class="body-block">
<div class="datetime">
<span><%= l(notification.last_time_changed_at, format: :full) %></span>
</div>
<h5 class="title">
<strong><%= notification.title %></strong>
</h5>
<div class="message">
<span><%= notification.description %></span>
</div>
</div>
</div>
<% end %>