From b32c2c571310e9950e3937449570d44a544a038b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=9A=93=E6=9C=88=E5=BD=92=E5=B0=98?= Date: Sat, 22 Feb 2025 14:50:57 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E5=9B=BD=E9=99=85=E5=8C=96=E7=AE=A1?= =?UTF-8?q?=E7=90=86=E6=B7=BB=E5=8A=A0=E6=8C=89=E9=92=AE=E7=BA=A7=E6=9D=83?= =?UTF-8?q?=E9=99=90=E7=AE=A1=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/i18n.ts | 24 ++++++++++++++++++ src/views/system/i18n/index.vue | 22 +++++++++++++--- src/views/system/i18n/{ => utils}/hook.tsx | 22 +++++++++++++++- .../{language => locale}/components/form.vue | 0 .../system/{language => locale}/index.vue | 23 ++++++++++++++--- .../{language => locale/utils}/hook.tsx | 25 +++++++++++++++++-- 6 files changed, 105 insertions(+), 11 deletions(-) rename src/views/system/i18n/{ => utils}/hook.tsx (91%) rename src/views/system/{language => locale}/components/form.vue (100%) rename src/views/system/{language => locale}/index.vue (89%) rename src/views/system/{language => locale/utils}/hook.tsx (91%) diff --git a/src/api/i18n.ts b/src/api/i18n.ts index 272e7a6..b93d01c 100644 --- a/src/api/i18n.ts +++ b/src/api/i18n.ts @@ -31,6 +31,18 @@ export const deleteLocaleAPI = (id: string) => { return http.request("post", `/api/i18n/deleteLocale/${id}`); }; +/** + * + * 批量删除语言类型 + */ +export const deleteLocaleListAPI = (ids: string[]) => { + return http.request("post", `/api/i18n/deleteLocaleList`, { + data: { + ids + } + }); +}; + /** * 修改语言类型 */ @@ -138,6 +150,18 @@ export const getI18nInfoAPI = (id: string) => { export const deleteI18nAPI = (id: string) => { return http.request("post", `/api/i18n/deleteI18n/${id}`); }; + +/** + * + * 批量删除翻译 + */ +export const deleteI18nListAPI = (ids: string[]) => { + return http.request("post", `/api/i18n/deleteI18nList`, { + data: { + ids + } + }); +}; /** * 修改翻译 * @param data diff --git a/src/views/system/i18n/index.vue b/src/views/system/i18n/index.vue index 6ecb801..c483e87 100644 --- a/src/views/system/i18n/index.vue +++ b/src/views/system/i18n/index.vue @@ -54,6 +54,7 @@