Class: BatchRollback::MigrationStep

Inherits:
ActiveRecord::Base
  • Object
show all
Defined in:
lib/batch_rollback/migration_step.rb

Class Method Summary collapse

Class Method Details

.create_tableObject



8
9
10
11
12
13
14
15
16
# File 'lib/batch_rollback/migration_step.rb', line 8

def create_table
  return if table_exists?

  connection.create_table(table_name) do |t|
    t.string :current_version
    t.string :target_version
    t.integer :step
  end
end

.table_nameObject



4
5
6
# File 'lib/batch_rollback/migration_step.rb', line 4

def table_name
  "br_migration_steps"
end