merge: 合并 upstream/main 并解决冲突
解决了以下文件的冲突: - backend/internal/handler/admin/setting_handler.go - 采用 upstream 的字段对齐风格和 *Configured 字段名 - 添加 EnableIdentityPatch 和 IdentityPatchPrompt 字段 - backend/internal/handler/gateway_handler.go - 采用 upstream 的 billingErrorDetails 错误处理方式 - frontend/src/api/admin/settings.ts - 采用 upstream 的 *_configured 字段名 - 添加 enable_identity_patch 和 identity_patch_prompt 字段 - frontend/src/views/admin/SettingsView.vue - 合并 turnstile_secret_key_configured 字段 - 保留 enable_identity_patch 和 identity_patch_prompt 字段
This commit is contained in:
@@ -217,6 +217,7 @@ export default {
|
||||
registrationFailed: 'Registration failed. Please try again.',
|
||||
loginSuccess: 'Login successful! Welcome back.',
|
||||
accountCreatedSuccess: 'Account created successfully! Welcome to {siteName}.',
|
||||
reloginRequired: 'Session expired. Please log in again.',
|
||||
turnstileExpired: 'Verification expired, please try again',
|
||||
turnstileFailed: 'Verification failed, please try again',
|
||||
completeVerification: 'Please complete the verification',
|
||||
@@ -1162,13 +1163,13 @@ export default {
|
||||
'One sessionKey per line, e.g.:\nsk-ant-sid01-xxxxx...\nsk-ant-sid01-yyyyy...',
|
||||
sessionKeyPlaceholderSingle: 'sk-ant-sid01-xxxxx...',
|
||||
howToGetSessionKey: 'How to get sessionKey',
|
||||
step1: 'Login to <strong>claude.ai</strong> in your browser',
|
||||
step2: 'Press <kbd>F12</kbd> to open Developer Tools',
|
||||
step3: 'Go to <strong>Application</strong> tab',
|
||||
step4: 'Find <strong>Cookies</strong> → <strong>https://claude.ai</strong>',
|
||||
step5: 'Find the row with key <strong>sessionKey</strong>',
|
||||
step6: 'Copy the <strong>Value</strong>',
|
||||
sessionKeyFormat: 'sessionKey usually starts with <code>sk-ant-sid01-</code>',
|
||||
step1: 'Login to claude.ai in your browser',
|
||||
step2: 'Press F12 to open Developer Tools',
|
||||
step3: 'Go to Application tab',
|
||||
step4: 'Find Cookies → https://claude.ai',
|
||||
step5: 'Find the row with key sessionKey',
|
||||
step6: 'Copy the Value',
|
||||
sessionKeyFormat: 'sessionKey usually starts with sk-ant-sid01-',
|
||||
startAutoAuth: 'Start Auto-Auth',
|
||||
authorizing: 'Authorizing...',
|
||||
followSteps: 'Follow these steps to authorize your Claude account:',
|
||||
@@ -1180,10 +1181,10 @@ export default {
|
||||
openUrlDesc:
|
||||
'Open the authorization URL in a new tab, log in to your Claude account and authorize.',
|
||||
proxyWarning:
|
||||
'<strong>Note:</strong> If you configured a proxy, make sure your browser uses the same proxy to access the authorization page.',
|
||||
'Note: If you configured a proxy, make sure your browser uses the same proxy to access the authorization page.',
|
||||
step3EnterCode: 'Enter the Authorization Code',
|
||||
authCodeDesc:
|
||||
'After authorization is complete, the page will display an <strong>Authorization Code</strong>. Copy and paste it below:',
|
||||
'After authorization is complete, the page will display an Authorization Code. Copy and paste it below:',
|
||||
authCode: 'Authorization Code',
|
||||
authCodePlaceholder: 'Paste the Authorization Code from Claude page...',
|
||||
authCodeHint: 'Paste the Authorization Code copied from the Claude page',
|
||||
@@ -1204,10 +1205,10 @@ export default {
|
||||
openUrlDesc:
|
||||
'Open the authorization URL in a new tab, log in to your OpenAI account and authorize.',
|
||||
importantNotice:
|
||||
'<strong>Important:</strong> The page may take a while to load after authorization. Please wait patiently. When the browser address bar changes to <code>http://localhost...</code>, the authorization is complete.',
|
||||
'Important: The page may take a while to load after authorization. Please wait patiently. When the browser address bar changes to http://localhost..., the authorization is complete.',
|
||||
step3EnterCode: 'Enter Authorization URL or Code',
|
||||
authCodeDesc:
|
||||
'After authorization is complete, when the page URL becomes <code>http://localhost:xxx/auth/callback?code=...</code>:',
|
||||
'After authorization is complete, when the page URL becomes http://localhost:xxx/auth/callback?code=...:',
|
||||
authCode: 'Authorization URL or Code',
|
||||
authCodePlaceholder:
|
||||
'Option 1: Copy the complete URL\n(http://localhost:xxx/auth/callback?code=...)\nOption 2: Copy only the code parameter value',
|
||||
@@ -1230,7 +1231,7 @@ export default {
|
||||
'Open the authorization URL in a new tab, log in to your Google account and authorize.',
|
||||
step3EnterCode: 'Enter Authorization URL or Code',
|
||||
authCodeDesc:
|
||||
'After authorization, copy the callback URL (recommended) or just the <code>code</code> and paste it below.',
|
||||
'After authorization, copy the callback URL (recommended) or just the code and paste it below.',
|
||||
authCode: 'Callback URL or Code',
|
||||
authCodePlaceholder:
|
||||
'Option 1 (recommended): Paste the callback URL\nOption 2: Paste only the code value',
|
||||
@@ -1272,10 +1273,10 @@ export default {
|
||||
step2OpenUrl: 'Open the URL in your browser and complete authorization',
|
||||
openUrlDesc: 'Open the authorization URL in a new tab, log in to your Google account and authorize.',
|
||||
importantNotice:
|
||||
'<strong>Important:</strong> The page may take a while to load after authorization. Please wait patiently. When the browser address bar shows <code>http://localhost...</code>, authorization is complete.',
|
||||
'Important: The page may take a while to load after authorization. Please wait patiently. When the browser address bar shows http://localhost..., authorization is complete.',
|
||||
step3EnterCode: 'Enter Authorization URL or Code',
|
||||
authCodeDesc:
|
||||
'After authorization, when the page URL becomes <code>http://localhost:xxx/auth/callback?code=...</code>:',
|
||||
'After authorization, when the page URL becomes http://localhost:xxx/auth/callback?code=...:',
|
||||
authCode: 'Authorization URL or Code',
|
||||
authCodePlaceholder:
|
||||
'Option 1: Copy the complete URL\n(http://localhost:xxx/auth/callback?code=...)\nOption 2: Copy only the code parameter value',
|
||||
@@ -1699,8 +1700,8 @@ export default {
|
||||
secretKey: 'Secret Key',
|
||||
siteKeyHint: 'Get this from your Cloudflare Dashboard',
|
||||
cloudflareDashboard: 'Cloudflare Dashboard',
|
||||
secretKeyHint: 'Server-side verification key (keep this secret)'
|
||||
},
|
||||
secretKeyHint: 'Server-side verification key (keep this secret)',
|
||||
secretKeyConfiguredHint: 'Secret key configured. Leave empty to keep the current value.' },
|
||||
defaults: {
|
||||
title: 'Default User Settings',
|
||||
description: 'Default values for new users',
|
||||
@@ -1750,6 +1751,8 @@ export default {
|
||||
password: 'SMTP Password',
|
||||
passwordPlaceholder: '********',
|
||||
passwordHint: 'Leave empty to keep existing password',
|
||||
passwordConfiguredPlaceholder: '********',
|
||||
passwordConfiguredHint: 'Password configured. Leave empty to keep the current value.',
|
||||
fromEmail: 'From Email',
|
||||
fromEmailPlaceholder: "noreply{'@'}example.com",
|
||||
fromName: 'From Name',
|
||||
|
||||
@@ -215,6 +215,7 @@ export default {
|
||||
registrationFailed: '注册失败,请重试。',
|
||||
loginSuccess: '登录成功!欢迎回来。',
|
||||
accountCreatedSuccess: '账户创建成功!欢迎使用 {siteName}。',
|
||||
reloginRequired: '会话已过期,请重新登录。',
|
||||
turnstileExpired: '验证已过期,请重试',
|
||||
turnstileFailed: '验证失败,请重试',
|
||||
completeVerification: '请完成验证',
|
||||
@@ -1296,13 +1297,13 @@ export default {
|
||||
'每行一个 sessionKey,例如:\nsk-ant-sid01-xxxxx...\nsk-ant-sid01-yyyyy...',
|
||||
sessionKeyPlaceholderSingle: 'sk-ant-sid01-xxxxx...',
|
||||
howToGetSessionKey: '如何获取 sessionKey',
|
||||
step1: '在浏览器中登录 <strong>claude.ai</strong>',
|
||||
step2: '按 <kbd>F12</kbd> 打开开发者工具',
|
||||
step3: '切换到 <strong>Application</strong> 标签',
|
||||
step4: '找到 <strong>Cookies</strong> → <strong>https://claude.ai</strong>',
|
||||
step5: '找到 <strong>sessionKey</strong> 所在行',
|
||||
step6: '复制 <strong>Value</strong> 列的值',
|
||||
sessionKeyFormat: 'sessionKey 通常以 <code>sk-ant-sid01-</code> 开头',
|
||||
step1: '在浏览器中登录 claude.ai',
|
||||
step2: '按 F12 打开开发者工具',
|
||||
step3: '切换到 Application 标签',
|
||||
step4: '找到 Cookies → https://claude.ai',
|
||||
step5: '找到 sessionKey 所在行',
|
||||
step6: '复制 Value 列的值',
|
||||
sessionKeyFormat: 'sessionKey 通常以 sk-ant-sid01- 开头',
|
||||
startAutoAuth: '开始自动授权',
|
||||
authorizing: '授权中...',
|
||||
followSteps: '按照以下步骤授权您的 Claude 账号:',
|
||||
@@ -1313,9 +1314,9 @@ export default {
|
||||
step2OpenUrl: '在浏览器中打开 URL 并完成授权',
|
||||
openUrlDesc: '在新标签页中打开授权 URL,登录您的 Claude 账号并授权。',
|
||||
proxyWarning:
|
||||
'<strong>注意:</strong>如果您配置了代理,请确保浏览器使用相同的代理访问授权页面。',
|
||||
'注意:如果您配置了代理,请确保浏览器使用相同的代理访问授权页面。',
|
||||
step3EnterCode: '输入授权码',
|
||||
authCodeDesc: '授权完成后,页面会显示一个 <strong>授权码</strong>。复制并粘贴到下方:',
|
||||
authCodeDesc: '授权完成后,页面会显示一个授权码。复制并粘贴到下方:',
|
||||
authCode: '授权码',
|
||||
authCodePlaceholder: '粘贴 Claude 页面的授权码...',
|
||||
authCodeHint: '粘贴从 Claude 页面复制的授权码',
|
||||
@@ -1335,10 +1336,10 @@ export default {
|
||||
step2OpenUrl: '在浏览器中打开链接并完成授权',
|
||||
openUrlDesc: '请在新标签页中打开授权链接,登录您的 OpenAI 账户并授权。',
|
||||
importantNotice:
|
||||
'<strong>重要提示:</strong>授权后页面可能会加载较长时间,请耐心等待。当浏览器地址栏变为 <code>http://localhost...</code> 开头时,表示授权已完成。',
|
||||
'重要提示:授权后页面可能会加载较长时间,请耐心等待。当浏览器地址栏变为 http://localhost... 开头时,表示授权已完成。',
|
||||
step3EnterCode: '输入授权链接或 Code',
|
||||
authCodeDesc:
|
||||
'授权完成后,当页面地址变为 <code>http://localhost:xxx/auth/callback?code=...</code> 时:',
|
||||
'授权完成后,当页面地址变为 http://localhost:xxx/auth/callback?code=... 时:',
|
||||
authCode: '授权链接或 Code',
|
||||
authCodePlaceholder:
|
||||
'方式1:复制完整的链接\n(http://localhost:xxx/auth/callback?code=...)\n方式2:仅复制 code 参数的值',
|
||||
@@ -1357,7 +1358,7 @@ export default {
|
||||
step2OpenUrl: '在浏览器中打开链接并完成授权',
|
||||
openUrlDesc: '请在新标签页中打开授权链接,登录您的 Google 账户并授权。',
|
||||
step3EnterCode: '输入回调链接或 Code',
|
||||
authCodeDesc: '授权完成后,复制浏览器跳转后的回调链接(推荐)或仅复制 <code>code</code>,粘贴到下方即可。',
|
||||
authCodeDesc: '授权完成后,复制浏览器跳转后的回调链接(推荐)或仅复制 code,粘贴到下方即可。',
|
||||
authCode: '回调链接或 Code',
|
||||
authCodePlaceholder: '方式1(推荐):粘贴回调链接\n方式2:仅粘贴 code 参数的值',
|
||||
authCodeHint: '系统会自动从链接中解析 code/state。',
|
||||
@@ -1393,10 +1394,10 @@ export default {
|
||||
step2OpenUrl: '在浏览器中打开链接并完成授权',
|
||||
openUrlDesc: '请在新标签页中打开授权链接,登录您的 Google 账户并授权。',
|
||||
importantNotice:
|
||||
'<strong>重要提示:</strong>授权后页面可能会加载较长时间,请耐心等待。当浏览器地址栏变为 <code>http://localhost...</code> 开头时,表示授权已完成。',
|
||||
'重要提示:授权后页面可能会加载较长时间,请耐心等待。当浏览器地址栏变为 http://localhost... 开头时,表示授权已完成。',
|
||||
step3EnterCode: '输入授权链接或 Code',
|
||||
authCodeDesc:
|
||||
'授权完成后,当页面地址变为 <code>http://localhost:xxx/auth/callback?code=...</code> 时:',
|
||||
'授权完成后,当页面地址变为 http://localhost:xxx/auth/callback?code=... 时:',
|
||||
authCode: '授权链接或 Code',
|
||||
authCodePlaceholder:
|
||||
'方式1:复制完整的链接\n(http://localhost:xxx/auth/callback?code=...)\n方式2:仅复制 code 参数的值',
|
||||
@@ -1845,8 +1846,8 @@ export default {
|
||||
secretKey: '私密密钥',
|
||||
siteKeyHint: '从 Cloudflare Dashboard 获取',
|
||||
cloudflareDashboard: 'Cloudflare Dashboard',
|
||||
secretKeyHint: '服务端验证密钥(请保密)'
|
||||
},
|
||||
secretKeyHint: '服务端验证密钥(请保密)',
|
||||
secretKeyConfiguredHint: '密钥已配置,留空以保留当前值。' },
|
||||
defaults: {
|
||||
title: '用户默认设置',
|
||||
description: '新用户的默认值',
|
||||
@@ -1895,6 +1896,8 @@ export default {
|
||||
password: 'SMTP 密码',
|
||||
passwordPlaceholder: '********',
|
||||
passwordHint: '留空以保留现有密码',
|
||||
passwordConfiguredPlaceholder: '********',
|
||||
passwordConfiguredHint: '密码已配置,留空以保留当前值。',
|
||||
fromEmail: '发件人邮箱',
|
||||
fromEmailPlaceholder: "noreply{'@'}example.com",
|
||||
fromName: '发件人名称',
|
||||
|
||||
Reference in New Issue
Block a user