feat(email): require verified approval email

Backfill approved legacy users with verified emails and replace the old unverified-email warning setting with a single approval email policy.
This commit is contained in:
2026-05-06 22:12:23 +08:00
parent a17a913618
commit ce55cfc6b3
18 changed files with 328 additions and 55 deletions
+2 -2
View File
@@ -16,8 +16,8 @@ class EmailNotificationSettingsBase(BaseModel):
require_admin_approval_for_registration: bool = Field(
True, description="新注册是否需要管理员审批"
)
warn_unverified_email_before_approval: bool = Field(
True, description="审批未验证邮箱用户时是否警告"
require_verified_email_for_approval: bool = Field(
True, description="审批前是否要求用户完成邮箱验证"
)
@field_validator("smtp_server", "smtp_sender_email", mode="before")