mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2024-11-14 21:24:54 +08:00
31 lines
1.1 KiB
Text
31 lines
1.1 KiB
Text
|
<h5 class="text-center"><%= t("projects.index.notifications_tab") %></h5>
|
||
|
<hr>
|
||
|
<ul class="no-style double-line content-notifications">
|
||
|
<% nr_of_notifications = 0 %>
|
||
|
<% @modules.each do |mod| %>
|
||
|
<% if mod.is_overdue? %>
|
||
|
<% nr_of_notifications += 1 %>
|
||
|
<% days = t("projects.index.module_overdue_days", count: mod.overdue_for_days) %>
|
||
|
<li class="notification alert-red">
|
||
|
<div class="date-time">
|
||
|
<span><%= l(mod.due_date, format: :full) %></span>
|
||
|
<span class="glyphicon glyphicon-alert"></span>
|
||
|
</div>
|
||
|
<%=t "projects.index.module_overdue_html", module: mod.name, days: days %>
|
||
|
</li>
|
||
|
<% elsif mod.is_one_day_prior? %>
|
||
|
<% nr_of_notifications += 1 %>
|
||
|
<li class="notification alert-yellow">
|
||
|
<div class="date-time">
|
||
|
<span><%= l(mod.due_date, format: :full) %></span>
|
||
|
<span class="glyphicon glyphicon-alert"></span>
|
||
|
</div>
|
||
|
<%=t "projects.index.module_one_day_due_html", module: mod.name %>
|
||
|
</li>
|
||
|
<% end %>
|
||
|
<% end %>
|
||
|
<% if nr_of_notifications == 0 %>
|
||
|
<li><em><%= t 'projects.index.no_notifications' %></em></li>
|
||
|
<% end %>
|
||
|
</ul>
|