diff --git a/app/controllers/admin/register_site_controller.rb b/app/controllers/admin/register_site_controller.rb deleted file mode 100644 index 7736d56..0000000 --- a/app/controllers/admin/register_site_controller.rb +++ /dev/null @@ -1,10 +0,0 @@ -class Admin::RegisterSiteController < OrbitBackendController - def index - end - - def register_site - site = Site.first - site.register_site - redirect_to admin_module_store_path - end -end \ No newline at end of file diff --git a/app/controllers/admin/sites_controller.rb b/app/controllers/admin/sites_controller.rb index 2e492dd..a3b3384 100644 --- a/app/controllers/admin/sites_controller.rb +++ b/app/controllers/admin/sites_controller.rb @@ -147,6 +147,11 @@ class Admin::SitesController < OrbitBackendController render :text => "success" end + def register_site + @site.register_site + redirect_to admin_module_store_path + end + protected def update_design(design) diff --git a/app/views/admin/register_site/index.html.erb b/app/views/admin/register_site/index.html.erb deleted file mode 100644 index cd8907f..0000000 --- a/app/views/admin/register_site/index.html.erb +++ /dev/null @@ -1 +0,0 @@ -<%= link_to "Register", register_site_admin_register_site_index_path, :class => "btn btn-primary"%> diff --git a/config/routes.rb b/config/routes.rb index bbfc832..af22d24 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -272,12 +272,6 @@ Orbit::Application.routes.draw do match 'template_store' => 'template_store#index' match 'template_store/download_theme' => "template_store#download_theme" match 'template_store/template/:id' => 'template_store#show', :as => :template_store_template - - resources :register_site, only: [:index] do - collection do - post 'register_site' - end - end # match 'template_store/cool_method' => "template_store#cool_method" end