0
/pages
으로 시작하지 않는 URL에 thoughtbot's High Voltage gem이 작동하지 않습니다. www.example.com/pages/company/about
과 같은 URL의 경우 완벽하게 작동합니다. 나는이 경로를 추가 할 때 :/_ 페이지로 시작하지 않는 URL에 대해 high_voltage gem이 작동하지 않습니다.
match '/company/about' => 'high_voltage/pages#show', :id => 'about'
을 나는 내부 서버 오류 얻을 : 난 그냥 app/views/pages/about.html.erb
내부 about.html.erb
페이지를 넣을 경우, 그러나
Started GET "/company/about" for 127.0.0.1 at 2012-10-09 18:03:45 -0700
Processing by HighVoltage::PagesController#show as HTML
Parameters: {"id"=>"about"}
Completed 500 Internal Server Error in 2ms
ActionController::RoutingError (No such page: about):
high_voltage (1.2.0) app/controllers/high_voltage/pages_controller.rb:9:in `block in <class:PagesController>'
activesupport (3.2.8) lib/active_support/rescuable.rb:80:in `call'
activesupport (3.2.8) lib/active_support/rescuable.rb:80:in `rescue_with_handler'
actionpack (3.2.8) lib/action_controller/metal/rescue.rb:15:in `rescue_with_handler'
을 한 후 모든 것이이 경로 예상 작품과 같이
match '/:id' => 'high_voltage/pages#show'
또는이 경로도 작동합니다
match '/about' => 'high_voltage/pages#show', :id => 'about'