summaryrefslogtreecommitdiff
path: root/db/migrate/20210217101901_create_epic_list_user_preferences.rb
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2021-03-12 16:26:10 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2021-03-12 16:26:10 +0000
commit6653ccc011dec86e5140a5d09ea3b2357eab6714 (patch)
tree897193f37bcd98152a0ac214f80a3c4cfe1047c5 /db/migrate/20210217101901_create_epic_list_user_preferences.rb
parentbff35a05aed6a31380a73c39113808fd262c2c37 (diff)
downloadgitlab-ce-6653ccc011dec86e5140a5d09ea3b2357eab6714.tar.gz
Add latest changes from gitlab-org/gitlab@13-10-stable-eev13.10.0-rc41
Diffstat (limited to 'db/migrate/20210217101901_create_epic_list_user_preferences.rb')
-rw-r--r--db/migrate/20210217101901_create_epic_list_user_preferences.rb20
1 files changed, 20 insertions, 0 deletions
diff --git a/db/migrate/20210217101901_create_epic_list_user_preferences.rb b/db/migrate/20210217101901_create_epic_list_user_preferences.rb
new file mode 100644
index 00000000000..5aacea1938d
--- /dev/null
+++ b/db/migrate/20210217101901_create_epic_list_user_preferences.rb
@@ -0,0 +1,20 @@
+# frozen_string_literal: true
+
+class CreateEpicListUserPreferences < ActiveRecord::Migration[6.0]
+ DOWNTIME = false
+
+ def up
+ create_table :boards_epic_list_user_preferences do |t|
+ t.bigint :user_id, null: false
+ t.bigint :epic_list_id, index: true, null: false
+ t.timestamps_with_timezone null: false
+ t.boolean :collapsed, null: false, default: false
+ end
+
+ add_index :boards_epic_list_user_preferences, [:user_id, :epic_list_id], unique: true, name: 'index_epic_board_list_preferences_on_user_and_list'
+ end
+
+ def down
+ drop_table :boards_epic_list_user_preferences
+ end
+end