Sha256: 7f963df9d7d98cb3d2ec30b5774420076a41c874a048b1787a26920179c93309
Contents?: true
Size: 693 Bytes
Versions: 13
Compression:
Stored size: 693 Bytes
Contents
module DataMigrate class Migration < ::ActiveRecord::Migration class << self def check_pending!(connection = ::ActiveRecord::Base.connection) raise ActiveRecord::PendingMigrationError if DataMigrator::Migrator.needs_migration?(connection) end def migrate(direction) new.migrate direction end def table_name ActiveRecord::Base.table_name_prefix + 'data_migrations' + ActiveRecord::Base.table_name_suffix end def index_name "#{table_name_prefix}unique_data_migrations#{table_name_suffix}" end end def initialize(name = self.class.name, version = nil) super(name, version) end end end
Version data entries
13 entries across 13 versions & 1 rubygems