Rails: Routing without plurals gives strange helpers

后端 未结 1 1578
野性不改
野性不改 2021-01-27 19:36

I am getting a strange named helpers with this setup:

In config/routes.rb I have:

Qtl::Application.routes.draw do
    resources :qtl_table do
                    


        
相关标签:
1条回答
  • 2021-01-27 20:28

    This has nothing to do with pluralizing. YOu need to use search_qtl_table_index_path when you reference it rather than just search_qtl_table_index (you need to add the _path to the end).

    So, your form_tag statement should be:

    <%= form_tag search_qtl_table_index_path, :method => 'get' do %>
    
    0 讨论(0)
提交回复
热议问题