From 6c67dc6ed428cdfbb8f2ef7129682607ae49e3ec Mon Sep 17 00:00:00 2001 From: ssongliu <73214554+ssongliu@users.noreply.github.com> Date: Mon, 25 Mar 2024 15:12:07 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E5=AE=8C=E5=96=84=20License=20?= =?UTF-8?q?=E5=AF=BC=E5=85=A5=E9=94=99=E8=AF=AF=E6=98=BE=E7=A4=BA=20(#4297?= =?UTF-8?q?)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- backend/constant/errs.go | 2 ++ backend/i18n/lang/en.yaml | 2 +- backend/i18n/lang/zh-Hant.yaml | 2 +- backend/i18n/lang/zh.yaml | 2 +- 4 files changed, 5 insertions(+), 3 deletions(-) diff --git a/backend/constant/errs.go b/backend/constant/errs.go index 1cafd9158..4f77061c9 100644 --- a/backend/constant/errs.go +++ b/backend/constant/errs.go @@ -18,6 +18,8 @@ const ( CodeErrDomain = 409 CodeErrInternalServer = 500 CodeErrHeader = 406 + + CodeErrXpack = 410 ) // internal diff --git a/backend/i18n/lang/en.yaml b/backend/i18n/lang/en.yaml index 0d3e003ab..0c32552d3 100644 --- a/backend/i18n/lang/en.yaml +++ b/backend/i18n/lang/en.yaml @@ -174,7 +174,7 @@ ErrRuleExist: "Rule is Exist" ErrRuleNotExist: "Rule is not Exist" #license -ErrLicense: "License format error, please re-import!" +ErrLicense: "License format error, {{ .err }}, please re-import!" ErrLicenseCheckInLocal: "Local license check failed, error {{ .err }}, please try again!" ErrLicenseCheckInRemote: "Remote license check failed, error {{ .err }}, please try again!" ErrLicenseSave: "Failed to save license information, error {{ .err }}, please try again!" diff --git a/backend/i18n/lang/zh-Hant.yaml b/backend/i18n/lang/zh-Hant.yaml index 63f3d0e8b..04247f953 100644 --- a/backend/i18n/lang/zh-Hant.yaml +++ b/backend/i18n/lang/zh-Hant.yaml @@ -175,7 +175,7 @@ ErrRuleExist: "規則名稱已存在" ErrRuleNotExist: "規則不存在" #license -ErrLicense: "License 格式錯誤,請重新匯入!" +ErrLicense: "License 格式錯誤,{{ .err }},請重新匯入!" ErrLicenseCheckInLocal: "License 本地校驗失敗,錯誤 {{ .err }},請重試!" ErrLicenseCheckInRemote: "License 遠程校驗失敗,錯誤 {{ .err }},請重試!" ErrLicenseSave: "License 資訊保存失敗,錯誤 {{ .err }},請重試!" diff --git a/backend/i18n/lang/zh.yaml b/backend/i18n/lang/zh.yaml index 59024ccda..b7e056c6a 100644 --- a/backend/i18n/lang/zh.yaml +++ b/backend/i18n/lang/zh.yaml @@ -174,7 +174,7 @@ ErrRuleExist: "规则名称已存在" ErrRuleNotExist: "规则不存在" #license -ErrLicense: "License 格式错误,请重新导入!" +ErrLicense: "License 格式错误,{{ .err }},请重新导入!" ErrLicenseCheckInLocal: "License 本地校验失败,错误 {{ .err }},请重试!" ErrLicenseCheckInRemote: "License 远程校验失败,错误 {{ .err }},请重试!" ErrLicenseSave: "License 信息保存失败,错误 {{ .err }},请重试!"