Correct handling of @Rational#to_s@ on ruby 1.9 #887

Contributed by Martin S
This commit is contained in:
Felix Schäfer 2012-04-04 09:36:58 +02:00
parent 6f064d3856
commit 0a7c6e6774
1 changed files with 1 additions and 1 deletions

View File

@ -98,7 +98,7 @@ 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
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), :title => "#{month_name(month_f.month)} #{month_f.year}"%>