update i18n
This commit is contained in:
@ -4,7 +4,9 @@ import {
|
||||
ElNotification,
|
||||
ElLoading,
|
||||
} from "element-plus";
|
||||
import i18n from "@/i18n";
|
||||
|
||||
const { t } = i18n.global;
|
||||
let loadingInstance;
|
||||
|
||||
export default {
|
||||
@ -26,19 +28,21 @@ export default {
|
||||
},
|
||||
// 弹出提示
|
||||
alert(content) {
|
||||
ElMessageBox.alert(content, "系统提示");
|
||||
ElMessageBox.alert(content, t("common.systemPrompt"));
|
||||
},
|
||||
// 错误提示
|
||||
alertError(content) {
|
||||
ElMessageBox.alert(content, "系统提示", { type: "error" });
|
||||
void ElMessageBox.alert(content, t("common.systemPrompt"), {
|
||||
type: "error",
|
||||
});
|
||||
},
|
||||
// 成功提示
|
||||
alertSuccess(content) {
|
||||
ElMessageBox.alert(content, "系统提示", { type: "success" });
|
||||
ElMessageBox.alert(content, t("common.systemPrompt"), { type: "success" });
|
||||
},
|
||||
// 警告提示
|
||||
alertWarning(content) {
|
||||
ElMessageBox.alert(content, "系统提示", { type: "warning" });
|
||||
ElMessageBox.alert(content, t("common.systemPrompt"), { type: "warning" });
|
||||
},
|
||||
// 通知提示
|
||||
notify(content) {
|
||||
@ -58,17 +62,17 @@ export default {
|
||||
},
|
||||
// 确认窗体
|
||||
confirm(content) {
|
||||
return ElMessageBox.confirm(content, "系统提示", {
|
||||
confirmButtonText: "确定",
|
||||
cancelButtonText: "取消",
|
||||
return ElMessageBox.confirm(content, t("common.systemPrompt"), {
|
||||
confirmButtonText: t("common.confirm"),
|
||||
cancelButtonText: t("common.confirm"),
|
||||
type: "warning",
|
||||
});
|
||||
},
|
||||
// 提交内容
|
||||
prompt(content) {
|
||||
return ElMessageBox.prompt(content, "系统提示", {
|
||||
confirmButtonText: "确定",
|
||||
cancelButtonText: "取消",
|
||||
return ElMessageBox.prompt(content, t("common.systemPrompt"), {
|
||||
confirmButtonText: t("common.confirm"),
|
||||
cancelButtonText: t("common.confirm"),
|
||||
type: "warning",
|
||||
});
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user