diff options
Diffstat (limited to 'config/routes.rb')
-rw-r--r-- | config/routes.rb | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/config/routes.rb b/config/routes.rb index c067de4e5..3dfa30d5a 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -7,12 +7,15 @@ # $Id: routes.rb,v 1.92 2009-10-14 22:01:27 francis Exp $ ActionController::Routing::Routes.draw do |map| - + # The priority is based upon order of creation: first created -> highest priority. # Sample of regular route: # map.connect 'products/:id', :controller => 'catalog', :action => 'view' # Keep in mind you can assign values other than :controller and :action + + # Allow easy extension from themes. Note these will have the highest priority. + require 'config/custom-routes' map.with_options :controller => 'general' do |general| general.frontpage '/', :action => 'frontpage' @@ -23,7 +26,7 @@ ActionController::Routing::Routes.draw do |map| # Couldn't find a way to do this in routes which also picked up multiple other slashes # and dots and other characters that can appear in search query. So we sort it all # out in the controller. - general.search_general '/search/*combined/all', :action => 'search', :view => 'all' + general.search_general '/search/*combined/requests', :action => 'search', :view => 'requests' general.search_general '/search/*combined', :action => 'search' general.advanced_search '/advancedsearch', :action => 'search_redirect', :advanced => true @@ -40,9 +43,13 @@ ActionController::Routing::Routes.draw do |map| request.request_list_awaiting '/list/awaiting', :action => 'list', :view => 'awaiting' request.request_list '/list', :action => 'list' + request.select_authority '/select_authority', :action => 'select_authority' + request.new_request '/new', :action => 'new' request.new_request_to_body '/new/:url_name', :action => 'new' + request.search_ahead '/request/search_ahead', :action => 'search_typeahead' + request.show_request '/request/:url_title.:format', :action => 'show' request.show_new_request '/request/:url_title/new', :action => 'show' request.details_request '/details/request/:url_title', :action => 'details' @@ -57,6 +64,7 @@ ActionController::Routing::Routes.draw do |map| request.info_request_event '/request_event/:info_request_event_id', :action => 'show_request_event' request.upload_response "/upload/request/:url_title", :action => 'upload_response' + request.download_entire_request '/request/:url_title/download', :action => 'download_entire_request' end @@ -85,6 +93,7 @@ ActionController::Routing::Routes.draw do |map| end map.with_options :controller => 'public_body' do |body| + body.search_ahead_bodies '/body/search_ahead', :action => 'search_typeahead' body.list_public_bodies "/body", :action => 'list' body.list_public_bodies_default "/body/list/all", :action => 'list' body.list_public_bodies "/body/list/:tag", :action => 'list' @@ -105,6 +114,10 @@ ActionController::Routing::Routes.draw do |map| comment.new_comment "/annotate/request/:url_title", :action => 'new', :type => 'request' end + map.with_options :controller => 'services' do |service| + service.other_country_message "/country_message", :action => 'other_country_message' + end + map.with_options :controller => 'track' do |track| # /track/ is for setting up an email alert for the item # /feed/ is a direct RSS feed of the item @@ -124,6 +137,7 @@ ActionController::Routing::Routes.draw do |map| map.with_options :controller => 'help' do |help| help.help_unhappy '/help/unhappy/:url_title', :action => 'unhappy' help.help_about '/help/about', :action => 'about' + help.help_about '/help/alaveteli', :action => 'alaveteli' help.help_contact '/help/contact', :action => 'contact' help.help_officers '/help/officers', :action => 'officers' help.help_requesting '/help/requesting', :action => 'requesting' @@ -192,7 +206,9 @@ ActionController::Routing::Routes.draw do |map| user.admin_user_list_banned '/admin/user/banned', :action => 'list_banned' user.admin_user_show '/admin/user/show/:id', :action => 'show' user.admin_user_edit '/admin/user/edit/:id', :action => 'edit' + user.admin_user_show '/admin/user/show_bounce_message/:id', :action => 'show_bounce_message' user.admin_user_update '/admin/user/update/:id', :action => 'update' + user.admin_user_clear_bounce '/admin/user/clear_bounce/:id', :action => 'clear_bounce' user.admin_user_destroy_track '/admin/user/destroy_track', :action => 'destroy_track' user.admin_user_login_as '/admin/user/login_as/:id', :action => 'login_as' user.admin_clear_profile_photo '/admin/user/clear_profile_photo/:id', :action => 'clear_profile_photo' |