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

20210729081739_create_project_topics.rb « migrate « db - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: cbb8842f6536328904870c0c67230dcf9041a49d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
# frozen_string_literal: true

class CreateProjectTopics < ActiveRecord::Migration[6.1]
  def change
    create_table :project_topics do |t|
      t.bigint :project_id, null: false
      t.bigint :topic_id, null: false

      t.index :project_id
      t.index :topic_id
      t.index [:project_id, :topic_id], unique: true

      t.timestamps_with_timezone
    end
  end
end