MM-21290: Adds licensing feature for LockTeammateNameDisplay. (#13431)
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
f2a14ae976
Коммит
f8d31def8e
@@ -61,6 +61,7 @@ type Features struct {
|
|||||||
CustomTermsOfService *bool `json:"custom_terms_of_service"`
|
CustomTermsOfService *bool `json:"custom_terms_of_service"`
|
||||||
GuestAccountsPermissions *bool `json:"guest_accounts_permissions"`
|
GuestAccountsPermissions *bool `json:"guest_accounts_permissions"`
|
||||||
IDLoadedPushNotifications *bool `json:"id_loaded"`
|
IDLoadedPushNotifications *bool `json:"id_loaded"`
|
||||||
|
LockTeammateNameDisplay *bool `json:"lock_teammate_name_display"`
|
||||||
|
|
||||||
// after we enabled more features we'll need to control them with this
|
// after we enabled more features we'll need to control them with this
|
||||||
FutureFeatures *bool `json:"future_features"`
|
FutureFeatures *bool `json:"future_features"`
|
||||||
@@ -85,6 +86,7 @@ func (f *Features) ToMap() map[string]interface{} {
|
|||||||
"custom_permissions_schemes": *f.CustomPermissionsSchemes,
|
"custom_permissions_schemes": *f.CustomPermissionsSchemes,
|
||||||
"guest_accounts_permissions": *f.GuestAccountsPermissions,
|
"guest_accounts_permissions": *f.GuestAccountsPermissions,
|
||||||
"id_loaded": *f.IDLoadedPushNotifications,
|
"id_loaded": *f.IDLoadedPushNotifications,
|
||||||
|
"lock_teammate_name_display": *f.LockTeammateNameDisplay,
|
||||||
"future": *f.FutureFeatures,
|
"future": *f.FutureFeatures,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -177,6 +179,10 @@ func (f *Features) SetDefaults() {
|
|||||||
if f.IDLoadedPushNotifications == nil {
|
if f.IDLoadedPushNotifications == nil {
|
||||||
f.IDLoadedPushNotifications = NewBool(*f.FutureFeatures)
|
f.IDLoadedPushNotifications = NewBool(*f.FutureFeatures)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if f.LockTeammateNameDisplay == nil {
|
||||||
|
f.LockTeammateNameDisplay = NewBool(*f.FutureFeatures)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (l *License) IsExpired() bool {
|
func (l *License) IsExpired() bool {
|
||||||
|
|||||||
@@ -157,6 +157,7 @@ func GetClientLicense(l *model.License) map[string]string {
|
|||||||
props["CustomPermissionsSchemes"] = strconv.FormatBool(*l.Features.CustomPermissionsSchemes)
|
props["CustomPermissionsSchemes"] = strconv.FormatBool(*l.Features.CustomPermissionsSchemes)
|
||||||
props["GuestAccountsPermissions"] = strconv.FormatBool(*l.Features.GuestAccountsPermissions)
|
props["GuestAccountsPermissions"] = strconv.FormatBool(*l.Features.GuestAccountsPermissions)
|
||||||
props["CustomTermsOfService"] = strconv.FormatBool(*l.Features.CustomTermsOfService)
|
props["CustomTermsOfService"] = strconv.FormatBool(*l.Features.CustomTermsOfService)
|
||||||
|
props["LockTeammateNameDisplay"] = strconv.FormatBool(*l.Features.LockTeammateNameDisplay)
|
||||||
}
|
}
|
||||||
|
|
||||||
return props
|
return props
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user