AnyLoginMultiple
This gem is inspired by any_login. This gem supports multiple models.
Installation
First of all, this gem only work in an environment where devise is installed.
Add this line to your application's Gemfile:
group :development, :test do
gem 'any_login_multiple'
end
And then execute:
$ bundle install
Add this line to routes.rb
:
mount AnyLoginMultiple::Engine => '/any_login_multiple' if Rails.env.development?
Add this lines to config/environments/development.rb
:
config.after_initialize do
AnyLoginMultiple.klass_names = ['User', 'Staff']
end
Usage
Add this line to application.html.erb
:
<%= any_login_multiple_here if Rails.env.development? %>
License
The gem is available as open source under the terms of the MIT License.