mirror of
https://github.com/Rain-kl/OpenFlare.git
synced 2026-09-29 22:06:38 +08:00
6a53619dd2
将平台域持久化收敛为 repository 唯一入口,model 去掉 IO。 邮件头写入前清除 CR/LF,防止 header 注入。 httppool 支持可配置 Transport;batchwriter 增加 MinBatchSize/Stats,flush 失败交回批次;任务 PermanentError 作为 SkipRetry 终态。 设置与推送页的确认改为 AlertDialog;axios 去尾斜杠并按 Gin 数组序列化查询参数。 升级共享 Go 依赖(Gin、Asynq、OTel、GORM、Redis 等)。
18 lines
1.0 KiB
Go
18 lines
1.0 KiB
Go
// Copyright 2026 Arctel.net
|
|
// SPDX-License-Identifier: Apache-2.0
|
|
|
|
package model
|
|
|
|
// Domain validation messages used by model.Validate and other no-IO rules.
|
|
// Persistence / data-access messages belong in internal/repository (do not import repository).
|
|
const (
|
|
errTemplateKeyRequired = "模板标识符不能为空"
|
|
errTemplateNameRequired = "模板名称不能为空"
|
|
errTemplateContentRequired = "模板内容不能为空"
|
|
errAuthSourceNameRequired = "认证源名称不能为空"
|
|
errAuthSourceNameInvalid = "认证源名称只能包含字母、数字、短横线或下划线,且必须以字母或数字开头"
|
|
errAuthSourceTypeUnsupported = "认证源类型仅支持 oidc"
|
|
errAuthSourceDiscoveryURLRequired = "OIDC 认证源必须配置 Discovery URL"
|
|
errAuthSourceClientCredentialsRequired = "启用认证源前必须配置 Client ID 和 Client Secret" //nolint:gosec // false positive: this is an error message, not hardcoded credentials
|
|
)
|