Sha256: bfc990fa693a4a276f52f0a70f78226f724124d35e5791617385b643fa7182bc

Contents?: true

Size: 792 Bytes

Versions: 5

Compression:

Stored size: 792 Bytes

Contents

class DiscoApp::InstallController < ApplicationController
  include DiscoApp::Concerns::AuthenticatedController

  skip_before_action :check_current_subscription
  skip_before_action :check_active_charge

  # Start the installation process for the current shop, then redirect to the installing screen.
  def install
    DiscoApp::AppInstalledJob.perform_later(@shop.shopify_domain, cookies[DiscoApp::CODE_COOKIE_KEY], cookies[DiscoApp::SOURCE_COOKIE_KEY])
    redirect_to action: :installing
  end

  # Display an "installing" page.
  def installing
    if @shop.installed?
      redirect_to main_app.root_path
    end
  end

  # Display an "uninstalling" page. Should be almost never used.
  def uninstalling
    if @shop.uninstalled?
      redirect_to main_app.root_path
    end
  end

end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
disco_app-0.8.9 app/controllers/disco_app/install_controller.rb
disco_app-0.9.0 app/controllers/disco_app/install_controller.rb
disco_app-0.9.1 app/controllers/disco_app/install_controller.rb
disco_app-0.9.2 app/controllers/disco_app/install_controller.rb
disco_app-0.9.3 app/controllers/disco_app/install_controller.rb