How to set visible attribute to field with condition in rails_admin?

100 Views Asked by At

How is it possible in rails_admin set visible attribute depends on other objects fields? If i trying to use bindings[:object] all fields are nil, because in list we have something like Model.new on every record. The problem is only with list action. other actions working fine.

Im trying this:

field :public do
        visible do
          p bindings[:object]
        end
      end

Maybe there is a way to get access to object from list action? Thanks

0

There are 0 best solutions below