fix: bug fix

This commit is contained in:
dataeaseShu
2025-07-30 10:45:31 +08:00
parent 35753078a4
commit 85bd9aa745
4 changed files with 17 additions and 8 deletions
+3 -1
View File
@@ -52,7 +52,9 @@ const changeLanguage = (lang: string) => {
const param = {
language: lang,
}
userApi.language(param)
userApi.language(param).then(() => {
window.location.reload()
})
}
const openPwd = () => {
+3 -1
View File
@@ -6,6 +6,8 @@
"AI Model Configuration": "AI Model Configuration"
},
"common": {
"proceed_with_caution": "Deletion is irreversible, so proceed with caution.",
"sales_in_2024": "Delete conversation: {msg}?",
"limited_to_30": "The number of data tables is limited to 30",
"enter_your_password": "Please enter your password",
"your_account_email_address": "Please enter your account/email address",
@@ -521,4 +523,4 @@
"back_community": "Restore to Community Edition",
"confirm_tips": "Are you sure to restore to Community Edition?"
}
}
}
+2
View File
@@ -6,6 +6,8 @@
"AI Model Configuration": "模型配置"
},
"common": {
"proceed_with_caution": "删除后无法恢复,请谨慎操作。",
"sales_in_2024": "是否删除对话:{msg}?",
"limited_to_30": "数据表数量限制30",
"enter_your_password": "请输入密码",
"your_account_email_address": "请输入账号/邮箱",
+9 -6
View File
@@ -112,18 +112,21 @@ function handleCommand(command: string | number | object, chat: Chat) {
dialogVisiblePassword.value = true
break
case 'delete':
ElMessageBox.confirm('This action will permanently delete the chat. Continue?', 'Warning', {
confirmButtonText: 'OK',
cancelButtonText: 'Cancel',
type: 'warning',
ElMessageBox.confirm(t('common.sales_in_2024', { msg: chat.brief }), {
confirmButtonType: 'danger',
tip: t('common.proceed_with_caution'),
confirmButtonText: t('dashboard.delete'),
cancelButtonText: t('common.cancel'),
customClass: 'confirm-no_icon',
autofocus: false,
}).then(() => {
_loading.value = true
chatApi
.deleteChat(chat.id)
.then((res) => {
.then(() => {
ElMessage({
type: 'success',
message: res,
message: t('dashboard.delete_success'),
})
emits('chatDeleted', chat.id)
})