We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
A great gem! Unfortunately I have issues getting it to work properly for CRUD routes. Maybe you can point me to a solution.
I followed the advice in #37 to define the navigation structure. For example:
#config/navigation.rb data.item :arch_objects, 'arch_objects', arch_objects_path do |i| i.item :arch_object, 'new arch_object', new_arch_object_path i.item :arch_object, 'show arch_object', lambda {arch_object_path(@arch_object)}, :unless => lambda {@arch_object.nil?} i.item :arch_object, 'edit arch_object', lambda {edit_arch_object_path(@arch_object)}, :unless => lambda {@arch_object.nil?} end
Unfortunately with this setting everything works fine only for the edit and the show action. For the new action I get the following error:
No route matches {:action=>"show", :controller=>"arch_objects", :id=>nil}, missing required keys: [:id]
If I turn off the navigation for the edit and the show action, the new action view is displayed normally and the breadcrumb menu works.
#config/navigation.rb data.item :arch_objects, 'arch_objects', arch_objects_path do |i| i.item :arch_object, 'new arch_object', new_arch_object_path # i.item :arch_object, 'show arch_object', lambda {arch_object_path(@arch_object)}, :unless => lambda {@arch_object.nil?} # i.item :arch_object, 'edit arch_object', lambda {edit_arch_object_path(@arch_object)}, :unless => lambda {@arch_object.nil?} end
What's the reason for this strange behaviour? How is the new action related to the show action with simple-navigation activated?
simple-navigation
The text was updated successfully, but these errors were encountered:
Could you put together a repo with that setup to make it easier to track this down?
Sorry, something went wrong.
No branches or pull requests
A great gem! Unfortunately I have issues getting it to work properly for CRUD routes. Maybe you can point me to a solution.
I followed the advice in #37 to define the navigation structure. For example:
Unfortunately with this setting everything works fine only for the edit and the show action. For the new action I get the following error:
If I turn off the navigation for the edit and the show action, the new action view is displayed normally and the breadcrumb menu works.
What's the reason for this strange behaviour? How is the new action related to the show action with
simple-navigation
activated?The text was updated successfully, but these errors were encountered: