♻️(features) rename "TEAMS" flag

To match recent changes we rename the "TEAMS" feature flag
to "TEAMS_DISPLAY".
This commit is contained in:
Quentin BEY
2024-11-14 14:20:10 +01:00
committed by BEY Quentin
parent 59f3499799
commit 90a3e26c7f
12 changed files with 38 additions and 18 deletions

View File

@@ -487,7 +487,7 @@ class User(AbstractBaseUser, BaseModel, auth_models.PermissionsMixin):
),
},
"teams": {
"can_view": teams_can_view and settings.FEATURES["TEAMS"],
"can_view": teams_can_view and settings.FEATURES["TEAMS_DISPLAY"],
"can_create": teams_can_view and settings.FEATURES["TEAMS_CREATE"],
},
"mailboxes": {

View File

@@ -24,7 +24,7 @@ def test_api_config_anonymous():
"CONTACTS_DISPLAY": True,
"CONTACTS_CREATE": True,
"MAILBOXES_CREATE": True,
"TEAMS": True,
"TEAMS_DISPLAY": True,
"TEAMS_CREATE": True,
},
"RELEASE": "NA",
@@ -46,7 +46,7 @@ def test_api_config_authenticated():
"CONTACTS_DISPLAY": True,
"CONTACTS_CREATE": True,
"MAILBOXES_CREATE": True,
"TEAMS": True,
"TEAMS_DISPLAY": True,
"TEAMS_CREATE": True,
},
"RELEASE": "NA",

View File

@@ -465,7 +465,7 @@ class Base(Configuration):
"CONTACTS_CREATE", # Used in the users/me/ endpoint
"CONTACTS_DISPLAY", # Used in the users/me/ endpoint
"MAILBOXES_CREATE", # Used in the users/me/ endpoint
"TEAMS",
"TEAMS_DISPLAY",
"TEAMS_CREATE", # Used in the users/me/ endpoint
}