2018-06-01 19:49:02 +08:00
|
|
|
<% if project.active_experiments.present? %>
|
2020-02-27 23:04:44 +08:00
|
|
|
<ul class="tree-child hidden" data-active="<%= project.id == current_project&.id %>" data-branch-id="pro<%= project.id %>">
|
2016-08-24 16:47:30 +08:00
|
|
|
<% project.active_experiments.each do |experiment| %>
|
2019-02-20 21:13:51 +08:00
|
|
|
<% cache [action_name, current_user, experiment] do %>
|
2020-02-27 23:04:44 +08:00
|
|
|
<li data-parent="candidate" class="branch <%= 'active' if experiment_page? && current_experiment == experiment %>">
|
2020-01-29 20:22:35 +08:00
|
|
|
<span class="tree-link line-wrap first-indent" title="<%= experiment.name %>">
|
2020-02-27 23:04:44 +08:00
|
|
|
<% if experiment.active_my_modules.any? %>
|
|
|
|
<i class="fas fa-caret-right tree-toggle"></i>
|
|
|
|
<% end %>
|
2018-06-01 19:49:02 +08:00
|
|
|
<%= link_to experiment.name,
|
|
|
|
experiment_action_to_link_to(experiment),
|
2020-01-29 20:22:35 +08:00
|
|
|
class: 'overview_exp_label line-wrap',
|
2020-02-27 23:04:44 +08:00
|
|
|
style: (current_experiment == experiment ? 'font-weight: bold' : ''),
|
2020-01-06 23:07:23 +08:00
|
|
|
data: { type: 'experiment', id: experiment.id }
|
2018-06-01 19:49:02 +08:00
|
|
|
%>
|
2020-02-27 23:04:44 +08:00
|
|
|
<% if experiment_page? && current_experiment == experiment && action_name =='canvas' %>
|
|
|
|
<a href="" class="canvas-center-on"><span class="fas fa-map-marker-alt"></span></a>
|
|
|
|
<% end %>
|
2016-08-03 22:09:45 +08:00
|
|
|
</span>
|
2020-02-27 23:04:44 +08:00
|
|
|
<%= render partial: 'shared/sidebar/my_modules', locals: {
|
|
|
|
experiment: experiment,
|
|
|
|
current_experiment: current_experiment,
|
|
|
|
current_task: current_task
|
|
|
|
} %>
|
2016-08-03 22:09:45 +08:00
|
|
|
</li>
|
|
|
|
<% end %>
|
2016-07-29 21:58:47 +08:00
|
|
|
<% end %>
|
2018-03-22 18:41:33 +08:00
|
|
|
</ul>
|
|
|
|
<% end %>
|