Class: RailsWorkflow::Generators::InstallGenerator
- Inherits:
-
Rails::Generators::Base
- Object
- Rails::Generators::Base
- RailsWorkflow::Generators::InstallGenerator
- Includes:
- Rails::Generators::Migration
- Defined in:
- lib/generators/rails_workflow/install/install_generator.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.next_migration_number(_path) ⇒ Object
13 14 15 16 17 18 19 20 |
# File 'lib/generators/rails_workflow/install/install_generator.rb', line 13 def self.next_migration_number(_path) if @prev_migration_nr @prev_migration_nr += 1 else @prev_migration_nr = Time.now.utc.strftime('%Y%m%d%H%M%S').to_i end @prev_migration_nr.to_s end |
Instance Method Details
#copy_migrations ⇒ Object
22 23 24 |
# File 'lib/generators/rails_workflow/install/install_generator.rb', line 22 def copy_migrations migration_template 'create_workflow_processes.rb', 'db/migrate/create_workflow_processes.rb' end |