Sha256: 350203cd59df1043ad44459c0317972b03f02c5b552f1eda63d00f676a9eb0e9
Contents?: true
Size: 693 Bytes
Versions: 18
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
18 entries across 18 versions & 1 rubygems