feat(devices): add landing page for desktop client

master
Aaron Liu 5 days ago
parent c99a4ece90
commit 1c5eefdc6a

@ -668,6 +668,7 @@ var DefaultSettings = map[string]string{
"encrypt_master_key_vault": "setting",
"encrypt_master_key_file": "",
"show_encryption_status": "1",
"show_desktop_app_promotion": "1",
}
var RedactedSettings = map[string]struct{}{

@ -319,7 +319,8 @@ func (s *settingProvider) FileViewers(ctx context.Context) []types.ViewerGroup {
func (s *settingProvider) AppSetting(ctx context.Context) *AppSetting {
return &AppSetting{
Promotion: s.getBoolean(ctx, "show_app_promotion", false),
Promotion: s.getBoolean(ctx, "show_app_promotion", false),
DesktopPromotion: s.getBoolean(ctx, "show_desktop_app_promotion", false),
}
}

@ -192,7 +192,8 @@ const (
)
type AppSetting struct {
Promotion bool
Promotion bool
DesktopPromotion bool
}
type EmailTemplate struct {

@ -59,7 +59,8 @@ type SiteConfig struct {
ThumbExts []string `json:"thumb_exts,omitempty"`
// App settings
AppPromotion bool `json:"app_promotion,omitempty"`
AppPromotion bool `json:"app_promotion,omitempty"`
DesktopAppPromotion bool `json:"desktop_app_promotion,omitempty"`
//EmailActive bool `json:"emailActive"`
//QQLogin bool `json:"QQLogin"`
@ -128,7 +129,8 @@ func (s *GetSettingService) GetSiteConfig(c *gin.Context) (*SiteConfig, error) {
case "app":
appSetting := settings.AppSetting(c)
return &SiteConfig{
AppPromotion: appSetting.Promotion,
AppPromotion: appSetting.Promotion,
DesktopAppPromotion: appSetting.DesktopPromotion,
}, nil
case "thumb":
// Return supported thumbnail extensions from enabled generators.

Loading…
Cancel
Save