feat: Bulk add team members in Team APIs (#1695)
This commit is contained in:
@@ -0,0 +1,6 @@
|
||||
class AdduniqueIndexToTeamMembers < ActiveRecord::Migration[6.0]
|
||||
def change
|
||||
add_index :teams, [:name, :account_id], unique: true
|
||||
add_index :team_members, [:team_id, :user_id], unique: true
|
||||
end
|
||||
end
|
||||
@@ -10,7 +10,7 @@
|
||||
#
|
||||
# It's strongly recommended that you check this file into your version control system.
|
||||
|
||||
ActiveRecord::Schema.define(version: 2021_01_14_202310) do
|
||||
ActiveRecord::Schema.define(version: 2021_01_26_121313) do
|
||||
|
||||
# These are extensions that must be enabled in order to support this database
|
||||
enable_extension "pg_stat_statements"
|
||||
@@ -498,6 +498,7 @@ ActiveRecord::Schema.define(version: 2021_01_14_202310) do
|
||||
t.bigint "user_id", null: false
|
||||
t.datetime "created_at", precision: 6, null: false
|
||||
t.datetime "updated_at", precision: 6, null: false
|
||||
t.index ["team_id", "user_id"], name: "index_team_members_on_team_id_and_user_id", unique: true
|
||||
t.index ["team_id"], name: "index_team_members_on_team_id"
|
||||
t.index ["user_id"], name: "index_team_members_on_user_id"
|
||||
end
|
||||
@@ -510,6 +511,7 @@ ActiveRecord::Schema.define(version: 2021_01_14_202310) do
|
||||
t.datetime "created_at", precision: 6, null: false
|
||||
t.datetime "updated_at", precision: 6, null: false
|
||||
t.index ["account_id"], name: "index_teams_on_account_id"
|
||||
t.index ["name", "account_id"], name: "index_teams_on_name_and_account_id", unique: true
|
||||
end
|
||||
|
||||
create_table "telegram_bots", id: :serial, force: :cascade do |t|
|
||||
|
||||
Reference in New Issue
Block a user