# the request comes from the comparison page: let's compare the given snapshots
sids = get_params_as_array(:sids)
unless sids.empty?
- selected_snapshots = Snapshot.find(:all, :conditions => ['id in (?)', sids])
+ selected_snapshots = Snapshot.all(:conditions => ['id in (?)', sids])
# next loop is required to keep the order that was decided by the user and which comes from the "sids" parameter
sids.each do |id|
selected_snapshots.each do |s|
end
end
-end
\ No newline at end of file
+end
<tr class="<%= clazz -%>" id="row_<%= index -%>_<%= row_index -%>">
<td nowrap>
<% if resource.source_code? %>
- <a href="<%= url_for :controller => 'resource', :action => 'index', :id => resource.key, :period => params[:period], :metric => @metric ? @metric.id : nil, :rule => @rule ? @rule.id : @severity, :display_title => 'true' -%>"
+ <a href="<%= url_for :controller => 'resource', :action => 'index', :id => resource.key, :period => @period, :metric => @metric ? @metric.id : nil, :rule => @rule ? @rule.id : @severity, :display_title => 'true' -%>"
onclick="window.open(this.href,'resource-<%= resource.key.parameterize -%>','height=800,width=900,scrollbars=1,resizable=1');return false;"
id="popup-<%= resource.key.parameterize -%>"
target="_blank"><%= image_tag 'new-window-16.gif', :alt => message('new_window') -%></a>
selected_section = Navigation::SECTION_HOME
end
@project=@resource unless @project || selected_section==Navigation::SECTION_HOME
- period_param = "period=#{h(params[:period])}" if params[:period]
+ period_param = "period=#{u(params[:period])}" if params[:period]
%>
<div id="container">
<%= yield :header -%>