In rails admin, you can define a navigation label to a model and its children like so:
# in rails_admin.rb
config.model Order do
navigation_label 'Orders related'
end
config.model OrderProducts do
parent Order
end
Is there a way to add labels to the navigation menu without creating models (i.e. just for grouping)?
According to the wiki, you can append static links to the navigation like so:
RailsAdmin.config do |config|
config.navigation_static_links = {
'Google' => 'http://www.google.com'
}
end
If you're just looking to group them, you can namespace your models under a module, and then you will see your models grouped under the module name in the navigation. Like so: http://i.imgur.com/kxtgNqx.png
RailsAdmin.config do |config|
config.model 'Spree::Product' do
...
end
end
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With