Sha256: fb9b6a899a90c29867e5497d3439fff05ade91a9d139f61d20af699193f51da3

Contents?: true

Size: 699 Bytes

Versions: 18

Compression:

Stored size: 699 Bytes

Contents

# frozen_string_literal: true

module ActiveRecord
  module ConnectionAdapters
    module SQLite3
      # = Active Record SQLite3 Adapter \Table Definition
      class TableDefinition < ActiveRecord::ConnectionAdapters::TableDefinition
        def change_column(column_name, type, **options)
          name = column_name.to_s
          @columns_hash[name] = nil
          column(name, type, **options)
        end

        def references(*args, **options)
          super(*args, type: :integer, **options)
        end
        alias :belongs_to :references

        private
          def integer_like_primary_key_type(type, options)
            :primary_key
          end
      end
    end
  end
end

Version data entries

18 entries across 18 versions & 4 rubygems

Version Path
minato_ruby_api_client-0.2.2 vendor/bundle/ruby/3.2.0/gems/activerecord-7.1.3.4/lib/active_record/connection_adapters/sqlite3/schema_definitions.rb
activerecord-7.1.5.1 lib/active_record/connection_adapters/sqlite3/schema_definitions.rb
activerecord-7.1.5 lib/active_record/connection_adapters/sqlite3/schema_definitions.rb
activerecord-7.1.4.2 lib/active_record/connection_adapters/sqlite3/schema_definitions.rb
activerecord-7.1.4.1 lib/active_record/connection_adapters/sqlite3/schema_definitions.rb
activerecord-7.1.4 lib/active_record/connection_adapters/sqlite3/schema_definitions.rb
blacklight-spotlight-3.6.0.beta8 vendor/bundle/ruby/3.2.0/gems/activerecord-7.1.3.4/lib/active_record/connection_adapters/sqlite3/schema_definitions.rb
tinymce-rails-7.1.2 vendor/bundle/ruby/3.3.0/gems/activerecord-7.1.3.4/lib/active_record/connection_adapters/sqlite3/schema_definitions.rb
activerecord-7.1.3.4 lib/active_record/connection_adapters/sqlite3/schema_definitions.rb
activerecord-7.1.3.2 lib/active_record/connection_adapters/sqlite3/schema_definitions.rb
activerecord-7.1.3.1 lib/active_record/connection_adapters/sqlite3/schema_definitions.rb
activerecord-7.1.3 lib/active_record/connection_adapters/sqlite3/schema_definitions.rb
activerecord-7.1.2 lib/active_record/connection_adapters/sqlite3/schema_definitions.rb
activerecord-7.1.1 lib/active_record/connection_adapters/sqlite3/schema_definitions.rb
activerecord-7.1.0 lib/active_record/connection_adapters/sqlite3/schema_definitions.rb
activerecord-7.1.0.rc2 lib/active_record/connection_adapters/sqlite3/schema_definitions.rb
activerecord-7.1.0.rc1 lib/active_record/connection_adapters/sqlite3/schema_definitions.rb
activerecord-7.1.0.beta1 lib/active_record/connection_adapters/sqlite3/schema_definitions.rb