From 0ba7ef0560b13cded47926044d5ad02b90b3f4dd Mon Sep 17 00:00:00 2001 From: huang Date: Thu, 12 Mar 2015 15:13:41 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E9=82=AE=E7=AE=B1=E9=82=80?= =?UTF-8?q?=E8=AF=B7=E6=97=B6=EF=BC=8C=E9=82=AE=E4=BB=B6=E4=B8=BA=E7=A9=BA?= =?UTF-8?q?=E6=97=B6=E6=8F=90=E7=A4=BA=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/projects_controller.rb | 3 +-- app/views/projects/invite_members_by_mail.html.erb | 11 ++++++++++- config/locales/zh.yml | 2 +- 3 files changed, 12 insertions(+), 4 deletions(-) diff --git a/app/controllers/projects_controller.rb b/app/controllers/projects_controller.rb index f83580fba..4f84212b4 100644 --- a/app/controllers/projects_controller.rb +++ b/app/controllers/projects_controller.rb @@ -334,8 +334,7 @@ class ProjectsController < ApplicationController end def send_mail_to_member - - if !params[:mail].nil? && User.find_by_mail(params[:mail].to_s).nil? + if !params[:mail].blank? && User.find_by_mail(params[:mail].to_s).nil? email = params[:mail] Mailer.send_invite_in_project(email, @project, User.current).deliver @is_zhuce =false diff --git a/app/views/projects/invite_members_by_mail.html.erb b/app/views/projects/invite_members_by_mail.html.erb index 70628094b..e0ba05f18 100644 --- a/app/views/projects/invite_members_by_mail.html.erb +++ b/app/views/projects/invite_members_by_mail.html.erb @@ -1,3 +1,12 @@ +

邀请加入

@@ -9,7 +18,7 @@

发送邮件邀请新用户

- 输入好友邮箱地址,Trustie帮您免费发送! + 输入好友邮箱地址,Trustie会自动为该邮箱注册用户!

<%= render :partial => 'regested', locals: { :isregisted => false} %> diff --git a/config/locales/zh.yml b/config/locales/zh.yml index 76f14f0da..9ed58788d 100644 --- a/config/locales/zh.yml +++ b/config/locales/zh.yml @@ -181,7 +181,7 @@ zh: notice_successful_create: 创建成功 notice_successful_update: 更新成功 notice_successful_delete: 删除成功 - notice_registed_success: 该邮箱已被注册,请直接邀请注册用户 + notice_registed_success: 您输入的邮箱为空或者该邮箱已被注册! notice_failed_delete: 删除失败 notice_successful_connection: 连接成功 notice_successful_join: 加入成功