register_modules/config/routes.rb

25 lines
1.1 KiB
Ruby

Rails.application.routes.draw do
locales = Site.first.in_use_locales rescue I18n.available_locales
scope "(:locale)", locale: Regexp.new(locales.join("|")) do
namespace :admin do
get "/register_modules/modulekeys" => "register_modules#modulekeys"
get "/admin_modules/approve" => "admin_modules#approve_modules"
get "/admin_modules/install_site_list" => "admin_modules#install_site_list"
get "/admin_modules/uninstall_site_list" => "admin_modules#uninstall_site_list"
get "/admin_modules/revokelist" => "admin_modules#revoke_list"
get "/admin_modules/grantlist" => "admin_modules#grant_list"
post "/admin_modules/install" => "admin_modules#install_module"
post "/admin_modules/uninstall" => "admin_modules#uninstall_module"
post "/admin_modules/revoke" => "admin_modules#revoke_module"
post "/admin_modules/grant" => "admin_modules#grant_module"
get "/register_desktop_widgets/approve_widget" => "register_desktop_widgets#approve_widget"
resources :register_modules
resources :admin_modules
resources :register_desktop_widgets
end
end
end