standard plan add custom domain config (#6061)

* standard plan add custom domain config

* bill detail modal
This commit is contained in:
heheer 2025-12-09 14:40:25 +08:00 committed by GitHub
parent cba43c974a
commit 397ffc6c19
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
12 changed files with 44 additions and 6 deletions

View File

@ -12,6 +12,7 @@ export type CustomSubConfig = {
appRegistrationCount: number;
auditLogStoreDuration: number;
ticketResponseTime: number;
customDomain: number;
};
export type TeamCouponSub = {

View File

@ -20,6 +20,7 @@ export type TeamStandardSubPlanItemType = {
websiteSyncPerDataset?: number;
auditLogStoreDuration?: number;
ticketResponseTime?: number;
customDomain?: number;
// Custom plan specific fields
priceDescription?: string;
@ -73,6 +74,7 @@ export type TeamSubSchema = {
appRegistrationCount?: number;
auditLogStoreDuration?: number;
ticketResponseTime?: number;
customDomain?: number;
totalPoints: number;
surplusPoints: number;

View File

@ -64,6 +64,7 @@ const SubSchema = new Schema({
appRegistrationCount: Number,
auditLogStoreDuration: Number,
ticketResponseTime: Number,
customDomain: Number,
// stand sub and extra points sub. Plan total points
totalPoints: {

View File

@ -74,7 +74,8 @@ export const getTeamStandPlan = async ({ teamId }: { teamId: string }) => {
standard?.appRegistrationCount ?? standardConstants.appRegistrationCount,
auditLogStoreDuration:
standard?.auditLogStoreDuration ?? standardConstants.auditLogStoreDuration,
ticketResponseTime: standard?.ticketResponseTime ?? standardConstants.ticketResponseTime
ticketResponseTime: standard?.ticketResponseTime ?? standardConstants.ticketResponseTime,
customDomain: standard?.customDomain ?? standardConstants.customDomain
}
: undefined
};
@ -210,7 +211,8 @@ export const getTeamPlanStatus = async ({
auditLogStoreDuration:
standardPlan?.auditLogStoreDuration ?? standardConstants.auditLogStoreDuration,
ticketResponseTime:
standardPlan?.ticketResponseTime ?? standardConstants.ticketResponseTime
standardPlan?.ticketResponseTime ?? standardConstants.ticketResponseTime,
customDomain: standardPlan?.customDomain ?? standardConstants.customDomain
}
: undefined,

View File

@ -9,6 +9,7 @@
"confirm_logout": "Confirm to log out?",
"create_channel": "Add new channel",
"create_model": "Add new model",
"custom_domain": "Custom Domain",
"custom_model": "custom model",
"default_model": "Default model",
"default_model_config": "Default model configuration",

View File

@ -1224,6 +1224,8 @@
"support.wallet.subscription.function.Points": "{{amount}} points",
"support.wallet.subscription.function.Requests per minute": "{{amount}} QPM",
"support.wallet.subscription.function.Website sync per dataset": "Single knowledge base {{amount}} web pages synchronized",
"support.wallet.subscription.function.Custom domain": "{{amount}} Custom domains",
"support.wallet.subscription.function.custom domain tip": "The number of custom domains that a team can configure for binding independent domain names to access applications",
"support.wallet.subscription.mode.Month": "Month",
"support.wallet.subscription.mode.Period": "Subscription Period",
"support.wallet.subscription.mode.Year": "Year",

View File

@ -14,6 +14,7 @@
"create_channel": "新增渠道",
"create_model": "新增模型",
"custom_config_details": "定制配置详情",
"custom_domain": "自定义域名",
"custom_model": "自定义模型",
"day": "天",
"default_model": "预设模型",

View File

@ -1233,6 +1233,8 @@
"support.wallet.subscription.function.Requests per minute": "{{amount}} QPM",
"support.wallet.subscription.function.Ticket response time": "{{amount}} 小时工单支持响应",
"support.wallet.subscription.function.Website sync per dataset": "站点同步最大 {{amount}} 页",
"support.wallet.subscription.function.Custom domain": "{{amount}} 个自定义域名",
"support.wallet.subscription.function.custom domain tip": "团队可以配置的自定义域名数量,用于绑定独立域名访问应用",
"support.wallet.subscription.function.qpm tip": "主要指团队每分钟请求 Agent 的最大次数,与单个 Agent 复杂度无关。其他 OpenAPI 接口也受此影响,每个接口单独计算",
"support.wallet.subscription.mode.Month": "按月",
"support.wallet.subscription.mode.Period": "订阅周期",

View File

@ -14,6 +14,7 @@
"create_channel": "新增管道",
"create_model": "新增模型",
"custom_config_details": "定制配置詳情",
"custom_domain": "自定義域名",
"custom_model": "自訂模型",
"day": "天",
"default_model": "預設模型",
@ -114,4 +115,4 @@
"website_sync_per_dataset": "站點同步最大頁數",
"yes": "是",
"yuan": "{{amount}}元"
}
}

View File

@ -775,11 +775,11 @@
"create_success": "建立成功",
"create_time": "建立時間",
"cron_job_run_app": "排程任務",
"custom_plan_price": "定制化計費",
"custom_plan_feature_1": "優先深度技術支援",
"custom_plan_feature_2": "專屬客戶經理",
"custom_plan_feature_3": "彈性資源配置",
"custom_plan_feature_4": "安全可控",
"custom_plan_price": "定制化計費",
"custom_title": "自訂標題",
"data_index_custom": "自定義索引",
"data_index_default": "預設索引",
@ -1213,6 +1213,7 @@
"support.wallet.subscription.Upgrade plan": "升級方案",
"support.wallet.subscription.ai_model": "AI 語言模型",
"support.wallet.subscription.function.Audit log store duration": "{{amount}} 天團隊操作日誌記錄",
"support.wallet.subscription.function.Custom domain": "{{amount}} 個自定義域名",
"support.wallet.subscription.function.History store": "{{amount}} 天對話紀錄保留",
"support.wallet.subscription.function.Max app": "{{amount}} 個 Agent",
"support.wallet.subscription.function.Max dataset": "{{amount}} 個知識庫",
@ -1221,6 +1222,7 @@
"support.wallet.subscription.function.Points": "{{amount}} 積分",
"support.wallet.subscription.function.Requests per minute": "{{amount}} QPM",
"support.wallet.subscription.function.Website sync per dataset": "單知識庫 {{amount}} 個網頁同步",
"support.wallet.subscription.function.custom domain tip": "團隊可以配置的自定義域名數量,用於綁定獨立域名訪問應用",
"support.wallet.subscription.mode.Month": "按月",
"support.wallet.subscription.mode.Period": "訂閱週期",
"support.wallet.subscription.mode.Year": "按年",

View File

@ -46,7 +46,8 @@ const StandardPlanContentList = ({
standplan?.chatHistoryStoreDuration ?? plan.chatHistoryStoreDuration,
auditLogStoreDuration: standplan?.auditLogStoreDuration ?? plan.auditLogStoreDuration,
appRegistrationCount: standplan?.appRegistrationCount ?? plan.appRegistrationCount,
ticketResponseTime: standplan?.ticketResponseTime ?? plan.ticketResponseTime
ticketResponseTime: standplan?.ticketResponseTime ?? plan.ticketResponseTime,
customDomain: standplan?.customDomain ?? plan.customDomain
};
}, [
subPlans?.standard,
@ -62,7 +63,8 @@ const StandardPlanContentList = ({
standplan?.chatHistoryStoreDuration,
standplan?.auditLogStoreDuration,
standplan?.appRegistrationCount,
standplan?.ticketResponseTime
standplan?.ticketResponseTime,
standplan?.customDomain
]);
return planContent ? (
@ -175,6 +177,20 @@ const StandardPlanContentList = ({
</Box>
</Flex>
)}
{planContent.customDomain !== undefined && (
<Flex alignItems={'center'}>
<MyIcon name={'price/right'} w={'16px'} mr={3} />
<Box color={'myGray.600'}>
{t('common:support.wallet.subscription.function.Custom domain', {
amount: planContent.customDomain
})}
</Box>
<QuestionTip
ml={1}
label={t('common:support.wallet.subscription.function.custom domain tip')}
/>
</Flex>
)}
</Grid>
) : null;
};

View File

@ -109,6 +109,13 @@ const BillDetailModal = ({ billId, onClose }: BillDetailModalProps) => {
unit: 'h'
});
}
if (config.customDomain !== undefined) {
items.push({
key: i18nT('account:custom_domain'),
value: config.customDomain,
unit: ''
});
}
return items;
}, [bill?.couponDetail?.subscriptions]);