Add shared channels related configuration under a E20 license check (#16415)

* Add shared channels related configuration under a E20 license check

* Apply PR suggestions; Default config value for shared channels

Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
Этот коммит содержится в:
John Tzikas
2020-12-10 11:25:38 +02:00
коммит произвёл GitHub
родитель 5d41bffe5e
Коммит 1fe003aa36
4 изменённых файлов: 28 добавлений и 1 удалений

Просмотреть файл

@@ -60,7 +60,6 @@ func GenerateClientConfig(c *model.Config, telemetryID string, license *model.Li
} else {
props["ExperimentalChannelOrganization"] = strconv.FormatBool(false)
}
props["ExperimentalSharedChannels"] = strconv.FormatBool(*c.ExperimentalSettings.EnableSharedChannels)
props["ExperimentalChannelSidebarOrganization"] = *c.ServiceSettings.ExperimentalChannelSidebarOrganization
props["ExperimentalEnableAutomaticReplies"] = strconv.FormatBool(*c.TeamSettings.ExperimentalEnableAutomaticReplies)
@@ -135,6 +134,7 @@ func GenerateClientConfig(c *model.Config, telemetryID string, license *model.Li
props["CustomUrlSchemes"] = strings.Join(c.DisplaySettings.CustomUrlSchemes, ",")
props["IsDefaultMarketplace"] = strconv.FormatBool(*c.PluginSettings.MarketplaceUrl == model.PLUGIN_SETTINGS_DEFAULT_MARKETPLACE_URL)
props["ExperimentalSharedChannels"] = "false"
if license != nil {
props["ExperimentalHideTownSquareinLHS"] = strconv.FormatBool(*c.TeamSettings.ExperimentalHideTownSquareinLHS)
@@ -199,6 +199,10 @@ func GenerateClientConfig(c *model.Config, telemetryID string, license *model.Li
if *license.Features.Cloud {
props["CWSUrl"] = *c.CloudSettings.CWSUrl
}
if *license.Features.SharedChannels {
props["ExperimentalSharedChannels"] = strconv.FormatBool(*c.ExperimentalSettings.EnableSharedChannels)
}
}
return props