'session国际化'

This commit is contained in:
wenyann 2020-06-02 19:39:31 +08:00
parent 86630d0115
commit ff0d49fb6f
3 changed files with 7 additions and 2 deletions

View File

@ -1,5 +1,7 @@
import {Message, MessageBox} from 'element-ui'; import {Message, MessageBox} from 'element-ui';
import axios from "axios"; import axios from "axios";
import i18n from '../../i18n/i18n'
export default { export default {
install(Vue) { install(Vue) {
@ -14,7 +16,7 @@ export default {
} }
let login = function () { let login = function () {
MessageBox.alert("The authentication information has expired, please login again", "Prompt", { MessageBox.alert(i18n.t('commons.tips'), i18n.t('commons.prompt'), {
callback: () => { callback: () => {
window.location.href = "/login" window.location.href = "/login"
} }

View File

@ -95,6 +95,7 @@ export default {
'remove_success': 'Remove Success', 'remove_success': 'Remove Success',
'tips': 'The authentication information has expired, please login again', 'tips': 'The authentication information has expired, please login again',
'not_performed_yet': 'Not performed yet', 'not_performed_yet': 'Not performed yet',
}, },
workspace: { workspace: {
'create': 'Create Workspace', 'create': 'Create Workspace',

View File

@ -94,6 +94,7 @@ export default {
'remove_success': '移除成功', 'remove_success': '移除成功',
'tips': '认证信息已过期,请重新登录', 'tips': '认证信息已过期,请重新登录',
'not_performed_yet': '尚未执行', 'not_performed_yet': '尚未执行',
}, },
workspace: { workspace: {
'create': '创建工作空间', 'create': '创建工作空间',
@ -196,7 +197,8 @@ export default {
'start_status': '测试处于开始状态,请稍后查看报告!', 'start_status': '测试处于开始状态,请稍后查看报告!',
'run_status': '测试处于运行状态,请稍后查看报告!', 'run_status': '测试处于运行状态,请稍后查看报告!',
'user_name': '创建人', 'user_name': '创建人',
'project_name': '所属项目' 'project_name': '所属项目',
}, },
load_test: { load_test: {
'operating': '操作', 'operating': '操作',