Convert `item_id` field to bigint (#1245)

* convert `item_id` field to bigint

* add fix to #1242 issue to CHANGELOG.md

* change item_id type on dummy schema
This commit is contained in:
Marcelo Perini Veloso 2020-05-28 14:24:37 -03:00 committed by GitHub
parent 294b7188e9
commit 21ead88829
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 7 additions and 4 deletions

View File

@ -21,6 +21,9 @@ recommendations of [keepachangelog.com](http://keepachangelog.com/).
### Fixed
- [#1242](https://github.com/paper-trail-gem/paper_trail/issues/1242) -
Generator make wrong migration for Oracle database
- [#1238](https://github.com/paper-trail-gem/paper_trail/pull/1238) -
Query optimization in `reify`
@ -46,9 +49,9 @@ recommendations of [keepachangelog.com](http://keepachangelog.com/).
### Dependencies
- [#1213](https://github.com/paper-trail-gem/paper_trail/pull/1213) - Allow
- [#1213](https://github.com/paper-trail-gem/paper_trail/pull/1213) - Allow
contributors to install incompatible versions of ActiveRecord.
See discussion in paper_trail/compatibility.rb
See discussion in paper_trail/compatibility.rb
## 10.3.0 (2019-04-09)

View File

@ -11,7 +11,7 @@ class CreateVersions < ActiveRecord::Migration<%= migration_version %>
def change
create_table :versions<%= versions_table_options %> do |t|
t.string :item_type<%= item_type_options %>
t.integer :item_id, null: false, limit: 8
t.bigint :item_id, null: false
t.string :event, null: false
t.string :whodunnit
t.text :object, limit: TEXT_BYTES

View File

@ -73,7 +73,7 @@ class SetUpTestTables < ::ActiveRecord::Migration::Current
create_table :versions, versions_table_options do |t|
t.string :item_type, **item_type_options(null: false)
t.integer :item_id, null: false
t.bigint :item_id, null: false
t.string :item_subtype, **item_type_options(null: true)
t.string :event, null: false
t.string :whodunnit