diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2010-12-07 18:40:34 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2010-12-07 18:40:34 +0000 |
commit | b0a1a0400825de2c4c84d7a428e0427b600fa099 (patch) | |
tree | 18e10082ce49e31e76e8972fa3a67fc1f7aec384 /app/views | |
parent | bfa61c1ec49a7429d0eb667dc6a58b76660e2ec5 (diff) | |
download | redmine-b0a1a0400825de2c4c84d7a428e0427b600fa099.tar.gz redmine-b0a1a0400825de2c4c84d7a428e0427b600fa099.zip |
Gantt: iterate over all objects only once for html and pdf rendering (#6348).
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@4472 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/views')
-rw-r--r-- | app/views/gantts/show.html.erb | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/app/views/gantts/show.html.erb b/app/views/gantts/show.html.erb index 1509261e7..e0d7479f2 100644 --- a/app/views/gantts/show.html.erb +++ b/app/views/gantts/show.html.erb @@ -62,6 +62,8 @@ g_width = (@gantt.date_to - @gantt.date_from + 1)*zoom # Collect the number of issues on Versions g_height = [(20 * (@gantt.number_of_rows + 6))+150, 206].max t_height = g_height + headers_height + +@gantt.render(:headers_height => headers_height, :top => headers_height + 8, :zoom => zoom, :g_width => g_width) %> <table width="100%" style="border:0; border-collapse: collapse;"> <tr> @@ -72,7 +74,7 @@ t_height = g_height + headers_height <div style="right:-2px;width:<%= subject_width %>px;height:<%= t_height %>px;border-left: 1px solid #c0c0c0;overflow:hidden;" class="gantt_hdr"></div> <% top = headers_height + 8 %> -<%= @gantt.subjects(:headers_height => headers_height, :top => top, :g_width => g_width) %> +<%= @gantt.subjects %> </div> </td> @@ -153,7 +155,7 @@ end %> <% top = headers_height + 10 %> -<%= @gantt.lines(:top => top, :zoom => zoom, :g_width => g_width ) %> +<%= @gantt.lines %> <% # |