orbit-basic/app/helpers/admin_helper.rb

8 lines
259 B
Ruby
Raw Normal View History

2010-01-18 07:52:52 +00:00
module AdminHelper
def show_parent_items_link(parent_item)
@parent_items = @parent_item.ancestors.map{ |i| i.name }
2010-03-08 08:04:05 +00:00
( @parent_items.map{ |i| link_to(i, admin_items_path(:parent_name=>i) ) } << parent_item.name ).join("/").html_safe
2010-01-18 07:52:52 +00:00
end
end