增加SMTP中继开关与配置管理

新增中继启用控制、列表展示、编辑和清除逻辑,保留安全配置边界。
This commit is contained in:
xuans committed 2026-10-06 00:20:29 +08:00
1 parent e7d1f99420
commit d0890758a0
13 files changed
+332 -24

No files matched your search

+1
View File
@@ -288,6 +288,7 @@ func CurrentSMTPRuntimeSettings() (SMTPRuntimeSettings, error) {
return SMTPRuntimeSettings{}, fmt.Errorf("runtime configuration is unavailable")
}
settings.Relay = SMTPConfig{
RelayEnabled: cfg.SMTPHost != "" || cfg.SMTPPort != 0 || cfg.SMTPUsername != "" || cfg.SMTPFrom != "" || cfg.SMTPPassword != "",
RelayHost: cfg.SMTPHost,
RelayPort: cfg.SMTPPort,
Username: cfg.SMTPUsername,