%= javascript_include_tag "raphael-min.js", :plugin => "redmine_better_gantt_chart" %> <%= javascript_include_tag "raphael.arrow.js", :plugin => "redmine_better_gantt_chart" %> <% @gantt.view = self %>
<%= gantt_zoom_link(@gantt, :in) %> <%= gantt_zoom_link(@gantt, :out) %>
<% end %> <%= error_messages_for 'query' %> <% if @query.valid? %> <% zoom = 1 @gantt.zoom.times { zoom = zoom * 2 } subject_width = 330 header_heigth = 18 headers_height = header_heigth show_weeks = false show_days = false # add show day show_day_num = false # <= ここ if @gantt.zoom >1 show_weeks = true headers_height = 2*header_heigth if @gantt.zoom > 2 show_days = true headers_height = 3*header_heigth end if @gantt.zoom > 3 # <= ここの条件を丸々追加 show_day_num = true headers_height = 4*header_heigth end end # Width of the entire chart g_width = (@gantt.date_to - @gantt.date_from + 1)*zoom @gantt.render(:top => headers_height + 8, :zoom => zoom, :g_width => g_width, :subject_width => subject_width) g_height = [(20 * (@gantt.number_of_rows + 6))+150, 206].max t_height = g_height + headers_height %> <% if @gantt.truncated %><%= l(:notice_gantt_chart_truncated, :max => @gantt.max_rows) %>
<% end %>
<%= @gantt.subjects %>
|
<%= link_to_content_update('« ' + l(:label_previous), params.merge(@gantt.params_previous)) %> | <%= link_to_content_update(l(:label_next) + ' »', params.merge(@gantt.params_next)) %> |