Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nestable_tree true is required #39

Open
vcavel opened this issue Oct 13, 2014 · 0 comments
Open

nestable_tree true is required #39

vcavel opened this issue Oct 13, 2014 · 0 comments

Comments

@vcavel
Copy link

vcavel commented Oct 13, 2014

Hi guys,

I have been struggling to make my tree work and I think that there is something missing in the README of the project!

I think that you forgot to mention that nestable_tree true is mandatory in the rails_admin.rb in order to have a fully functional drag and drop tree.

The full snippet for a tree would therefore be :

RailsAdmin.config do |config|
  config.actions do
    ...
  end

  config.model MyModel do
    nestable_tree({
      position_field: :position,
      max_depth: 3
    })

  nestable_tree true
  end
end

Whithout this line my tree was just acting weird, the hiearchy was not saved and nothing was really working as it should have. It would be nice to add it so someone else doesn't struggle like me :-).

@vcavel vcavel closed this as completed Oct 13, 2014
@vcavel vcavel reopened this Oct 13, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant