Merge branch 'rep_quality' of https://git.trustie.net/jacknudt/trustieforge into rep_quality

This commit is contained in:
huang 2016-09-22 13:42:24 +08:00
commit 775655b854
2 changed files with 9 additions and 2 deletions

View File

@ -53,7 +53,6 @@ class VersionsController < ApplicationController
@offset ||= @versions_pages.offset
@versions = @versions.slice(@offset, @limit)
#end by young
@issues_by_version = {}
if @selected_tracker_ids.any? && @versions.any?
@ -81,6 +80,14 @@ class VersionsController < ApplicationController
all
}
format.api
format.xls {
@issues = @version.fixed_issues.visible.
includes(:status, :tracker, :priority).
reorder("#{Tracker.table_name}.position, #{Issue.table_name}.id").
all
filename = "#{@version.name.to_s}_#{l(:label_issue_list_xls)}.xls"
send_data(issue_list_xls(@issues), :type => 'application/octet-stream', :filename => filename_for_content_disposition(filename))
}
end
end

View File

@ -57,10 +57,10 @@
<div class="roadmap_list">
<p class="f14 mb5">&#187;<%= l(:label_versions_description)%></p>
<p><%=h version.description %></p>
<p class="f14 mb5">&#187;<%= link_to "导出XLS", version_path(version, :format => 'xls') %></p>
</div><!--roadmap_list end-->
</div><!--roadmap_box end-->
<% end %>
<ul class="wlist" >
<%= pagination_links_full @versions_pages%>
</ul>