Is there a way to customize association name that is displayed on dashboard? Currently I see
All of your dashboards inherit from Administrate::BaseDashboard, which uses the following method to display resources:
def display_resource(resource)
"#{resource.class} ##{resource.id}"
end
Assuming you have an Author model with name attribute, you could add this to the AuthorDashboard to overwrite the default:
def display_resource(author)
author.name
end
That works. Thanks a lot. Found it commented out in dashboards code
Most helpful comment
All of your dashboards inherit from Administrate::BaseDashboard, which uses the following method to display resources:
Assuming you have an Author model with name attribute, you could add this to the AuthorDashboard to overwrite the default: