feat: 支持按项目配置钉钉通知 @ 名单
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
a4cd855b0c
commit
10c39b5116
@@ -24,6 +24,7 @@ from ..config import (
|
||||
SKINS_DIR,
|
||||
)
|
||||
from ..deps import get_current_user, require_admin
|
||||
from ..services.notification import AT_MOBILES_KEYS, normalize_mobiles
|
||||
from ..projects import (
|
||||
DEFINITION_KEYS,
|
||||
LEGACY_PROJECT_DEFINITION,
|
||||
@@ -1376,6 +1377,11 @@ def _apply_definition(project: dict, data: dict, existing_git: dict = None):
|
||||
project[fields_key] = _clean_fields(data[fields_key], fields_key)
|
||||
if "obfuscation" in data:
|
||||
project["obfuscation"] = bool(data["obfuscation"])
|
||||
if "dingtalk_at" in data:
|
||||
dingtalk_at = data["dingtalk_at"] or {}
|
||||
if not isinstance(dingtalk_at, dict):
|
||||
raise HTTPException(status_code=400, detail="dingtalk_at 必须是对象")
|
||||
project["dingtalk_at"] = {key: normalize_mobiles(dingtalk_at.get(key)) for key in AT_MOBILES_KEYS}
|
||||
|
||||
xcode = project.get("xcode") or {}
|
||||
if not xcode.get("workspace") and not xcode.get("project"):
|
||||
|
||||
Reference in New Issue
Block a user