Commit 3c8ef22d authored by Etienne Baqué's avatar Etienne Baqué Committed by Stan Hu

Readding state column for members table

Changelog: added
parent bcfd7848
# frozen_string_literal: true
class AddStateToMember < ActiveRecord::Migration[6.1]
include Gitlab::Database::MigrationHelpers
def up
unless column_exists?(:members, :state)
with_lock_retries do
add_column :members, :state, :integer, limit: 2, default: 0
end
end
end
def down
if column_exists?(:members, :state)
with_lock_retries do
remove_column :members, :state
end
end
end
end
54f7c66eed745b62d0b53a407a96721f90392ab7f800db9c8a2607f22974ef3c
\ No newline at end of file
...@@ -14873,7 +14873,8 @@ CREATE TABLE members ( ...@@ -14873,7 +14873,8 @@ CREATE TABLE members (
requested_at timestamp without time zone, requested_at timestamp without time zone,
expires_at date, expires_at date,
ldap boolean DEFAULT false NOT NULL, ldap boolean DEFAULT false NOT NULL,
override boolean DEFAULT false NOT NULL override boolean DEFAULT false NOT NULL,
state smallint DEFAULT 0
); );
CREATE SEQUENCE members_id_seq CREATE SEQUENCE members_id_seq
...@@ -333,6 +333,9 @@ excluded_attributes: ...@@ -333,6 +333,9 @@ excluded_attributes:
project_members: project_members:
- :source_id - :source_id
- :invite_email_success - :invite_email_success
- :state
group_members:
- :state
metrics: metrics:
- :merge_request_id - :merge_request_id
- :pipeline_id - :pipeline_id
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment