aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--app/controllers/admin/blog/settings_controller.rb9
-rw-r--r--config/locales/en.yml1
2 files changed, 9 insertions, 1 deletions
diff --git a/app/controllers/admin/blog/settings_controller.rb b/app/controllers/admin/blog/settings_controller.rb
index 52a7e83..541fa36 100644
--- a/app/controllers/admin/blog/settings_controller.rb
+++ b/app/controllers/admin/blog/settings_controller.rb
@@ -4,7 +4,14 @@ class Admin::Blog::SettingsController < Admin::BaseController
@recipients = BlogComment::Notification.recipients
if request.post?
- BlogComment::Notification.recipients == params[:recipients]
+ BlogComment::Notification.recipients = params[:recipients]
+ flash[:notice] = t('admin.blog.settings.notification_recipients.updated',
+ :recipients => BlogComment::Notification.recipients)
+ unless request.xhr? or from_dialog?
+ redirect_back_or_default(admin_blog_posts_path)
+ else
+ render :text => "<script type='text/javascript'>parent.window.location = '#{admin_blog_posts_path}';</script>"
+ end
end
end
diff --git a/config/locales/en.yml b/config/locales/en.yml
index 234299b..2cd53dc 100644
--- a/config/locales/en.yml
+++ b/config/locales/en.yml
@@ -49,6 +49,7 @@ en:
explanation: Every time someone comments on a blog post, Refinery sends out an email to say there is a new comment.
hint: When a new comment is added, Refinery will send an email notification to you.
example: "Enter your email address(es) like: jack@work.com, jill@office.com"
+ updated: Notification recipients have been set to '{{recipients}}'
submenu:
categories:
title: Categories