Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7710291
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T01:05:26+00:00 2026-06-01T01:05:26+00:00

hi im new in ruby on rails development and currently im working in a

  • 0

hi im new in ruby on rails development and currently im working in a reservation system i made a semi static page with a controller inside it has a functionroom action
my functionroom action is

 def functionroom
    @reservation = Reservation.find(params[:reservation_id])
    @function_room = FunctionRoom.all 
  end

but when i try to route to functionroom coming from the reservation module with this route
<%= link_to "add functionrooms", reservation_pages_functionroom_path(@reservation) %>

it gives me a uninitialized constant Reservations error
im just wondering if im working with my routes right dealing with the pages/functionroom static page.

resources :reservations do
   resources :reservation_function_rooms
   resources :reservation_packages
   get 'pages/functionroom'
   resources :package_line_items
  end

error stack:

ActionController::RoutingError (uninitialized constant Reservations):
  activesupport (3.2.1) lib/active_support/inflector/methods.rb:229:in 
`block in constantize'
  activesupport (3.2.1) lib/active_support/inflector/methods.rb:228:in 
`each'
  activesupport (3.2.1) lib/active_support/inflector/methods.rb:228:in 
`constantize'
  actionpack (3.2.1) lib/action_dispatch/routing/route_set.rb:62:in 
`controller_reference'
  actionpack (3.2.1) lib/action_dispatch/routing/route_set.rb:47:in 
`controller'
  actionpack (3.2.1) lib/action_dispatch/routing/route_set.rb:26:in 
`call'
  journey (1.0.3) lib/journey/router.rb:68:in `block in call'
  journey (1.0.3) lib/journey/router.rb:56:in `each'
  journey (1.0.3) lib/journey/router.rb:56:in `call'
  actionpack (3.2.1) lib/action_dispatch/routing/route_set.rb:589:in 
`call'
  sass (3.1.15) lib/sass/plugin/rack.rb:54:in `call'
  warden (1.1.1) lib/warden/manager.rb:35:in `block in call'
  warden (1.1.1) lib/warden/manager.rb:34:in `catch'
  warden (1.1.1) lib/warden/manager.rb:34:in `call'
  actionpack (3.2.1) 
lib/action_dispatch/middleware/best_standards_support.rb:17:in `call'
  rack (1.4.1) lib/rack/etag.rb:23:in `call'
  rack (1.4.1) lib/rack/conditionalget.rb:25:in `call'
  actionpack (3.2.1) lib/action_dispatch/middleware/head.rb:14:in `call'
  actionpack (3.2.1) 
lib/action_dispatch/middleware/params_parser.rb:21:in `call'
  actionpack (3.2.1) lib/action_dispatch/middleware/flash.rb:242:in 
`call'
  rack (1.4.1) lib/rack/session/abstract/id.rb:205:in `context'
  rack (1.4.1) lib/rack/session/abstract/id.rb:200:in `call'
  actionpack (3.2.1) lib/action_dispatch/middleware/cookies.rb:338:in 
`call'
  activerecord (3.2.1) lib/active_record/query_cache.rb:64:in `call'
  activerecord (3.2.1) 
lib/active_record/connection_adapters/abstract/connection_pool.rb:443:in 
`call'
  actionpack (3.2.1) lib/action_dispatch/middleware/callbacks.rb:28:in 
`block in call'
  activesupport (3.2.1) lib/active_support/callbacks.rb:405:in 
`_run__321294476__call__156324443__callbacks'
  activesupport (3.2.1) lib/active_support/callbacks.rb:405:in 
`__run_callback'
  activesupport (3.2.1) lib/active_support/callbacks.rb:385:in 
`_run_call_callbacks'
  activesupport (3.2.1) lib/active_support/callbacks.rb:81:in 
`run_callbacks'
  actionpack (3.2.1) lib/action_dispatch/middleware/callbacks.rb:27:in 
`call'
  actionpack (3.2.1) lib/action_dispatch/middleware/reloader.rb:65:in 
`call'
  actionpack (3.2.1) lib/action_dispatch/middleware/remote_ip.rb:31:in 
`call'
  actionpack (3.2.1) 
lib/action_dispatch/middleware/debug_exceptions.rb:16:in `call'
  actionpack (3.2.1) 
lib/action_dispatch/middleware/show_exceptions.rb:56:in `call'
  railties (3.2.1) lib/rails/rack/logger.rb:26:in `call_app'
  railties (3.2.1) lib/rails/rack/logger.rb:16:in `call'
  actionpack (3.2.1) lib/action_dispatch/middleware/request_id.rb:22:in 
`call'
  rack (1.4.1) lib/rack/methodoverride.rb:21:in `call'
  rack (1.4.1) lib/rack/runtime.rb:17:in `call'
  activesupport (3.2.1) 
lib/active_support/cache/strategy/local_cache.rb:72:in `call'
  rack (1.4.1) lib/rack/lock.rb:15:in `call'
  actionpack (3.2.1) lib/action_dispatch/middleware/static.rb:53:in 
`call'
  railties (3.2.1) lib/rails/engine.rb:479:in `call'
  railties (3.2.1) lib/rails/application.rb:220:in `call'
  rack (1.4.1) lib/rack/content_length.rb:14:in `call'
  railties (3.2.1) lib/rails/rack/log_tailer.rb:14:in `call'
  rack (1.4.1) lib/rack/handler/webrick.rb:59:in `service'
  /home/led/.rvm/rubies/ruby-1.9.3-rc1/lib/ruby/1.9.1/webrick/httpserver.rb:138:in 
`service'
  /home/led/.rvm/rubies/ruby-1.9.3-rc1/lib/ruby/1.9.1/webrick/httpserver.rb:94:in 
`run'
  /home/led/.rvm/rubies/ruby-1.9.3-rc1/lib/ruby/1.9.1/webrick/server.rb:191:in 
`block in start_thread'


  Rendered 
/home/led/.rvm/gems/ruby-1.9.3-rc1/gems/actionpack-3.2.1/lib/action_dispatch/middleware/templates/rescues/routing_error.erb 
within rescues/layout (1.2ms)
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T01:05:27+00:00Added an answer on June 1, 2026 at 1:05 am

    You can make route of it like in this way also

        resources :reservations do
    
         resources :pages do
            collection do
              get :functionroom
            end
         end
            resources :reservation_function_rooms
            resources :reservation_packages            
            resources :package_line_items
        end
    

    but you can check routes through rake routes

    it will sure work……..

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm quite new to ruby development, and i'm currently working on a project in
I'm currently evaluating options for adding sub-domain support to a new Ruby on Rails
I'm really new at Ruby on Rails development. I'm reading Head First Rails and
I'm working on a Ruby on Rails application that used the Devise authentication system.
First I'm quite new to ruby and rails... I have a little application working
I'm new to ruby on rails development but I am a little confused with
I'm new to ruby on rails so i'm using the book Agile Web Development
I'm new to Ruby On Rails. I love, it has Testing capabilities built in.
I am new to Ruby on Rails, I have completed the Blog Tutorial .
I'm new to Ruby on Rails, and I'm in the process of setting it

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.