"#id" patterns are turned into links to issues in descriptions and commit messages
git-svn-id: http://redmine.rubyforge.org/svn/trunk@274 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
32782a7f9f
commit
2e31311e3c
|
@ -93,7 +93,9 @@ module ApplicationHelper
|
||||||
end
|
end
|
||||||
|
|
||||||
def textilizable(text)
|
def textilizable(text)
|
||||||
(Setting.text_formatting == 'textile') && (ActionView::Helpers::TextHelper.method_defined? "textilize") ? RedCloth.new(h(text)).to_html : simple_format(auto_link(h(text)))
|
text = (Setting.text_formatting == 'textile') && (ActionView::Helpers::TextHelper.method_defined? "textilize") ? RedCloth.new(h(text)).to_html : simple_format(auto_link(h(text)))
|
||||||
|
# turn "#id" patterns into links to issues
|
||||||
|
text = text.gsub(/#(\d+)([^;\d])/, "<a href='/issues/show/\\1'>#\\1</a>\\2")
|
||||||
end
|
end
|
||||||
|
|
||||||
def error_messages_for(object_name, options = {})
|
def error_messages_for(object_name, options = {})
|
||||||
|
|
Loading…
Reference in New Issue