From: Christopher Schmidt Date: Sun, 20 Apr 2008 16:18:22 +0000 (+0000) Subject: add a browse index (no content yet) X-Git-Tag: live~7711^2~37 X-Git-Url: https://git.openstreetmap.org/rails.git/commitdiff_plain/bad57126c0cb9ff6824c5688bdf3974c2410ea5a?ds=inline add a browse index (no content yet) --- diff --git a/app/controllers/browse_controller.rb b/app/controllers/browse_controller.rb index 5e55de13b..a33fedd53 100644 --- a/app/controllers/browse_controller.rb +++ b/app/controllers/browse_controller.rb @@ -2,6 +2,9 @@ class BrowseController < ApplicationController before_filter :authorize_web layout 'site' + def index + end + def relation begin @relation = Relation.find(params[:id]) diff --git a/app/views/browse/index.rhtml b/app/views/browse/index.rhtml new file mode 100644 index 000000000..d4a7b19ef --- /dev/null +++ b/app/views/browse/index.rhtml @@ -0,0 +1 @@ +Welcome to the browse subpages! diff --git a/config/routes.rb b/config/routes.rb index 84e6256e1..a93946c52 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -55,6 +55,7 @@ ActionController::Routing::Routes.draw do |map| map.connect "api/#{API_VERSION}/swf/trackpoints", :controller =>'swf', :action =>'trackpoints' # Data browsing + map.connect '/browse', :controller => 'browse', :action => 'index' map.connect '/browse/way/:id', :controller => 'browse', :action => 'way', :id => /\d+/ map.connect '/browse/way/:id/history', :controller => 'browse', :action => 'way_history', :id => /\d+/ map.connect '/browse/node/:id', :controller => 'browse', :action => 'node', :id => /\d+/