2022-07-26 19:52:40 +08:00
|
|
|
<ul class="sidebar-branch">
|
2023-03-03 21:32:08 +08:00
|
|
|
<% if templates_view_mode_archived?(type: @type, protocol: @protocol) %>
|
2023-03-03 21:11:40 +08:00
|
|
|
<li class="sidebar-leaf">
|
|
|
|
<%= link_to protocols_path, class: "sidebar-link back-button" do %>
|
|
|
|
<%= t("protocols.index.back_to_active_protocols") %>
|
2022-12-05 20:32:05 +08:00
|
|
|
<% end %>
|
2023-03-03 21:11:40 +08:00
|
|
|
</li>
|
|
|
|
<% else %>
|
2022-09-14 21:13:13 +08:00
|
|
|
<li class="sidebar-leaf">
|
2023-03-03 21:11:40 +08:00
|
|
|
<i class="fas fa-caret-right toggle-branch collapsed"></i>
|
|
|
|
<%= link_to t('sidebar.templates.protocol_templates'),
|
|
|
|
protocols_path,
|
|
|
|
class: "sidebar-link #{'selected' if active == :protocol && params[:type] != 'archived'}" %>
|
|
|
|
<ul class="sidebar-branch">
|
|
|
|
<li class="sidebar-leaf">
|
|
|
|
<%= link_to protocols_path(type: :archived), class: "sidebar-link #{'selected' if active == :protocol && params[:type] == 'archived'}" do %>
|
|
|
|
<i class="fas fa-archive"></i>
|
|
|
|
<%= t("protocols.index.navigation.archive") %>
|
|
|
|
<% end %>
|
|
|
|
</ul>
|
2022-09-14 21:13:13 +08:00
|
|
|
</li>
|
2023-03-03 21:11:40 +08:00
|
|
|
<% if can_view_label_templates?(current_team) %>
|
|
|
|
<li class="sidebar-leaf">
|
|
|
|
<%= link_to t('sidebar.templates.label_templates'),
|
|
|
|
label_templates_path,
|
|
|
|
class: "sidebar-link #{'selected' if active == :label}" %>
|
|
|
|
</li>
|
|
|
|
<% end %>
|
2022-09-14 21:13:13 +08:00
|
|
|
<% end %>
|
2022-07-26 19:52:40 +08:00
|
|
|
</ul>
|