Isolate this engine to Refinery::Blog (which, according to my interpretation of the docs, is how it should be) and remove url hack now that resolve/refinerycms#1193 has been fixed.

This commit is contained in:
Philip Arndt 2012-01-10 17:19:28 +13:00
parent 889127a58c
commit 2a2fcca649

View file

@ -3,7 +3,7 @@ module Refinery
class Engine < Rails::Engine class Engine < Rails::Engine
include Refinery::Engine include Refinery::Engine
isolate_namespace Refinery isolate_namespace Refinery::Blog
engine_name :refinery_blog engine_name :refinery_blog
initializer "register refinerycms_blog plugin", :after => :set_routes_reloader do |app| initializer "register refinerycms_blog plugin", :after => :set_routes_reloader do |app|
@ -13,13 +13,7 @@ module Refinery
plugin.url = app.routes.url_helpers.refinery_admin_blog_posts_path plugin.url = app.routes.url_helpers.refinery_admin_blog_posts_path
plugin.menu_match = /refinery\/blog\/?(posts|comments|categories)?/ plugin.menu_match = /refinery\/blog\/?(posts|comments|categories)?/
plugin.activity = { plugin.activity = {
:class_name => :'refinery/blog/post', :class_name => :'refinery/blog/post'
# Workaround bug #1193 in refinerycms.
# Without this line, the route fragment generated by the Refinery's
# activity dashboard would be refinery_blog_admin_blog_posts_path,
# which does not exist.
:url => "refinery_admin_blog_post_path"
} }
end end
end end