Permalink
Browse files

support relative_url_root in primary nav

  • Loading branch information...
1 parent ff7a5c0 commit defbf6b33c153c95aaee5299143fc6a408a3087c Andrew Carpenter committed Jun 24, 2011
Showing with 2 additions and 2 deletions.
  1. +1 −1 lib/active_admin/views/header_renderer.rb
  2. +1 −1 lib/active_admin/views/tabs_renderer.rb
@@ -27,7 +27,7 @@ def utility_navigation
content_tag 'p', :id => "utility_nav" do
if current_active_admin_user?
content_tag(:span, display_name(current_active_admin_user), :class => "current_user") +
- link_to(I18n.t('active_admin.logout'), "/#{active_admin_application.default_namespace}/logout")
+ link_to(I18n.t('active_admin.logout'), "#{controller.config.relative_url_root}/#{active_admin_application.default_namespace}/logout")
end
end
end
@@ -32,7 +32,7 @@ def render_item(item)
unless item.children.blank?
link_to(item.name, item.url || "#") + render_nested_menu(item)
else
- link_to item.name, item.url
+ link_to item.name, controller.config.relative_url_root + item.url
end
end
end

0 comments on commit defbf6b

Please sign in to comment.