Sha256: 46b4b93d1298bd3fb9b589bcf4c514556b0b342aa5828d4004f64cdf0d051a7c

Contents?: true

Size: 460 Bytes

Versions: 3

Compression:

Stored size: 460 Bytes

Contents

class <%= migration_class_name %> < ActiveRecord::Migration
  def change
    create_table :records do |t|
      t.belongs_to :author, polymorphic: true, index: true
      t.belongs_to :subject, polymorphic: true, index: true
      t.belongs_to :parent, polymorphic: true, index: true
      t.jsonb :record_changes, default: {}
      t.jsonb :meta, default: {}
      t.string :request_uuid
      t.string :action

      t.datetime :created_at
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
rails_log_book-0.3.0 lib/generators/log_book/templates/install.rb
rails_log_book-0.2.0 lib/generators/log_book/templates/install.rb
rails_log_book-0.1.0 lib/generators/log_book/templates/install.rb