From 2b12d31fb8e6d2c2707672ce8e7b54f31f9ee6b3 Mon Sep 17 00:00:00 2001 From: z9hang Date: Mon, 19 May 2014 11:02:07 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8E=BB=E9=99=A4=E7=BD=91=E7=AB=99=E4=B8=AD?= =?UTF-8?q?=E7=9A=84=E9=82=AE=E7=AE=B1=E5=9C=B0=E5=9D=80=E6=98=BE=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/layouts/base_users.html.erb | 5 ++++- app/views/mailer/journals_for_message_add.html.erb | 2 +- app/views/mailer/journals_for_message_add.text.erb | 2 +- app/views/users/show_old.html.erb | 4 +++- 4 files changed, 9 insertions(+), 4 deletions(-) diff --git a/app/views/layouts/base_users.html.erb b/app/views/layouts/base_users.html.erb index 5c6f2452..1220a529 100644 --- a/app/views/layouts/base_users.html.erb +++ b/app/views/layouts/base_users.html.erb @@ -66,7 +66,7 @@ <%= link_to(l(:label_user_edit), my_account_path(@user)) if User.current %> <% end %> - + <% messages_count = @user.messages.count %> <% messages_score = messages_count * 0.05%> @@ -158,9 +158,12 @@ <%= l(:label_user_login) %>:<%= format_time(@user.last_login_on) %> + <% if User.current == @user %> + <%= l(:label_user_mail) %>:<%= mail_to(h(@user.mail), nil, :encode => 'javascript') %> + <% end %> <% unless @user.user_extensions.nil? %> diff --git a/app/views/mailer/journals_for_message_add.html.erb b/app/views/mailer/journals_for_message_add.html.erb index d6c0bc48..bd2a3644 100644 --- a/app/views/mailer/journals_for_message_add.html.erb +++ b/app/views/mailer/journals_for_message_add.html.erb @@ -1,4 +1,4 @@ -尊敬的用户,<%= @user %>(<%= @user.mail%>)给你留言了: +尊敬的用户,<%= @user %>给你留言了:
<%= @message %>

点击链接查看最新回复<%= link_to(@url, @url) %>

diff --git a/app/views/mailer/journals_for_message_add.text.erb b/app/views/mailer/journals_for_message_add.text.erb index ae405d06..5eb47ef3 100644 --- a/app/views/mailer/journals_for_message_add.text.erb +++ b/app/views/mailer/journals_for_message_add.text.erb @@ -1,3 +1,3 @@ -尊敬的用户,<%= @user %>(<%= @user.mail%>)给你留言了: +尊敬的用户,<%= @user %>给你留言了: <%= @message %> 点击链接查看最新回复<%= link_to(@url, @url) %> diff --git a/app/views/users/show_old.html.erb b/app/views/users/show_old.html.erb index 9ce6c160..d2de97b0 100644 --- a/app/views/users/show_old.html.erb +++ b/app/views/users/show_old.html.erb @@ -6,7 +6,7 @@