scinote-web/app/views/shared/_sidebar.html.erb

23 lines
759 B
Text
Raw Normal View History

2016-07-28 17:00:56 +08:00
<%= content_for :sidebar do %>
<% current_task ||= current_task || nil %>
<% current_experiment ||= current_experiment || current_task&.experiment || nil %>
<% current_project ||= current_experiment&.project || current_task&.experiment&.project || nil %>
<div id="slide-panel"
class="visible"
data-page="<%= page %>"
data-current-project="<%= current_project&.id %>"
data-current-experiment="<%= current_experiment&.id %>"
data-current-task="<%= current_task&.id %>">
2016-02-12 23:52:43 +08:00
<div class="tree">
<ul>
<% cache [current_user, current_team] do %>
<%= render partial: 'shared/sidebar/projects' %>
<% end %>
2016-02-12 23:52:43 +08:00
</ul>
</div>
</div>
<% end %>
<%= javascript_include_tag("sidebar") %>