summaryrefslogtreecommitdiffstats
path: root/app/views/gantts
diff options
context:
space:
mode:
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>2012-09-07 11:59:19 +0000
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>2012-09-07 11:59:19 +0000
commit621b15c923a7ffa3139514f165e88d87092b7a3a (patch)
tree6fae51b0e0a60c32a8f74622d9fdb1df706e6990 /app/views/gantts
parentd1eb07dd8bb4e6f2ee07b6997f9d0fd229f331dc (diff)
downloadredmine-621b15c923a7ffa3139514f165e88d87092b7a3a.tar.gz
redmine-621b15c923a7ffa3139514f165e88d87092b7a3a.zip
code layout cleanup gantt months headers
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@10311 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/views/gantts')
-rw-r--r--app/views/gantts/show.html.erb11
1 files changed, 7 insertions, 4 deletions
diff --git a/app/views/gantts/show.html.erb b/app/views/gantts/show.html.erb
index ad905925b..076b6c761 100644
--- a/app/views/gantts/show.html.erb
+++ b/app/views/gantts/show.html.erb
@@ -92,12 +92,14 @@ t_height = g_height + headers_height
#
# Months headers
#
+%>
+<%
month_f = @gantt.date_from
left = 0
height = (show_weeks ? header_heigth : header_heigth + g_height)
-@gantt.months.times do
- width = (((month_f >> 1) - month_f) * zoom - 1).to_i
- %>
+%>
+<% @gantt.months.times do %>
+ <% width = (((month_f >> 1) - month_f) * zoom - 1).to_i %>
<div style="left:<%= left %>px;width:<%= width %>px;height:<%= height %>px;" class="gantt_hdr">
<%= link_to h("#{month_f.year}-#{month_f.month}"),
@gantt.params.merge(:year => month_f.year, :month => month_f.month),
@@ -106,7 +108,8 @@ height = (show_weeks ? header_heigth : header_heigth + g_height)
<%
left = left + width + 1
month_f = month_f >> 1
-end %>
+ %>
+<% end %>
<%
#