app/controllers/admin/base_controller.rb
# Locates the current controller within the navigation and sets the breadcrumb
Locates the current controller within the navigation and sets the breadcrumb
Locates the current controller within the navigation and sets the breadcrumb
def locate_self
      path = controller_path.gsub( /^admin\//, '' )
      if Rails.application.config.admin[:map].key?( path )
        @breadcrumb = Rails.application.config.admin[:map][path].deep_dup
      end
    end
def locate_self path = controller_path . gsub ( / ^admin \/ / , '' ) if Rails . application . config . admin [ :map ] . key? ( path ) @breadcrumb = Rails . application . config . admin [ :map ] [ path ] . deep_dup end end
Locates the current controller within the navigation and sets the breadcrumb
Locates the current controller within the navigation and sets the breadcrumb
# get our path # if we know about it, set a breadcrumb