announcement-test/config/routes.rb

18 lines
364 B
Ruby
Raw Normal View History

2014-04-01 07:12:43 +00:00
Rails.application.routes.draw do
2014-04-10 03:52:59 +00:00
locales = Site.find_by(site_active: true).in_use_locales
scope "(:locale)", locale: Regexp.new(locales.join("|")) do
2014-04-03 03:18:02 +00:00
namespace :admin do
resources :announcements
end
2014-04-01 07:12:43 +00:00
resources :announcements do
collection do
get ':uid/:title', to: 'announcements#show', as: :display
end
end
end
end