为什么http:// localhost:3000 / email / remind / 1将我带到http:// localhost:3000 / sessions /

时间:2017-03-22 20:52:19

标签: email session ruby-on-rails-4 url

我正在尝试从/ session / new发送登录提醒 当我提交请求时,我将转到http://localhost:3000/email/remind/1,但显示的页面为http://localhost:3000/sessions/ 在routes.rb我有

get  'email/remind/:id' =>  'email#remind'
post 'email/remind/:id' => 'email#remind'

任何机构都可以解释我被误导的原因 Screenshot showing /email/remind/1 in the address and /sessions/ on the screen

从终端

  

开始GET" / email / remind / 1"对于127.0.0.1 2017-03-23 17:41:18   +0000通过EmailController处理#repind为HTML参数:{" id" =>" 1"} ActiveRecord :: SessionStore ::会话加载(0.1ms)SELECT   "会话"。* FROM"会话"会议"。" session_id" =?订购   BY"会话"。" id" ASC LIMIT 1 [[" session_id",   " db283ddac9b9c0e1810541ad728398e2"]]呈现的电子邮件/ remind.html.erb   在布局/应用程序内(0.6ms)在11ms完成200 OK(浏览次数:   9.7ms | ActiveRecord:0.1ms)(0.1ms)begin transaction(0.0ms)commit transaction

0 个答案:

没有答案