https://www.redmine.org/
https://www.redmine.org/favicon.ico?1679302129
2020-06-16T08:16:22Z
Redmine
Redmine - Defect #33601: Additional email addresses are not displayed in user profile page
https://www.redmine.org/issues/33601?journal_id=98224
2020-06-16T08:16:22Z
Go MAEDA
<ul></ul><p>The following code fixes the issue.</p>
<pre><code class="diff syntaxhl"><span class="gh">diff --git a/app/helpers/users_helper.rb b/app/helpers/users_helper.rb
index c9e4e198f..e773b9eee 100644
</span><span class="gd">--- a/app/helpers/users_helper.rb
</span><span class="gi">+++ b/app/helpers/users_helper.rb
</span><span class="p">@@ -60,6 +60,12 @@</span> module UsersHelper
end
end
+ def user_emails(user)
<span class="gi">+ emails = [user.mail]
+ emails += user.email_addresses.order(:id).where(:is_default => false).pluck(:address)
+ emails.map {|email| mail_to(email, nil)}.join(', ').html_safe
+ end
+
</span> def user_settings_tabs
tabs = [{:name => 'general', :partial => 'users/general', :label => :label_general},
{:name => 'memberships', :partial => 'users/memberships', :label => :label_project_plural}
<span class="gh">diff --git a/app/views/users/show.html.erb b/app/views/users/show.html.erb
index e97119bab..fabf91dae 100644
</span><span class="gd">--- a/app/views/users/show.html.erb
</span><span class="gi">+++ b/app/views/users/show.html.erb
</span><span class="p">@@ -9,7 +9,7 @@</span>
<ul>
<li><%=l(:field_login)%>: <%= @user.login %></li>
<% unless @user.pref.hide_mail %>
<span class="gd">- <li><%=l(:field_mail)%>: <%= mail_to(@user.mail, nil, :encode => 'javascript') %></li>
</span><span class="gi">+ <li><%=l(:field_mail)%>: <%= user_emails(@user) %></li>
</span> <% end %>
<% @user.visible_custom_field_values.each do |custom_value| %>
<% if !custom_value.value.blank? %>
</code></pre>
Redmine - Defect #33601: Additional email addresses are not displayed in user profile page
https://www.redmine.org/issues/33601?journal_id=98307
2020-06-22T14:16:18Z
Go MAEDA
<ul><li><strong>File</strong> <a href="/attachments/25597">33601.patch</a> <a class="icon-only icon-download" title="Download" href="/attachments/download/25597/33601.patch">33601.patch</a> added</li><li><strong>Target version</strong> set to <i>Candidate for next major release</i></li></ul><p>Attaching a patch.</p>
Redmine - Defect #33601: Additional email addresses are not displayed in user profile page
https://www.redmine.org/issues/33601?journal_id=98325
2020-06-23T09:54:50Z
Go MAEDA
<ul><li><strong>Target version</strong> changed from <i>Candidate for next major release</i> to <i>4.2.0</i></li></ul><p>Setting the target version to 4.2.0.</p>
Redmine - Defect #33601: Additional email addresses are not displayed in user profile page
https://www.redmine.org/issues/33601?journal_id=98390
2020-06-27T05:43:50Z
Go MAEDA
<ul><li><strong>Status</strong> changed from <i>New</i> to <i>Closed</i></li><li><strong>Assignee</strong> set to <i>Go MAEDA</i></li><li><strong>Resolution</strong> set to <i>Fixed</i></li></ul><p>Committed the patch.</p>