当我尝试提交表单时,我收到此错误 ActionController::MethodNotAllowed(仅允许获取、放置和删除请求。)。我的路线是这样的
admin.resources:email_launcher
这是我的form_for,
- form_for :email_launcher, :url => new_admin_email_launcher_path, :method => :get do |f|
这不是形式,而是新视图,我正在使用 HAML。我整天在谷歌上搜索错误,但从未发现任何有价值的东西。任何帮助都会很棒,谢谢。
这是我的 admin_email_launcher 的 rake 路线
admin_email_launcher_index GET /admin/email_launcher(.:format) {:controller=>"admin/email_launcher", :action=>"index"}
POST /admin/email_launcher(.:format) {:controller=>"admin/email_launcher", :action=>"create"}
new_admin_email_launcher GET /admin/email_launcher/new(.:format) {:controller=>"admin/email_launcher", :action=>"new"}
edit_admin_email_launcher GET /admin/email_launcher/:id/edit(.:format) {:controller=>"admin/email_launcher", :action=>"edit"}
GET /admin/email_launcher/:id(.:format) {:controller=>"admin/email_launcher", :action=>"show"}
PUT /admin/email_launcher/:id(.:format) {:controller=>"admin/email_launcher", :action=>"update"}
DELETE /admin/email_launcher/:id(.:format) {:controller=>"admin/email_launcher", :action=>"destroy"}