Skip to content

Commit

Permalink
Routing work for #87.
Browse files Browse the repository at this point in the history
  • Loading branch information
bamnet committed May 10, 2012
1 parent fb222e2 commit 6e69702
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 8 deletions.
12 changes: 5 additions & 7 deletions config/routes.rb
Original file line number Diff line number Diff line change
Expand Up @@ -60,23 +60,21 @@
resources :fields
end

match 'content/' => 'feeds#index'
resources :feeds do
resources :submissions, :only => [:index, :show, :update]
end

#map.resources :feeds do |feeds|
# feeds.resources :submissions
#end

resources :contents, :path => "content" do
resources :contents, :except => [:index], :path => "content" do
get :display, :on => :member
end

resources :graphics, :controller => :contents, :path => "content" do
# TODO(bamnet): Figure out if these routes mean anything.
resources :graphics, :controller => :contents, :except => [:index], :path => "content" do
get :display, :on => :member
end

resources :tickers, :controller => :contents, :path => "content"
resources :tickers, :controller => :contents, :except => [:index], :path => "content"

#Set a non-restul route to the dashboard
match 'dashboard/' => 'dashboard#index'
Expand Down
2 changes: 1 addition & 1 deletion test/integration/routes_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ class RoutesTest < ActionController::IntegrationTest
fixtures :all

test "non plural content route" do
assert_recognizes({:controller => 'contents', :action => 'index'}, "content")
assert_recognizes({:controller => 'feeds', :action => 'index'}, "content")

# A backup way to test this
#assert_equal "/content", contents_path
Expand Down

0 comments on commit 6e69702

Please sign in to comment.