1
0
mirror of https://github.com/meineerde/redmine.git synced 2025-12-29 11:49:37 +00:00

shorten long line at app/helpers/application_helper.rb

git-svn-id: http://svn.redmine.org/redmine/trunk@19825 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Toshi MARUYAMA 2020-06-16 11:45:39 +00:00
parent 51515332f4
commit d2b25ef7b1

View File

@ -426,10 +426,19 @@ module ApplicationHelper
if controller.controller_name == 'wiki' && controller.action_name == 'export'
href = "##{page.title}"
else
href = {:controller => 'wiki', :action => 'show', :project_id => page.project, :id => page.title, :version => nil}
href = {:controller => 'wiki', :action => 'show',
:project_id => page.project, :id => page.title, :version => nil}
end
content << link_to(h(page.pretty_title), href,
:title => (options[:timestamp] && page.updated_on ? l(:label_updated_time, distance_of_time_in_words(Time.now, page.updated_on)) : nil))
content <<
link_to(
h(page.pretty_title),
href,
:title => (if options[:timestamp] && page.updated_on
l(:label_updated_time, distance_of_time_in_words(Time.now, page.updated_on))
else
nil
end)
)
content << "\n" + render_page_hierarchy(pages, page.id, options) if pages[page.id]
content << "</li>\n"
end