Class: EasyAdmin::Generators::TwoFactorGenerator
- Inherits:
-
Rails::Generators::Base
- Object
- Rails::Generators::Base
- EasyAdmin::Generators::TwoFactorGenerator
- Defined in:
- lib/generators/easy_admin/two_factor/two_factor_generator.rb
Instance Method Summary collapse
Instance Method Details
#create_migration ⇒ Object
10 11 12 13 14 15 |
# File 'lib/generators/easy_admin/two_factor/two_factor_generator.rb', line 10 def create_migration = Time.current.utc.strftime("%Y%m%d%H%M%S") migration_file = "#{}_add_two_factor_to_easy_admin_admin_users.rb" template 'migration.rb', "db/migrate/#{migration_file}" end |
#show_readme ⇒ Object
17 18 19 |
# File 'lib/generators/easy_admin/two_factor/two_factor_generator.rb', line 17 def show_readme readme "README" if behavior == :invoke end |