added roadmap view

git-svn-id: http://redmine.rubyforge.org/svn/trunk@228 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang
2007-02-04 09:18:40 +00:00
parent 8c3dc34359
commit 879a614cde
11 changed files with 78 additions and 13 deletions
+14
View File
@@ -421,6 +421,20 @@ class ProjectsController < ApplicationController
@fixed_issues ||= []
end
def roadmap
@trackers = Tracker.find(:all, :conditions => ["is_in_roadmap=?", true], :order => 'position')
if request.get?
@selected_tracker_ids = @trackers.collect {|t| t.id.to_s }
else
@selected_tracker_ids = params[:tracker_ids].collect { |id| id.to_i.to_s } if params[:tracker_ids] and params[:tracker_ids].is_a? Array
end
@selected_tracker_ids ||= []
@versions = @project.versions.find(:all,
:conditions => [ "versions.effective_date>?", Date.today],
:order => "versions.effective_date ASC"
)
end
def activity
if params[:year] and params[:year].to_i > 1900
@year = params[:year].to_i