Welcome to mirror list, hosted at ThFree Co, Russian Federation.

20170827222357_remove_rails_admin_histories.rb « migrate « db - github.com/diaspora/diaspora.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 7c914cb8b3ab3990545f2eeb717abf067c470acb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
# frozen_string_literal: true

class RemoveRailsAdminHistories < ActiveRecord::Migration[5.1]
  def up
    drop_table :rails_admin_histories
  end

  def down
    create_table :rails_admin_histories do |t|
      t.text     :message
      t.string   :username
      t.integer  :item
      t.string   :table
      t.integer  :month,      limit: 2
      t.integer  :year,       limit: 8
      t.datetime :created_at,           null: false
      t.datetime :updated_at,           null: false
    end

    add_index :rails_admin_histories, %i[item table month year], name:   :index_rails_admin_histories,
                                                                 length: {table: 188}
  end
end