issue功能优化
This commit is contained in:
parent
19c1a0d843
commit
7c76584e14
|
@ -60,13 +60,13 @@ class IssuesController < ApplicationController
|
|||
def index
|
||||
if params[:set_filter] != "1"
|
||||
@project_base_tag = (params[:project_id] || @issue.project) ? 'base_projects':'base'
|
||||
@issues = @project.issues.visible.all
|
||||
@issue_count = @issues.count
|
||||
@issues_filter = Issue.where(:project_id => @project.id).order('updated_on desc')
|
||||
@issue_count = @issues_filter.count
|
||||
@limit = 10
|
||||
@is_remote = true
|
||||
@issue_pages = Paginator.new @issue_count, @limit, params['page'] || 1
|
||||
@offset ||= @issue_pages.offset
|
||||
@issues = paginateHelper @issues, @limit
|
||||
@issues = paginateHelper @issues_filter, @limit
|
||||
# if params[:set_filter]
|
||||
# @set_filter = params[:set_filter]
|
||||
# end
|
||||
|
|
|
@ -80,14 +80,11 @@ 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))
|
||||
}
|
||||
# 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
|
||||
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
|
||||
div.respond-form .reply_btn{margin-left:565px;margin-top:5px;}
|
||||
div.recall_con{width:570px;}
|
||||
div.recall_con .reply_btn{margin-left:525px;margin-top:5px;}
|
||||
div.recall_con .reply_btn{margin-left:606px;margin-top:5px;}
|
||||
</style>
|
||||
<%= content_for(:header_tags) do %>
|
||||
<%= import_ke(enable_at: false, prettify: false, init_activity: false) %>
|
||||
|
|
|
@ -40,7 +40,7 @@
|
|||
<% end %>
|
||||
<li id="pro_st_tb_5" class="<%= show_memu == 'join_org' ? 'pro_st_hovertab' : 'pro_st_normaltab'%>" onclick="project_setting(5);">组织</li>
|
||||
<% if User.current.allowed_to?(:manage_versions, @project) %>
|
||||
<li id="pro_st_tb_4" class="<%= show_memu == 'manage_versions' ? 'pro_st_hovertab' : 'pro_st_normaltab'%>" onclick="project_setting(4);">版本</li>
|
||||
<li id="pro_st_tb_4" class="<%= show_memu == 'manage_versions' ? 'pro_st_hovertab' : 'pro_st_normaltab'%>" onclick="project_setting(4);"><%= l(:milestone) %></li>
|
||||
<% end %>
|
||||
<!--<li id="pro_st_tb_5" class="pro_st_normaltab" onclick="project_setting(5);">问题类别</li>-->
|
||||
<% if User.current.allowed_to?(:manage_repository, @project) %>
|
||||
|
|
|
@ -58,7 +58,7 @@
|
|||
<div class="roadmap_list">
|
||||
<p class="f14 mb5">»<%= l(:label_versions_description)%></p>
|
||||
<p><%=h version.description %></p>
|
||||
<p class="f14 mb5">»<%= link_to "导出:Excel", version_path(version, :format => 'xls') %></p>
|
||||
<!--p class="f14 mb5">»<%#= link_to "导出:Excel", version_path(version, :format => 'xls') %></p-->
|
||||
</div><!--roadmap_list end-->
|
||||
</div><!--roadmap_box end-->
|
||||
<% end %>
|
||||
|
|
Loading…
Reference in New Issue