Override @#url_for@ in AM to force generation of absolute links (#10251).

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9022 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Etienne Massip committed 2012-02-27 18:42:03 +00:00
1 parent 81554eae5a
commit 7056649a4b
11 files changed
+108 -73

No files matched your search

+5
View File
@@ -30,6 +30,11 @@ class Mailer < ActionMailer::Base
{ :host => h, :protocol => Setting.protocol }
end
def url_for(options)
options[:only_path] = false if options.is_a?(Hash)
super options
end
# Builds a tmail object used to email recipients of the added issue.
#
# Example:
+1 -1
View File
@@ -12,4 +12,4 @@
<% end %>
</ul>
<%= textilizable(issue, :description, :only_path => false) %>
<%= textilizable(issue, :description) %>
+1 -1
View File
@@ -1,3 +1,3 @@
<%= link_to(h(@document.title), @document_url) %> (<%=h @document.category.name %>)<br />
<br />
<%= textilizable(@document, :description, :only_path => false) %>
<%= textilizable(@document, :description) %>
+1 -1
View File
@@ -6,6 +6,6 @@
<% end %>
</ul>
<%= textilizable(@journal, :notes, :only_path => false) %>
<%= textilizable(@journal, :notes) %>
<hr />
<%= render :partial => "issue.html.erb", :locals => { :issue => @issue, :issue_url => @issue_url } %>
+1 -1
View File
@@ -1,4 +1,4 @@
<h1><%=h @message.board.project.name %> - <%=h @message.board.name %>: <%= link_to(h(@message.subject), @message_url) %></h1>
<em><%=h @message.author %></em>
<%= textilizable(@message, :content, :only_path => false) %>
<%= textilizable(@message, :content) %>
+1 -1
View File
@@ -1,4 +1,4 @@
<h1><%= link_to(h(@news.title), @news_url) %></h1>
<em><%=h @news.author.name %></em>
<%= textilizable(@news, :description, :only_path => false) %>
<%= textilizable(@news, :description) %>
+1 -1
View File
@@ -2,4 +2,4 @@
<p><%= l(:text_user_wrote, :value => h(@comment.author)) %></p>
<%= textilizable @comment, :comments, :only_path => false %>
<%= textilizable @comment, :comments %>
+1 -1
View File
@@ -2,7 +2,7 @@
<ul>
<% @issues.each do |issue| -%>
<li><%=h issue.project %> - <%=link_to(h("#{issue.tracker} ##{issue.id}"), :controller => 'issues', :action => 'show', :id => issue, :only_path => false)%>: <%=h issue.subject %></li>
<li><%=h issue.project %> - <%=link_to(h("#{issue.tracker} ##{issue.id}"), :controller => 'issues', :action => 'show', :id => issue)%>: <%=h issue.subject %></li>
<% end -%>
</ul>