From: Jean-Philippe Lang Date: Sun, 30 Nov 2008 14:31:01 +0000 (+0000) Subject: Adds link to user's account on issue history. X-Git-Tag: 0.8.0-RC1~29 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=0b2299c7d1efcba652ddd8ef91c6a50602ee5029;p=redmine.git Adds link to user's account on issue history. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@2073 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 5995187d7..064c13190 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -48,7 +48,7 @@ module ApplicationHelper # Display a link to user's account page def link_to_user(user) - user ? link_to(user, :controller => 'account', :action => 'show', :id => user) : 'Anonymous' + (user && !user.anonymous?) ? link_to(user, :controller => 'account', :action => 'show', :id => user) : 'Anonymous' end def link_to_issue(issue, options={}) diff --git a/app/views/issues/_history.rhtml b/app/views/issues/_history.rhtml index 2b30dadc5..13414fd84 100644 --- a/app/views/issues/_history.rhtml +++ b/app/views/issues/_history.rhtml @@ -3,7 +3,7 @@

<%= link_to "##{journal.indice}", :anchor => "note-#{journal.indice}" %>
<%= content_tag('a', '', :name => "note-#{journal.indice}")%> - <%= format_time(journal.created_on) %> - <%= journal.user.name %>

+ <%= format_time(journal.created_on) %> - <%= link_to_user(journal.user) %> <%= avatar(journal.user, :size => "32") %>