From c245529b70a81c22251d528469c4383ea7af85af Mon Sep 17 00:00:00 2001 From: lan-yonghui Date: Tue, 2 Jul 2024 19:43:44 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E6=96=87=E4=BB=B6=E5=88=97=E8=A1=A8?= =?UTF-8?q?=E7=BB=84=E4=BB=B6=E6=96=B0=E5=A2=9E=E5=88=9B=E5=BB=BA=E6=96=87?= =?UTF-8?q?=E4=BB=B6=E5=A4=B9=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- backend/i18n/lang/en.yaml | 4 +- backend/i18n/lang/zh-Hant.yaml | 2 +- backend/i18n/lang/zh.yaml | 4 +- frontend/src/components/file-list/index.vue | 115 +++++++++++++++++--- frontend/src/lang/modules/en.ts | 2 + frontend/src/lang/modules/tw.ts | 2 + frontend/src/lang/modules/zh.ts | 2 + 7 files changed, 111 insertions(+), 20 deletions(-) diff --git a/backend/i18n/lang/en.yaml b/backend/i18n/lang/en.yaml index 389a4c87db0f..148cadabc9f7 100644 --- a/backend/i18n/lang/en.yaml +++ b/backend/i18n/lang/en.yaml @@ -74,7 +74,7 @@ ErrFileToLarge: "file is too large" ErrPathNotFound: "Path is not found" ErrMovePathFailed: "The target path cannot contain the original path!" ErrLinkPathNotFound: "Target path does not exist!" -ErrFileIsExit: "File already exists!" +ErrFileIsExit: "File or directory already exists!" ErrFileUpload: "Failed to upload file {{.name}} {{.detail}}" ErrFileDownloadDir: "Download folder not supported" ErrCmdNotFound: "{{ .name}} command does not exist, please install this command on the host first" @@ -131,7 +131,7 @@ ErrLocalExist: "The local database already exists with that name, please modify #redis ErrTypeOfRedis: "The recovery file type does not match the current persistence mode. Modify the file type and try again" -#container +#container ErrInUsed: "{{ .detail }} is in use and cannot be deleted" ErrObjectInUsed: "This object is in use and cannot be deleted" ErrPortRules: "The number of ports does not match, please re-enter!" diff --git a/backend/i18n/lang/zh-Hant.yaml b/backend/i18n/lang/zh-Hant.yaml index f58a3c4ad6e7..3556977a039f 100644 --- a/backend/i18n/lang/zh-Hant.yaml +++ b/backend/i18n/lang/zh-Hant.yaml @@ -75,7 +75,7 @@ ErrFileToLarge: "文件超過10M,無法打開" ErrPathNotFound: "目錄不存在" ErrMovePathFailed: "目標路徑不能包含原路徑!" ErrLinkPathNotFound: "目標路徑不存在!" -ErrFileIsExit: "文件已存在!" +ErrFileIsExit: "文件或文件夾已存在!" ErrFileUpload: "{{ .name }} 上傳文件失敗 {{ .detail}}" ErrFileDownloadDir: "不支持下載文件夾" ErrCmdNotFound: "{{ .name}} 命令不存在,請先在宿主機安裝此命令" diff --git a/backend/i18n/lang/zh.yaml b/backend/i18n/lang/zh.yaml index e52fc7f6eb2e..4bb2d515dc3d 100644 --- a/backend/i18n/lang/zh.yaml +++ b/backend/i18n/lang/zh.yaml @@ -74,7 +74,7 @@ ErrFileToLarge: "文件超过10M,无法打开" ErrPathNotFound: "目录不存在" ErrMovePathFailed: "目标路径不能包含原路径!" ErrLinkPathNotFound: "目标路径不存在!" -ErrFileIsExit: "文件已存在!" +ErrFileIsExit: "文件或文件夹已存在!" ErrFileUpload: "{{ .name }} 上传文件失败 {{ .detail}}" ErrFileDownloadDir: "不支持下载文件夹" ErrCmdNotFound: "{{ .name}} 命令不存在,请先在宿主机安装此命令" @@ -134,7 +134,7 @@ ErrLocalExist: "本地数据库已存在该名称,请修改后重试" #redis ErrTypeOfRedis: "恢复文件类型与当前持久化方式不符,请修改后重试" -#container +#container ErrInUsed: "{{ .detail }} 正被使用,无法删除" ErrObjectInUsed: "该对象正被使用,无法删除" ErrPortRules: "端口数目不匹配,请重新输入!" diff --git a/frontend/src/components/file-list/index.vue b/frontend/src/components/file-list/index.vue index 11620639f89f..2b1f7dc9312e 100644 --- a/frontend/src/components/file-list/index.vue +++ b/frontend/src/components/file-list/index.vue @@ -67,7 +67,19 @@ @@ -83,9 +95,16 @@ -
- {{ $t('commons.button.cancel') }} - {{ $t('commons.button.confirm') }} +
+ + {{ $t('commons.button.create') }} + +
+ {{ $t('commons.button.cancel') }} + + {{ $t('commons.button.confirm') }} + +
@@ -93,19 +112,24 @@