路线.rb
match 'mybookings/:token' => 'mybookings#test', :as => 'bookit'
resources :mybookings
rails路线显示:
bookit /app/mybookings/:token(.:format) mybookings#test
然后我使用一个助手:
=link_to "by clicking here", bookit_url(@client.token)
这导致
ActionView::Template::Error
Error
undefined method `bookit_url' for #<#<Class:0x007fd2c1ca3488>:0x007fd2c1f96960>
那个帮手怎么了?