summaryrefslogtreecommitdiffstats
path: root/app/views/common
diff options
context:
space:
mode:
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>2020-11-07 12:31:41 +0000
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>2020-11-07 12:31:41 +0000
commit56b354a3dc42fb54b81455bca263df2f57a22621 (patch)
treea07543999bb687a7ac1038ea727857b7411c7bb7 /app/views/common
parent0fca1c6066b798b0f85b198c36b2c684424de592 (diff)
downloadredmine-56b354a3dc42fb54b81455bca263df2f57a22621.tar.gz
redmine-56b354a3dc42fb54b81455bca263df2f57a22621.zip
not use html_safe in app/views/common/_calendar.html.erb
git-svn-id: http://svn.redmine.org/redmine/trunk@20292 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/views/common')
-rw-r--r--app/views/common/_calendar.html.erb20
1 files changed, 13 insertions, 7 deletions
diff --git a/app/views/common/_calendar.html.erb b/app/views/common/_calendar.html.erb
index 942fb3452..63cb43c97 100644
--- a/app/views/common/_calendar.html.erb
+++ b/app/views/common/_calendar.html.erb
@@ -11,9 +11,13 @@
</thead>
<tbody>
<tr>
-<% day = calendar.startdt
-while day <= calendar.enddt %>
-<%= ("<td class='week-number' title='#{ l(:label_week) }'>#{(day+(11-day.cwday)%7).cweek}</td>".html_safe) if day.cwday == calendar.first_wday %>
+<% day = calendar.startdt %>
+<% while day <= calendar.enddt %>
+ <% if day.cwday == calendar.first_wday %>
+ <td class='week-number' title='<%= l(:label_week) %>'>
+ <%= (day + (11 - day.cwday) % 7).cweek %>
+ </td>
+ <% end %>
<td class="<%= calendar_day_css_classes(calendar, day) %>">
<p class="day-num"><%= day.day %></p>
<% calendar.events_on(day).each do |i| %>
@@ -27,14 +31,16 @@ while day <= calendar.enddt %>
<% else %>
<span class="icon icon-package">
<%= "#{i.project} -" unless @project && @project == i.project %>
- <%= link_to_version i%>
+ <%= link_to_version i %>
</span>
<% end %>
<% end %>
</td>
-<%= '</tr><tr>'.html_safe if day.cwday==calendar.last_wday and day!=calendar.enddt %>
-<% day = day + 1
-end %>
+<% if day.cwday==calendar.last_wday and day!=calendar.enddt %>
+ </tr><tr>
+<% end %>
+<% day = day + 1 %>
+<% end %>
</tr>
</tbody>
</table>