【调整】API管理EdgeOne标识

This commit is contained in:
cai
2026-01-16 11:52:32 +08:00
parent 200c0aeee6
commit de29831f2a
50 changed files with 71 additions and 50 deletions

View File

@@ -289,11 +289,11 @@ export const ApiProjectConfig: Record<string, ApiProjectType> = {
sort: 33,
},
edgeone: {
name: "Edgeone",
name: "EdgeOne",
icon: "edgeone",
type: ["host", "dns"],
type: ["dns"],
hostRelated: {
sslcenter: { name: "Edgeone" }
sslcenter: { name: "EdgeOne" }
},
sort: 38,
},

View File

@@ -688,9 +688,23 @@ export const useApiFormController = (
trigger: "input",
},
secret_id: {
required: true,
message: $t("t_6_1745317313383"),
trigger: "input",
validator: (
rule: FormItemRule,
value: string,
callback: (error?: Error) => void
) => {
if (!value || !value.length) {
const mapTips = {
tencentcloud: $t("t_2_1747042967277"),
edgeone: "请输入正确的 EdgeOne SecretId",
};
return callback(
new Error(mapTips[param.value.type as keyof typeof mapTips])
);
}
callback();
},
},
access_key: {
trigger: "input",
@@ -725,6 +739,7 @@ export const useApiFormController = (
if (!value || !value.length) {
const mapTips = {
tencentcloud: $t("t_2_1747042967277"),
edgeone: "请输入 EdgeOne Secret Key",
huawei: $t("t_3_1747042967608"),
baidu: $t("t_4_1747271294621"),
volcengine: $t("t_4_1747365600137"),
@@ -1607,6 +1622,12 @@ export const useApiFormController = (
secret_key: "",
};
break;
case "edgeone":
param.value.config = {
secret_id: "",
secret_key: "",
};
break;
case "godaddy":
param.value.config = {
api_key: "",