I created a new project to test your point. The following are the routes generated. In the case of machine, I have no problem with "machines/new", but "equipment/new" provides the exact-same error as before. So, the route generated by Rails creates ambiguity without my doing anything special.
map.resources :machines map.resources :equipment Your snide comment about BSAT is ignorant of the effort I've put into trying to solve this problem. I've been professionally programming for well over a decade, and typically resort to the hostility of forums only after I can't solve the problem through intense research. You assume I'm the sort who runs to a forum first, not last. On Jul 20, 12:31 pm, Rick <[email protected]> wrote: > The error message is spot on (except that is says "you may...") as you > have problems with your routes. Try running "script/generate scaffold > Machine name:string" and the follow-on "rake db:migrate" and "rake > routes". Look at the difference between the routes generated for > Equipment/Equipment and Machine/Machines. > > With a heavy personal application of bsat (blood sweat and tears) you > can work around Rail's expectation for distinct tense forms but you > won't be happy. > > That's life in a syntactic sugar bowl... > > On Jul 19, 5:26 pm,BenWilson<[email protected]> wrote: > > > I'm trying to use new_equipment_path, which creates the appropriate > > link. But, when trying to evaluate "equipment/new" I get the error > > below. I've included my routes (rake route). Equipment is one of those > > words that pluralizes to "equipment", so the singular is right (from > > what I know from this forum. > > > Any help would be appreciated. > > > Error: > > > equipment_url failed to generate from > > {:action=>"show", :controller=>"equipment"} - you may have ambiguous > > routes, or you may need to supply additional parameters for this > > route. content_url has the following required parameters: > > ["equipment", :id] - are they all satisfied? > > > Routes: > > > equipment_index GET /equipment > > (.:format) > > {:controller=>"equipment", :action=>"index"} > > POST /equipment > > (.:format) > > {:controller=>"equipment", :action=>"create"} > > new_equipment GET /equipment/new > > (.:format) > > {:controller=>"equipment", :action=>"new"} > > edit_equipment GET /equipment/:id/edit > > (.:format) > > {:controller=>"equipment", :action=>"edit"} > > equipment GET /equipment/:id > > (.:format) > > {:controller=>"equipment", :action=>"show"} > > PUT /equipment/:id > > (.:format) > > {:controller=>"equipment", :action=>"update"} > > DELETE /equipment/:id > > (.:format) > > {:controller=>"equipment", :action=>"destroy"} > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---

