added html_safe to fix gants_controller tests

pull/1186/head
Dennis Schmidt 12 years ago
parent db79d875c4
commit 165a09bc5a
  1. 14
      app/helpers/issues_helper.rb
  2. 4
      app/views/gantts/show.html.erb
  3. 6
      lib/redmine/helpers/gantt.rb

@ -43,13 +43,13 @@ module IssuesHelper
@cached_label_priority ||= l(:field_priority) @cached_label_priority ||= l(:field_priority)
@cached_label_project ||= l(:field_project) @cached_label_project ||= l(:field_project)
link_to_issue(issue) + "<br /><br />" + (link_to_issue(issue).html_safe + "<br /><br />".html_safe +
"<strong>#{@cached_label_project}</strong>: #{link_to_project(issue.project)}<br />" + "<strong>#{@cached_label_project}</strong>: #{link_to_project(issue.project)}<br />".html_safe +
"<strong>#{@cached_label_status}</strong>: #{h(issue.status.name)}<br />" + "<strong>#{@cached_label_status}</strong>: #{h(issue.status.name)}<br />".html_safe +
"<strong>#{@cached_label_start_date}</strong>: #{format_date(issue.start_date)}<br />" + "<strong>#{@cached_label_start_date}</strong>: #{format_date(issue.start_date)}<br />".html_safe +
"<strong>#{@cached_label_due_date}</strong>: #{format_date(issue.due_date)}<br />" + "<strong>#{@cached_label_due_date}</strong>: #{format_date(issue.due_date)}<br />".html_safe +
"<strong>#{@cached_label_assigned_to}</strong>: #{h(issue.assigned_to)}<br />" + "<strong>#{@cached_label_assigned_to}</strong>: #{h(issue.assigned_to)}<br />".html_safe +
"<strong>#{@cached_label_priority}</strong>: #{h(issue.priority.name)}" "<strong>#{@cached_label_priority}</strong>: #{h(issue.priority.name)}".html_safe).html_safe
end end
# TODO: deprecate and/or remove # TODO: deprecate and/or remove

@ -81,7 +81,7 @@ t_height = g_height + headers_height
<div style="right:-2px;width:<%= subject_width %>px;height:<%= t_height %>px;border-left: 1px solid #c0c0c0;overflow:hidden;" class="gantt_hdr"></div> <div style="right:-2px;width:<%= subject_width %>px;height:<%= t_height %>px;border-left: 1px solid #c0c0c0;overflow:hidden;" class="gantt_hdr"></div>
<div class="gantt_subjects"> <div class="gantt_subjects">
<%= @gantt.subjects %> <%= @gantt.subjects.html_safe %>
</div> </div>
</div> </div>
@ -161,7 +161,7 @@ if show_days
end end
end %> end %>
<%= @gantt.lines %> <%= @gantt.lines.html_safe %>
<% <%
# #

@ -718,9 +718,9 @@ module Redmine
style = "position: absolute;top:#{params[:top]}px;left:#{params[:indent]}px;" style = "position: absolute;top:#{params[:top]}px;left:#{params[:indent]}px;"
style << "width:#{params[:subject_width] - params[:indent]}px;" if params[:subject_width] style << "width:#{params[:subject_width] - params[:indent]}px;" if params[:subject_width]
output = view.content_tag 'div', subject, :class => options[:css], :style => style, :title => options[:title] output = view.content_tag 'div', subject.html_safe, :class => options[:css], :style => style, :title => options[:title]
@subjects << output @subjects << output.html_safe
output output.html_safe
end end
def pdf_subject(params, subject, options={}) def pdf_subject(params, subject, options={})

Loading…
Cancel
Save