Sha256: cb3e07ca33729e0b486c225b2949d6be62ab6c55628051fd98982e7f983edb66

Contents?: true

Size: 683 Bytes

Versions: 8

Compression:

Stored size: 683 Bytes

Contents

class CreateRailsApiLoggerTable < ActiveRecord::Migration[<%= ActiveRecord::Migration.current_version %>]
  def change
    create_table :inbound_request_logs do |t|
      t.string :method
      t.string :path
      t.text :request_body
      t.text :response_body
      t.integer :response_code
      t.references :loggable, index: true, polymorphic: true
      t.timestamps null: false
    end

    create_table :outbound_request_logs do |t|
      t.string :method
      t.string :path
      t.text :request_body
      t.text :response_body
      t.integer :response_code
      t.references :loggable, index: true, polymorphic: true
      t.timestamps null: false
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
rails_api_logger-0.3.0 lib/generators/templates/create_rails_api_logger_table.rb.tt
rails_api_logger-0.2.5 lib/generators/templates/create_rails_api_logger_table.rb.tt
rails_api_logger-0.2.4 lib/generators/templates/create_rails_api_logger_table.rb.tt
rails_api_logger-0.2.3 lib/generators/templates/create_rails_api_logger_table.rb.tt
rails_api_logger-0.2.2 lib/generators/templates/create_rails_api_logger_table.rb.tt
rails_api_logger-0.2.1 lib/generators/templates/create_rails_api_logger_table.rb.tt
rails_api_logger-0.2.0 lib/generators/templates/create_rails_api_logger_table.rb.tt
rails_api_logger-0.1.1 lib/generators/templates/create_rails_api_logger_table.rb.tt