mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2024-11-12 12:16:06 +08:00
24 lines
701 B
Text
24 lines
701 B
Text
<% query ||= nil %>
|
|
<% text = query.present? ? highlight(step.name, query.strip.split(/\s+/)) : step.name %>
|
|
|
|
<% if can_view_steps_in_protocol(step.protocol) %>
|
|
<% if step.protocol.in_module? %>
|
|
<% if target == :comment %>
|
|
<%= link_to protocols_my_module_path(step.protocol.my_module, ctarget: "step-panel-#{step.id}") do %>
|
|
<%= text %>
|
|
<% end %>
|
|
<% else %>
|
|
<a href="<%= protocols_my_module_path(step.protocol.my_module) %>">
|
|
<%= text %>
|
|
</a>
|
|
<% end %>
|
|
<% elsif can_edit_protocol(step.protocol) %>
|
|
<a href="<%= edit_protocol_path(step.protocol) %>">
|
|
<%= text %>
|
|
</a>
|
|
<% else %>
|
|
<%= text %>
|
|
<% end %>
|
|
<% else %>
|
|
<%= text %>
|
|
<% end %>
|