Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Rails ActiveAdmin: Incorrect breadcrumb

I have model called Part which is using ActiveAdmin, CRUD operation works fine but the breadcrumb is not generating properly. Here is what I am getting in the breadcrumb on the EDIT page

 Admin / Parts / #<Part:0xcd74ef0> / 

I am using "activeadmin", "0.5.0"

like image 324
Zahid Avatar asked Feb 13 '26 23:02

Zahid


1 Answers

In Active Admin for Custom breadcrumb

Try to define display_name in your Part model.

class Part < ActiveRecord::Base
  // Some Code
  def display_name
    "#{ id } #{ name }"
  end
end
like image 195
Rubyist Avatar answered Feb 21 '26 02:02

Rubyist



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!