diff options
author | Matija Čupić <matteeyah@gmail.com> | 2018-01-26 17:06:52 +0100 |
---|---|---|
committer | Matija Čupić <matteeyah@gmail.com> | 2018-01-26 23:14:37 +0100 |
commit | 89ea6a9931bb232bd391ff4dace6e13deb6dee0c (patch) | |
tree | 1f64818d116b724ec654df69cac7b13afd47031d /db | |
parent | 4376be84ce18cde22febc50356ad254b507eef1b (diff) | |
download | gitlab-ce-89ea6a9931bb232bd391ff4dace6e13deb6dee0c.tar.gz |
Add Callout model
Diffstat (limited to 'db')
-rw-r--r-- | db/migrate/20180125214301_create_callouts.rb | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/db/migrate/20180125214301_create_callouts.rb b/db/migrate/20180125214301_create_callouts.rb new file mode 100644 index 00000000000..5dc9638a845 --- /dev/null +++ b/db/migrate/20180125214301_create_callouts.rb @@ -0,0 +1,19 @@ +# See http://doc.gitlab.com/ce/development/migration_style_guide.html +# for more information on how to write migrations for GitLab. + +class CreateCallouts < ActiveRecord::Migration + # Set this constant to true if this migration requires downtime. + DOWNTIME = false + + def change + create_table :callouts do |t| + t.string :feature_name, null: false + t.boolean :dismissed_state, null: false + t.references :user, index: true, foreign_key: { on_delete: :cascade }, null: false + + t.timestamps_with_timezone null: false + end + + add_index :callouts, :feature_name, unique: true + end +end |