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

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSean McGivern <sean@gitlab.com>2019-04-02 11:39:53 +0300
committerSean McGivern <sean@gitlab.com>2019-04-02 11:39:53 +0300
commitf87b7fe3b386962c45e83486634352da544857fb (patch)
tree4c3fc969e0306e9877d22f787e8064126bfdef75 /db/migrate
parent5ddd4f0f0708921ca0c8a9a941cfb4c0fb868b00 (diff)
parentf2b7da4bf507691cffd419d3dd759fcf6311cdd6 (diff)
Merge branch 'issue_51789_part_1' into 'master'
Migrate issuable states to integer patch 1 of 2 Closes #51789 See merge request gitlab-org/gitlab-ce!25107
Diffstat (limited to 'db/migrate')
-rw-r--r--db/migrate/20190211131150_add_state_id_to_issuables.rb17
1 files changed, 17 insertions, 0 deletions
diff --git a/db/migrate/20190211131150_add_state_id_to_issuables.rb b/db/migrate/20190211131150_add_state_id_to_issuables.rb
new file mode 100644
index 00000000000..c1173eb4249
--- /dev/null
+++ b/db/migrate/20190211131150_add_state_id_to_issuables.rb
@@ -0,0 +1,17 @@
+# frozen_string_literal: true
+
+class AddStateIdToIssuables < ActiveRecord::Migration[5.0]
+ include Gitlab::Database::MigrationHelpers
+
+ DOWNTIME = false
+
+ def up
+ add_column :issues, :state_id, :integer, limit: 2
+ add_column :merge_requests, :state_id, :integer, limit: 2
+ end
+
+ def down
+ remove_column :issues, :state_id
+ remove_column :merge_requests, :state_id
+ end
+end