Module: Hyrax::BreadcrumbsForCollections
Instance Method Summary
collapse
#build_breadcrumbs, #default_trail, #trail_from_referer
Instance Method Details
#add_breadcrumb_for_action ⇒ Object
14
15
16
17
18
19
20
21
|
# File 'app/controllers/concerns/hyrax/breadcrumbs_for_collections.rb', line 14
def add_breadcrumb_for_action
case action_name
when 'edit'.freeze
add_breadcrumb I18n.t("hyrax.collection.browse_view"), collection_path(params["id"])
when 'show'.freeze
add_breadcrumb presenter.to_s, polymorphic_path(presenter)
end
end
|
#add_breadcrumb_for_controller ⇒ Object
10
11
12
|
# File 'app/controllers/concerns/hyrax/breadcrumbs_for_collections.rb', line 10
def add_breadcrumb_for_controller
add_breadcrumb I18n.t('hyrax.dashboard.my.collections'), hyrax.my_collections_path
end
|