Skip to content
This repository has been archived by the owner on Sep 28, 2020. It is now read-only.

Config changes for exposing OOO feature in status dropdown #34

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions config/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ func GenerateClientConfig(c *model.Config, diagnosticId string, license *model.L
props["GfycatApiKey"] = *c.ServiceSettings.GfycatApiKey
props["GfycatApiSecret"] = *c.ServiceSettings.GfycatApiSecret
props["MaxFileSize"] = strconv.FormatInt(*c.FileSettings.MaxFileSize, 10)
props["ShowOutOfOfficeInStatusDropdown"] = strconv.FormatBool(*c.ServiceSettings.ShowOutOfOfficeInStatusDropdown)

props["MaxNotificationsPerChannel"] = strconv.FormatInt(*c.TeamSettings.MaxNotificationsPerChannel, 10)
props["EnableConfirmNotificationsToChannel"] = strconv.FormatBool(*c.TeamSettings.EnableConfirmNotificationsToChannel)
Expand Down
5 changes: 5 additions & 0 deletions model/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -310,6 +310,7 @@ type ServiceSettings struct {
DisableBotsWhenOwnerIsDeactivated *bool `restricted:"true"`
EnableBotAccountCreation *bool
EnableSVGs *bool
ShowOutOfOfficeInStatusDropdown *bool
}

func (s *ServiceSettings) SetDefaults(isUpdate bool) {
Expand Down Expand Up @@ -678,6 +679,10 @@ func (s *ServiceSettings) SetDefaults(isUpdate bool) {
s.EnableSVGs = NewBool(false)
}
}

if s.ShowOutOfOfficeInStatusDropdown == nil {
s.ShowOutOfOfficeInStatusDropdown = NewBool(false)
}
}

type ClusterSettings struct {
Expand Down