summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>2012-09-08 02:47:27 +0000
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>2012-09-08 02:47:27 +0000
commitd4fc347a8aaed8b4a8228c025f20bdf96a8a6a1e (patch)
treeaf1e02dcde1db4d384cd80673df156345064dd23
parentc25d1756233c3a27cf46c0f9820260b57ecc430e (diff)
downloadredmine-d4fc347a8aaed8b4a8228c025f20bdf96a8a6a1e.tar.gz
redmine-d4fc347a8aaed8b4a8228c025f20bdf96a8a6a1e.zip
gantt: use content_tag instead of html tag at days headers
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@10324 e93f8b46-1217-0410-a6f0-8f06a7374b81
-rw-r--r--app/views/gantts/show.html.erb18
1 files changed, 13 insertions, 5 deletions
diff --git a/app/views/gantts/show.html.erb b/app/views/gantts/show.html.erb
index 556be7d5e..d9a291795 100644
--- a/app/views/gantts/show.html.erb
+++ b/app/views/gantts/show.html.erb
@@ -201,11 +201,19 @@
wday = @gantt.date_from.cwday
%>
<% (@gantt.date_to - @gantt.date_from + 1).to_i.times do %>
- <% width = zoom - 1 %>
- <div style="left:<%= left %>px;top:37px;width:<%= width %>px;height:<%= height %>px;font-size:0.7em;<%= "background:#f1f1f1;" if wday > 5 %>"
- class="gantt_hdr">
- <%= day_letter(wday) %>
- </div>
+ <%
+ width = zoom - 1
+ style = ""
+ style += "left: #{left}px;"
+ style += "top:37px;"
+ style += "width: #{width}px;"
+ style += "height: #{height}px;"
+ style += "font-size:0.7em;"
+ style += 'background:#f1f1f1;' if wday > 5
+ %>
+ <%= content_tag(:div, :style => style, :class => "gantt_hdr") do %>
+ <%= day_letter(wday) %>
+ <% end %>
<%
left = left + width + 1
wday = wday + 1