Heroku - Страница не существует

При попытке получить доступ к моему приложению появляется ошибка, что моя страница не существует. Он работает локально, но не в системе, я запустил rake и route и перезапустился без разрешения. «Страница не существует» показывает мой пользовательский значок, хотя. Это простое приложение на одной странице для использования в моей личной компании. Я СОБСТВЕННЫЙ, ОЧЕНЬ ОСНОВНОЙ, ничего сверх того, один набор строительных лесов и все ... Это было разработано в RubyMine

Файл маршрутов:

BoothLeads::Application.routes.draw do

  resources :leads


  # The priority is based upon order of creation:
  # first created -> highest priority.

  # Sample of regular route:
  #   match 'products/:id' => 'catalog#view'
  # Keep in mind you can assign values other than :controller and :action

  # Sample of named route:
  #   match 'products/:id/purchase' => 'catalog#purchase', :as => :purchase
  # This route can be invoked with purchase_url(:id => product.id)

  # Sample resource route (maps HTTP verbs to controller actions automatically):
  #   resources :products

  # Sample resource route with options:
  #   resources :products do
  #     member do
  #       get 'short'
  #       post 'toggle'
  #     end
  #
  #     collection do
  #       get 'sold'
  #     end
  #   end

  # Sample resource route with sub-resources:
  #   resources :products do
  #     resources :comments, :sales
  #     resource :seller
  #   end

  # Sample resource route with more complex sub-resources
  #   resources :products do
  #     resources :comments
  #     resources :sales do
  #       get 'recent', :on => :collection
  #     end
  #   end

  # Sample resource route within a namespace:
  #   namespace :admin do
  #     # Directs /admin/products/* to Admin::ProductsController
  #     # (app/controllers/admin/products_controller.rb)
  #     resources :products
  #   end

  # You can have the root of your site routed with "root"
  # just remember to delete public/index.html.
   #root :to => 'leads#index.html'

  # See how all your routes lay out with "rake routes"

  # This is a legacy wild controller route that's not recommended for RESTful applications.
  # Note: This route will make all actions in every controller accessible via GET requests.
  # match ':controller(/:action(/:id))(.:format)'
end

мигрировать

class CreateLeads < ActiveRecord::Migration
  def change
    create_table :leads do |t|
      t.string :name
      t.string :address
      t.string :phone
      t.text :interest

      t.timestamps
    end
  end
end

ВЕДЕТ КОНТРОЛЛЕР

class LeadsController < ApplicationController
  # GET /leads
  # GET /leads.json
  def index
    @leads = Lead.all

    respond_to do |format|
      format.html # index.html.erb
      format.json { render json: @leads }
    end
  end

  # GET /leads/1
  # GET /leads/1.json
  def show
    @lead = Lead.find(params[:id])

    respond_to do |format|
      format.html # show.html.erb
      format.json { render json: @lead }
    end
  end

  # GET /leads/new
  # GET /leads/new.json
  def new
    @lead = Lead.new

    respond_to do |format|
      format.html # new.html.erb
      format.json { render json: @lead }
    end
  end

  # GET /leads/1/edit
  def edit
    @lead = Lead.find(params[:id])
  end

  # POST /leads
  # POST /leads.json
  def create
    @lead = Lead.new(params[:lead])

    respond_to do |format|
      if @lead.save
        format.html { redirect_to @lead, notice: 'Lead was successfully created.' }
        format.json { render json: @lead, status: :created, location: @lead }
      else
        format.html { render action: "new" }
        format.json { render json: @lead.errors, status: :unprocessable_entity }
      end
    end
  end

  # PUT /leads/1
  # PUT /leads/1.json
  def update
    @lead = Lead.find(params[:id])

    respond_to do |format|
      if @lead.update_attributes(params[:lead])
        format.html { redirect_to @lead, notice: 'Lead was successfully updated.' }
        format.json { head :no_content }
      else
        format.html { render action: "edit" }
        format.json { render json: @lead.errors, status: :unprocessable_entity }
      end
    end
  end

  # DELETE /leads/1
  # DELETE /leads/1.json
  def destroy
    @lead = Lead.find(params[:id])
    @lead.destroy

    respond_to do |format|
      format.html { redirect_to leads_url }
      format.json { head :no_content }
    end
  end
end

Что-нибудь еще нужно, дайте мне знать.

Спасибо за помощь.

CMD PROMPT: Heroku Logs

C:\Users\Jeff Gray\RubymineProjects\BoothLeads>heroku logs
2013-04-01T05:34:12+00:00 app[web.1]: Completed 200 OK in 218ms (Views: 61.9ms |
 ActiveRecord: 63.6ms)
2013-04-01T05:34:13+00:00 heroku[router]: at=info method=GET path=/assets/applic
ation-01780e1cf08fc467414520399232647f.css host=peaceful-chamber-6371.herokuapp.
com fwd="110.32.193.201" dyno=web.1 connect=1ms service=32ms status=200 bytes=25
4629
2013-04-01T05:34:13+00:00 heroku[router]: at=info method=GET path=/assets/applic
ation-5909661ad10a83c2e0ae36fac77e7706.js host=peaceful-chamber-6371.herokuapp.c
om fwd="110.32.193.201" dyno=web.1 connect=1ms service=19ms status=200 bytes=128
395
2013-04-01T05:34:21+00:00 heroku[web.1]: Stopping all processes with SIGTERM
2013-04-01T05:34:22+00:00 app[web.1]:   /usr/local/lib/ruby/1.9.1/webrick/server
.rb:90:in `select'
2013-04-01T05:34:22+00:00 app[web.1]: [2013-04-01 05:34:22] ERROR SignalExceptio
n: SIGTERM
2013-04-01T05:34:33+00:00 heroku[web.1]: Stopping remaining processes with SIGKI
LL
2013-04-01T05:34:33+00:00 heroku[web.1]: Error R12 (Exit timeout) -> At least on
e process failed to exit within 10 seconds of SIGTERM
2013-04-01T05:34:35+00:00 heroku[web.1]: Process exited with status 137
2013-04-01T05:37:42+00:00 heroku[api]: Starting process with command `bundle exe
c rake db:migrate` by [email protected]
2013-04-01T05:37:45+00:00 heroku[run.2185]: Awaiting client
2013-04-01T05:37:45+00:00 heroku[run.2185]: Starting process with command `bundl
e exec rake db:migrate`
2013-04-01T05:37:46+00:00 heroku[run.2185]: State changed from starting to up
2013-04-01T05:37:54+00:00 heroku[run.2185]: Process exited with status 1
2013-04-01T05:37:54+00:00 heroku[run.2185]: State changed from up to complete
2013-04-01T05:38:00+00:00 heroku[web.1]: State changed from up to starting
2013-04-01T05:38:02+00:00 heroku[web.1]: Starting process with command `bundle e
xec rails server -p 47627`
2013-04-01T05:38:03+00:00 heroku[web.1]: Stopping all processes with SIGTERM
2013-04-01T05:38:04+00:00 app[web.1]: [2013-04-01 05:38:04] ERROR SignalExceptio
n: SIGTERM
2013-04-01T05:38:04+00:00 app[web.1]:   /usr/local/lib/ruby/1.9.1/webrick/server
.rb:90:in `select'
2013-04-01T05:38:06+00:00 app[web.1]: DEPRECATION WARNING: You have Rails 2.3-st
yle plugins in vendor/plugins! Support for these plugins will be removed in Rail
s 4.0. Move them out and bundle them in your Gemfile, or fold them in to your ap
p as lib/myplugin/* and config/initializers/myplugin.rb. See the release notes f
or more on this: http://weblog.rubyonrails.org/2012/1/4/rails-3-2-0-rc2-has-been
-released. (called from <top (required)> at /app/config/environment.rb:5)
2013-04-01T05:38:06+00:00 app[web.1]: DEPRECATION WARNING: You have Rails 2.3-st
yle plugins in vendor/plugins! Support for these plugins will be removed in Rail
s 4.0. Move them out and bundle them in your Gemfile, or fold them in to your ap
p as lib/myplugin/* and config/initializers/myplugin.rb. See the release notes f
or more on this: http://weblog.rubyonrails.org/2012/1/4/rails-3-2-0-rc2-has-been
-released. (called from <top (required)> at /app/config/environment.rb:5)
2013-04-01T05:38:10+00:00 app[web.1]: => Booting WEBrick
2013-04-01T05:38:10+00:00 app[web.1]: => Rails 3.2.12 application starting in pr
oduction on http://0.0.0.0:47627
2013-04-01T05:38:10+00:00 app[web.1]: => Call with -d to detach
2013-04-01T05:38:10+00:00 app[web.1]: => Ctrl-C to shutdown server
2013-04-01T05:38:10+00:00 app[web.1]: Connecting to database specified by DATABA
SE_URL
2013-04-01T05:38:10+00:00 app[web.1]: [2013-04-01 05:38:10] INFO  ruby 1.9.2 (20
11-07-09) [x86_64-linux]
2013-04-01T05:38:10+00:00 app[web.1]: [2013-04-01 05:38:10] INFO  WEBrick 1.3.1
2013-04-01T05:38:10+00:00 app[web.1]: [2013-04-01 05:38:10] INFO  WEBrick::HTTPS
erver#start: pid=2 port=47627
2013-04-01T05:38:11+00:00 heroku[web.1]: State changed from starting to up
2013-04-01T05:38:14+00:00 heroku[web.1]: Error R12 (Exit timeout) -> At least on
e process failed to exit within 10 seconds of SIGTERM
2013-04-01T05:38:14+00:00 heroku[web.1]: Stopping remaining processes with SIGKI
LL
2013-04-01T05:38:17+00:00 heroku[web.1]: Process exited with status 137
2013-04-01T05:38:36+00:00 heroku[router]: at=info method=GET path=/ host=peacefu
l-chamber-6371.herokuapp.com fwd="75.170.18.86" dyno=web.1 connect=6ms service=1
94ms status=404 bytes=728
2013-04-01T05:38:36+00:00 app[web.1]: Started GET "/" for 75.170.18.86 at 2013-0
4-01 05:38:35 +0000
2013-04-01T05:38:36+00:00 app[web.1]:
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/railties-3
.2.12/lib/rails/rack/logger.rb:32:in `call_app'
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/activesupp
ort-3.2.12/lib/active_support/tagged_logging.rb:22:in `tagged'
2013-04-01T05:38:36+00:00 app[web.1]: ActionController::RoutingError (No route m
atches [GET] "/"):
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/railties-3
.2.12/lib/rails/rack/logger.rb:16:in `call'
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/actionpack
-3.2.12/lib/action_dispatch/middleware/request_id.rb:22:in `call'
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/activesupp
ort-3.2.12/lib/active_support/cache/strategy/local_cache.rb:72:in `call'
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/actionpack
-3.2.12/lib/action_dispatch/middleware/show_exceptions.rb:56:in `call'
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/railties-3
.2.12/lib/rails/rack/logger.rb:16:in `block in call'
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/rack-1.4.5
/lib/rack/methodoverride.rb:21:in `call'
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/rack-1.4.5
/lib/rack/lock.rb:15:in `call'
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/actionpack
-3.2.12/lib/action_dispatch/middleware/debug_exceptions.rb:21:in `call'
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/rack-cache
-1.2/lib/rack/cache/context.rb:136:in `forward'
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/rack-cache
-1.2/lib/rack/cache/context.rb:245:i
n `fetch'
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/rack-cache
-1.2/lib/rack/cache/context.rb:66:in `call!'
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/railties-3
.2.12/lib/rails/engine.rb:479:in `call'
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/rack-cache
-1.2/lib/rack/cache/context.rb:51:in `call'
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/railties-3
.2.12/lib/rails/application.rb:223:in `call'
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/rack-1.4.5
/lib/rack/content_length.rb:14:in `call'
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/rack-1.4.5
/lib/rack/runtime.rb:17:in `call'
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/rack-cache
-1.2/lib/rack/cache/context.rb:185:in `lookup'
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/actionpack
-3.2.12/lib/action_dispatch/middleware/static.rb:62:in `call'
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/railties-3
.2.12/lib/rails/rack/log_tailer.rb:17:in `call'
2013-04-01T05:38:36+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/rack-1.4.5
/lib/rack/handler/webrick.rb:59:in `service'
2013-04-01T05:38:36+00:00 app[web.1]:   /usr/local/lib/ruby/1.9.1/webrick/httpse
rver.rb:111:in `service'
2013-04-01T05:38:36+00:00 app[web.1]:   /usr/local/lib/ruby/1.9.1/webrick/httpse
rver.rb:70:in `run'
2013-04-01T05:38:36+00:00 app[web.1]:
2013-04-01T05:38:36+00:00 app[web.1]:   /usr/local/lib/ruby/1.9.1/webrick/server
.rb:183:in `block in start_thread'
2013-04-01T05:38:36+00:00 app[web.1]:
2013-04-01T05:39:44+00:00 app[web.1]: Started GET "/" for 75.170.18.86 at 2013-0
4-01 05:39:44 +0000
2013-04-01T05:39:44+00:00 app[web.1]:
2013-04-01T05:39:44+00:00 app[web.1]: ActionController::RoutingError (No route m
atches [GET] "/"):
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/actionpack
-3.2.12/lib/action_dispatch/middleware/debug_exceptions.rb:21:in `call'
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/actionpack
-3.2.12/lib/action_dispatch/middleware/show_exceptions.rb:56:in `call'
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/railties-3
.2.12/lib/rails/rack/logger.rb:32:in `call_app'
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/railties-3
.2.12/lib/rails/rack/logger.rb:16:in `block in call'
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/activesupp
ort-3.2.12/lib/active_support/tagged_logging.rb:22:in `tagged'
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/railties-3
.2.12/lib/rails/rack/logger.rb:16:in `call'
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/actionpack
-3.2.12/lib/action_dispatch/middleware/request_id.rb:22:in `call'
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/rack-1.4.5
/lib/rack/methodoverride.rb:21:in `call'
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/rack-1.4.5
/lib/rack/runtime.rb:17:in `call'
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/activesupp
ort-3.2.12/lib/active_support/cache/strategy/local_cache.rb:72:in `call'
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/rack-1.4.5
/lib/rack/lock.rb:15:in `call'
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/actionpack
-3.2.12/lib/action_dispatch/middleware/static.rb:62:in `call'
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/rack-cache
-1.2/lib/rack/cache/context.rb:136:in `forward'
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/rack-cache
-1.2/lib/rack/cache/context.rb:245:in `fetch'
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/rack-cache
-1.2/lib/rack/cache/context.rb:185:in `lookup'
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/rack-cache
-1.2/lib/rack/cache/context.rb:51:in `call'
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/rack-cache
-1.2/lib/rack/cache/context.rb:66:in `call!'
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/railties-3
.2.12/lib/rails/engine.rb:479:in `call'
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/railties-3
.2.12/lib/rails/application.rb:223:in `call'
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/rack-1.4.5
/lib/rack/content_length.rb:14:in `call'
2013-04-01T05:39:44+00:00 heroku[router]: at=info method=GET path=/ host=peacefu
l-chamber-6371.herokuapp.com fwd="75.170.18.86" dyno=web.1 connect=2ms service=4
6ms status=404 bytes=728
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/railties-3
.2.12/lib/rails/rack/log_tailer.rb:17:in `call'
2013-04-01T05:39:44+00:00 app[web.1]:   /usr/local/lib/ruby/1.9.1/webrick/httpse
rver.rb:111:in `service'
2013-04-01T05:39:44+00:00 app[web.1]:   /usr/local/lib/ruby/1.9.1/webrick/server
.rb:183:in `block in start_thread'
2013-04-01T05:39:44+00:00 app[web.1]:   /usr/local/lib/ruby/1.9.1/webrick/httpse
rver.rb:70:in `run'
2013-04-01T05:39:44+00:00 app[web.1]:
2013-04-01T05:39:44+00:00 app[web.1]:   vendor/bundle/ruby/1.9.1/gems/rack-1.4.5
/lib/rack/handler/webrick.rb:59:in `service'
2013-04-01T05:39:44+00:00 app[web.1]:
2013-04-01T05:39:54+00:00 app[web.1]: Started GET "/leads" for 110.32.193.201 at
 2013-04-01 05:39:54 +0000
2013-04-01T05:39:54+00:00 app[web.1]: Processing by LeadsController#index as HTM
L
2013-04-01T05:39:54+00:00 app[web.1]:   Rendered leads/index.html.erb within lay
outs/application (12.6ms)
2013-04-01T05:39:54+00:00 app[web.1]: Completed 200 OK in 207ms (Views: 60.8ms |
 ActiveRecord: 60.4ms)
2013-04-01T05:39:54+00:00 heroku[router]: at=info method=GET path=/leads host=pe
aceful-chamber-6371.herokuapp.com fwd="110.32.193.201" dyno=web.1 connect=1ms se
rvice=228ms status=304 bytes=0

production.rb

    BoothLeads::Application.configure do
  # Settings specified here will take precedence over those in config/application.rb

  # Code is not reloaded between requests
  config.cache_classes = true

  # Full error reports are disabled and caching is turned on
  config.consider_all_requests_local       = false
  config.action_controller.perform_caching = true

  # Disable Rails's static asset server (Apache or nginx will already do this)
  config.serve_static_assets = false

  # Compress JavaScripts and CSS
  config.assets.compress = true

  # Don't fallback to assets pipeline if a precompiled asset is missed
  config.assets.compile = true


  # Generate digests for assets URLs
  config.assets.digest = true

  # Defaults to nil and saved in location specified by config.assets.prefix
  # config.assets.manifest = YOUR_PATH

  # Specifies the header that your server uses for sending files
  # config.action_dispatch.x_sendfile_header = "X-Sendfile" # for apache
  # config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect' # for nginx

  # Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies.
  # config.force_ssl = true

  # See everything in the log (default is :info)
  # config.log_level = :debug

  # Prepend all log lines with the following tags
  # config.log_tags = [ :subdomain, :uuid ]

  # Use a different logger for distributed setups
  # config.logger = ActiveSupport::TaggedLogging.new(SyslogLogger.new)

  # Use a different cache store in production
  # config.cache_store = :mem_cache_store

  # Enable serving of images, stylesheets, and JavaScripts from an asset server
  # config.action_controller.asset_host = "http://assets.example.com"

  # Precompile additional assets (application.js, application.css, and all non-JS/CSS are already added)
  # config.assets.precompile += %w( search.js )

  # Disable delivery errors, bad email addresses will be ignored
  # config.action_mailer.raise_delivery_errors = false

  # Enable threaded mode
  # config.threadsafe!

  # Enable locale fallbacks for I18n (makes lookups for any locale fall back to
  # the I18n.default_locale when a translation can not be found)
  config.i18n.fallbacks = true

  # Send deprecation notices to registered listeners
  config.active_support.deprecation = :notify

  # Log the query plan for queries taking more than this (works
  # with SQLite, MySQL, and PostgreSQL)
  # config.active_record.auto_explain_threshold_in_seconds = 0.5
end

Development.rb

BoothLeads::Application.configure do
  # Settings specified here will take precedence over those in config/application.rb

  # In the development environment your application's code is reloaded on
  # every request. This slows down response time but is perfect for development
  # since you don't have to restart the web server when you make code changes.
  config.cache_classes = false

  # Log error messages when you accidentally call methods on nil.
  config.whiny_nils = true

  # Show full error reports and disable caching
  config.consider_all_requests_local       = true
  config.action_controller.perform_caching = false

  # Don't care if the mailer can't send
  config.action_mailer.raise_delivery_errors = false

  # Print deprecation notices to the Rails logger
  config.active_support.deprecation = :log

  # Only use best-standards-support built into browsers
  config.action_dispatch.best_standards_support = :builtin

  # Raise exception on mass assignment protection for Active Record models
  config.active_record.mass_assignment_sanitizer = :strict

  # Log the query plan for queries taking more than this (works
  # with SQLite, MySQL, and PostgreSQL)
  config.active_record.auto_explain_threshold_in_seconds = 0.5

  # Do not compress assets
  config.assets.compress = false

  # Expands the lines which load the assets
  config.assets.debug = true
end

Cat / Config / routes.rb

C:\Users\Jeff Gray\RubymineProjects\BoothLeads>heroku run cat config/routes.rb
Running `cat config/routes.rb` attached to terminal... up, run.2943
BoothLeads::Application.routes.draw do
  resources :solds


  resources :leads


  # The priority is based upon order of creation:
  # first created -> highest priority.

  # Sample of regular route:
  #   match 'products/:id' => 'catalog#view'
  # Keep in mind you can assign values other than :controller and :action

  # Sample of named route:
  #   match 'products/:id/purchase' => 'catalog#purchase', :as => :purchase
  # This route can be invoked with purchase_url(:id => product.id)

  # Sample resource route (maps HTTP verbs to controller actions automatically):

  #   resources :products

  # Sample resource route with options:
  #   resources :products do
  #     member do
  #       get 'short'
  #       post 'toggle'
  #     end
  #
  #     collection do
  #       get 'sold'
  #     end
  #   end

  # Sample resource route with sub-resources:
  #   resources :products do
  #     resources :comments, :sales
  #     resource :seller
  #   end

  # Sample resource route with more complex sub-resources
  #   resources :products do
  #     resources :comments
  #     resources :sales do
  #       get 'recent', :on => :collection
  #     end
  #   end

  # Sample resource route within a namespace:
  #   namespace :admin do
  #     # Directs /admin/products/* to Admin::ProductsController
  #     # (app/controllers/admin/products_controller.rb)
  #     resources :products
  #   end

  # You can have the root of your site routed with "root"
  # just remember to delete public/index.html.
  # root :to => 'welcome#index'

  # See how all your routes lay out with "rake routes"

  # This is a legacy wild controller route that's not recommended for RESTful ap
plications.
  # Note: This route will make all actions in every controller accessible via GE
T requests.
  # match ':controller(/:action(/:id))(.:format)'
end

Ответы на вопрос(3)

Ваш ответ на вопрос