mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2024-11-16 14:17:00 +08:00
32 lines
1.2 KiB
Text
32 lines
1.2 KiB
Text
<li class="activity-item">
|
|
<span class="activity-item-date">
|
|
<%= l activity.created_at, format: :full %>
|
|
</span>
|
|
<span class="activity-item-text">
|
|
<%= activity_truncate(activity.message) %>
|
|
<% if activity.my_module %>
|
|
[<%=t 'Project' %>:
|
|
<% if activity.my_module.experiment.project.name.length >
|
|
Constants::NAME_TRUNCATION_LENGTH %>
|
|
<div class="modal-tooltip">
|
|
<%= truncate(activity.my_module.experiment.project.name,
|
|
lenght: Constants::NAME_TRUNCATION_LENGTH).strip %>
|
|
<span class="modal-tooltiptext"><%= activity.my_module.experiment.project.name %></span>
|
|
</div>
|
|
<% else %>
|
|
<%= activity.my_module.experiment.project.name %>
|
|
<% end %>, <%=t 'Module' %>:
|
|
<% if activity.my_module.name.length >
|
|
Constants::NAME_TRUNCATION_LENGTH %>
|
|
<div class="modal-tooltip"><%= truncate(
|
|
activity.my_module.name,
|
|
lenght: Constants::NAME_TRUNCATION_LENGTH) %>
|
|
<span class="modal-tooltiptext"><%= activity.my_module.name %></span>
|
|
</div>
|
|
<% else %>
|
|
<%= activity.my_module.name %>
|
|
<% end %>
|
|
]
|
|
<% end %>
|
|
</span>
|
|
</li>
|