* chore: remove current_admin routes file * feat: move all the admin routes into the admin file * chore: remove conditionals for the sidebar and tabbed navbar * remove some more notes where we use the admin_restructure feature flag * chore: amend the tests now that the old routes and the admin_restructure flag are removed * chore: remove more references to the admin_restructure flag * chore: fix the tests * chore: remove sidebar_spec * chore: add slash back * chore: comment it out for now whilst I try and figure out why its not passing
13 lines
248 B
Ruby
13 lines
248 B
Ruby
module AdminHelper
|
|
def deduced_controller(request)
|
|
request.path.split("/").fourth
|
|
end
|
|
|
|
def deduced_scope(request)
|
|
request.path.split("/").third
|
|
end
|
|
|
|
def display_name(group_name)
|
|
group_name.to_s.tr("_", " ").titleize
|
|
end
|
|
end
|