mirror of
https://gitlink.org.cn/Gitlink/forgeplus.git
synced 2026-05-22 04:35:45 +08:00
[ADD]organization add num_teams
This commit is contained in:
@@ -14,6 +14,7 @@
|
||||
# updated_at :datetime not null
|
||||
# num_projects :integer default("0")
|
||||
# num_users :integer default("0")
|
||||
# num_teams :integer default("0")
|
||||
#
|
||||
# Indexes
|
||||
#
|
||||
@@ -25,6 +26,7 @@ class OrganizationExtension < ApplicationRecord
|
||||
belongs_to :organization
|
||||
has_many :organization_users, foreign_key: :organization_id, primary_key: :organization_id
|
||||
has_many :projects, foreign_key: :user_id, primary_key: :organization_id
|
||||
has_many :teams, foreign_key: :organization_id, primary_key: :organization_id
|
||||
|
||||
enum visibility: {common: 0, limited: 1, privacy: 2}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user