@metrics = Metric.by_keys(metrics)
@metric_to_choose = Metric.all.select {|m| m.display? && !@metrics.include?(m)}.sort_by(&:short_name)
-
- # UI breadcrumb and permalink
- unless @snapshots.empty?
- @permalink = url_for :controller => 'comparison', :action => 'index', :sids => @snapshots.map {|s| s.id.to_s}.join(','), :metrics => @metrics.map {|m| m.key}.join(',')
- end
end
def versions
<div id="crumbs">
<ul id="crumbs-ops">
- <% if displayed_resource %>
+ <% if displayed_resource && !@review %>
<li>
<%= link_to_favourite(displayed_resource) -%>
</li>
- <% end %>
- <% if @permalink %>
- <li>
- <a href="<%= @permalink -%>"><img src="<%= ApplicationController.root_context -%>/images/permalink.png" width="16" height="16" title="<%= message('permalink') -%>"/></a>
- </li>
- <% end %>
- <% if displayed_resource && has_role?(:admin, displayed_resource) && !displayed_resource.entity? %>
- <%= render 'layouts/menu_resource_settings' -%>
+ <% if has_role?(:admin, displayed_resource) && !displayed_resource.entity? %>
+ <%= render 'layouts/menu_resource_settings' -%>
+ <% end %>
<% end %>
</ul>
<ul id="bc">
<div id="crumbs">
<ul id="crumbs-ops">
- <% if displayed_resource %>
+ <% if displayed_resource && !@review %>
<li>
<%= link_to_favourite(displayed_resource) -%>
</li>
- <% end %>
- <% if !@review %>
- <li>
- <a href="<%= url_for(:overwrite_params => {:id => displayed_resource.key}) -%>"><img src="<%= ApplicationController.root_context -%>/images/permalink.png" width="16" height="16" title="<%= message('permalink') -%>"/></a>
- </li>
- <% end %>
- <% if displayed_resource && has_role?(:admin, displayed_resource) && !displayed_resource.entity? %>
- <%= render 'layouts/menu_resource_settings' -%>
+ <% if has_role?(:admin, displayed_resource) && !displayed_resource.entity? %>
+ <%= render 'layouts/menu_resource_settings' -%>
+ <% end %>
<% end %>
</ul>
<ul id="bc">