diff options
author | Philip Arndt <parndt@gmail.com> | 2012-01-29 20:51:38 -0800 |
---|---|---|
committer | Philip Arndt <parndt@gmail.com> | 2012-01-29 20:51:38 -0800 |
commit | adcf66751c0bad7c85563e3575e0470973a165ca (patch) | |
tree | b3e5612be713b4276c568d7e5c5c9721a0347a84 /app/controllers/refinery/blog | |
parent | 44a059a47502eba436de440b542be76807501953 (diff) | |
parent | e46f0549c6aca4c9b32a4cec1aa7c70d65d7f910 (diff) | |
download | refinerycms-blog-adcf66751c0bad7c85563e3575e0470973a165ca.tar.gz refinerycms-blog-adcf66751c0bad7c85563e3575e0470973a165ca.tar.bz2 refinerycms-blog-adcf66751c0bad7c85563e3575e0470973a165ca.zip |
Merge pull request #189 from markstuart/rails-3-1
Fixes for notification settings access in refinery admin area
Diffstat (limited to 'app/controllers/refinery/blog')
-rw-r--r-- | app/controllers/refinery/blog/admin/posts_controller.rb | 2 | ||||
-rw-r--r-- | app/controllers/refinery/blog/admin/settings_controller.rb | 12 |
2 files changed, 7 insertions, 7 deletions
diff --git a/app/controllers/refinery/blog/admin/posts_controller.rb b/app/controllers/refinery/blog/admin/posts_controller.rb index 2ed2b98..f8d0f8f 100644 --- a/app/controllers/refinery/blog/admin/posts_controller.rb +++ b/app/controllers/refinery/blog/admin/posts_controller.rb @@ -63,7 +63,7 @@ module Refinery end end else - render :text => "<script>parent.window.location = '#{refinery_blog_admin_posts_url}';</script>" + render :text => "<script>parent.window.location = '#{main_app.refinery_blog_admin_posts_url}';</script>" end else unless request.xhr? diff --git a/app/controllers/refinery/blog/admin/settings_controller.rb b/app/controllers/refinery/blog/admin/settings_controller.rb index 34a8d00..e47fe7b 100644 --- a/app/controllers/refinery/blog/admin/settings_controller.rb +++ b/app/controllers/refinery/blog/admin/settings_controller.rb @@ -11,9 +11,9 @@ module Refinery flash[:notice] = t('updated', :scope => 'admin.blog.settings.notification_recipients', :recipients => Refinery::Blog::Comment::Notification.recipients) unless request.xhr? or from_dialog? - redirect_back_or_default(refinery_blog_admin_posts_path) + redirect_back_or_default(main_app.refinery_blog_admin_posts_path) else - render :text => "<script type='text/javascript'>parent.window.location = '#{refinery_blog_admin_posts_path}';</script>", + render :text => "<script type='text/javascript'>parent.window.location = '#{main_app.refinery_blog_admin_posts_path}';</script>", :layout => false end end @@ -22,7 +22,7 @@ module Refinery def moderation enabled = Refinery::Blog::Comment::Moderation.toggle! unless request.xhr? - redirect_back_or_default(refinery_blog_admin_posts_path) + redirect_back_or_default(main_app.refinery_blog_admin_posts_path) else render :json => {:enabled => enabled}, :layout => false @@ -32,7 +32,7 @@ module Refinery def comments enabled = Refinery::Blog::Comment.toggle! unless request.xhr? - redirect_back_or_default(refinery_blog_admin_posts_path) + redirect_back_or_default(main_app.refinery_blog_admin_posts_path) else render :json => {:enabled => enabled}, :layout => false @@ -42,7 +42,7 @@ module Refinery def teasers enabled = Refinery::Blog::Post.teaser_enabled_toggle! unless request.xhr? - redirect_back_or_default(refinery_blog_admin_posts_path) + redirect_back_or_default(main_app.refinery_blog_admin_posts_path) else render :json => {:enabled => enabled}, :layout => false @@ -52,4 +52,4 @@ module Refinery end end end -end +end
\ No newline at end of file |