|
|
|
@ -3,12 +3,14 @@ module NavigationItemsHelper
|
|
|
|
|
|
|
|
|
|
def primary_items(path, current_user) |
|
|
|
|
if current_user.support? |
|
|
|
|
[ |
|
|
|
|
nav_items = [ |
|
|
|
|
NavigationItem.new("Organisations", organisations_path, organisations_current?(path)), |
|
|
|
|
NavigationItem.new("Users", "/users", users_current?(path)), |
|
|
|
|
NavigationItem.new("Logs", case_logs_path, logs_current?(path)), |
|
|
|
|
NavigationItem.new("Supported housing", "/supported-housing", supported_housing_current?(path)), |
|
|
|
|
] |
|
|
|
|
|
|
|
|
|
Rails.env.production? ? nav_items[0...-1] : nav_items |
|
|
|
|
else |
|
|
|
|
[ |
|
|
|
|
NavigationItem.new("Logs", case_logs_path, logs_current?(path)), |
|
|
|
|