feat: 接入真实登录与成员权限
- auth/members/messages: 新增超级管理员登录、成员权限和密码消息流程 - agent-config/agent: 支持服务端保存 Agent 配置并取消未配置 mock 成功结果 - projects/deploy-runs/settings: 按当前用户权限保护真实接口 - prisma: 新增用户、项目权限和平台消息表结构
This commit is contained in:
@@ -43,7 +43,7 @@ export class DeployNotificationService {
|
||||
if (!provider) {
|
||||
return {
|
||||
status: 'not_configured',
|
||||
message: 'Missing NOTIFICATION_PROVIDER',
|
||||
message: '缺少 NOTIFICATION_PROVIDER',
|
||||
};
|
||||
}
|
||||
|
||||
@@ -63,7 +63,7 @@ export class DeployNotificationService {
|
||||
: {
|
||||
status: 'not_configured',
|
||||
provider,
|
||||
message: `Missing ${webhookKey}`,
|
||||
message: `缺少 ${webhookKey}`,
|
||||
};
|
||||
}
|
||||
|
||||
@@ -77,7 +77,7 @@ export class DeployNotificationService {
|
||||
return {
|
||||
status: 'skipped',
|
||||
channel: health.provider ?? 'none',
|
||||
reason: health.message ?? 'Notification provider is not configured',
|
||||
reason: health.message ?? '通知平台尚未配置',
|
||||
};
|
||||
}
|
||||
|
||||
@@ -85,7 +85,7 @@ export class DeployNotificationService {
|
||||
return {
|
||||
status: 'failed',
|
||||
channel: health.provider ?? 'none',
|
||||
reason: health.message ?? 'Notification provider is unavailable',
|
||||
reason: health.message ?? '通知平台不可用',
|
||||
};
|
||||
}
|
||||
|
||||
@@ -100,7 +100,7 @@ export class DeployNotificationService {
|
||||
reason:
|
||||
error instanceof Error
|
||||
? redactSensitive({ message: error.message }).message
|
||||
: 'Unknown notification error',
|
||||
: '未知通知错误',
|
||||
};
|
||||
}
|
||||
}
|
||||
@@ -196,7 +196,7 @@ export class DeployNotificationService {
|
||||
});
|
||||
|
||||
if (!response.ok) {
|
||||
throw new Error(`${provider} webhook request failed: ${response.status}`);
|
||||
throw new Error(`${provider} webhook 请求失败:${response.status}`);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user