ActionController::RoutingError(Uninitialized constant AdminsController)

后端 未结 2 1778
孤城傲影
孤城傲影 2021-01-25 11:33

I am using Rails 3 with dhtmlxGrid. I have created a controller called admin in that we defined 3 functions, such as view,data

2条回答
  •  囚心锁ツ
    2021-01-25 11:50

    Just to add on to what @Paul said. Rails really likes it when you use plural for your controllers but at the end of the day if you can match the name of the file admin_controller.rb and the name on the class AdminController then this should also work okay.

    Otherwise the rails convention over configuration methodology dictates the pluralization of the controller names.

提交回复
热议问题