Sha256: 7aa0b137dcb2d69323620999144533974e887576bff7fca063f82a3d19d01c8c

Contents?: true

Size: 744 Bytes

Versions: 1

Compression:

Stored size: 744 Bytes

Contents

module Alchemy
  module Admin
    class PasswordsController < ::Devise::PasswordsController
      include Alchemy::Admin::Locale

      before_action { enforce_ssl if ssl_required? && !request.ssl? }

      helper 'Alchemy::Admin::Base'

      layout 'alchemy/admin'

      private

      # Override for Devise method
      def new_session_path(resource_name)
        alchemy.admin_login_path
      end

      def admin_edit_password_url(resource, options={})
        alchemy.admin_edit_password_url(options)
      end

      def after_resetting_password_path_for(resource)
        if can? :index, :alchemy_admin_dashboard
          alchemy.admin_dashboard_path
        else
          alchemy.root_path
        end
      end

    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
alchemy-devise-4.5.0 app/controllers/alchemy/admin/passwords_controller.rb