i18n
This commit is contained in:
parent
2f6c95d137
commit
96e3111768
|
@ -90,7 +90,7 @@
|
|||
<el-col class="test-detail" :span="20" :offset="1">
|
||||
<el-tabs v-model="activeTab" type="border-card" @tab-click="testTabChange">
|
||||
<el-tab-pane name="detail" :label="$t('test_track.plan_view.test_detail')">
|
||||
<api-test-detail v-if="testCase.type == 'api'" @runTest="testRun" :id="testCase.testId" ref="apiTestDetail"/>
|
||||
<api-test-detail :is-read-only="isReadOnly" v-if="testCase.type == 'api'" @runTest="testRun" :id="testCase.testId" ref="apiTestDetail"/>
|
||||
<performance-test-detail :is-read-only="isReadOnly" v-if="testCase.type == 'performance'" @runTest="testRun" :id="testCase.testId" ref="performanceTestDetail"/>
|
||||
</el-tab-pane>
|
||||
<el-tab-pane name="result" :label="$t('test_track.plan_view.test_result')">
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
:placeholder="$t('api_test.select_project')">
|
||||
</el-select>
|
||||
</el-input>
|
||||
<el-button type="primary" plain @click="runTest">
|
||||
<el-button :disabled="isReadOnly" type="primary" plain @click="runTest">
|
||||
{{$t('api_test.run')}}
|
||||
</el-button>
|
||||
</el-row>
|
||||
|
@ -31,7 +31,13 @@
|
|||
export default {
|
||||
name: "ApiTestDetail",
|
||||
components: {MsMainContainer, MsContainer, MsApiScenarioConfig},
|
||||
props: ["id"],
|
||||
props: {
|
||||
id: String,
|
||||
isReadOnly: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
result: {},
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<template>
|
||||
<ms-container>
|
||||
<ms-main-container>
|
||||
<span v-if="!reportId">尚未执行</span>
|
||||
<span v-if="!reportId">{{$t('commons.not_performed_yet')}}</span>
|
||||
<el-card v-if="reportId">
|
||||
<section class="report-container" v-loading="loading">
|
||||
<header class="report-header">
|
||||
|
|
|
@ -1,7 +1,8 @@
|
|||
<template>
|
||||
<ms-container>
|
||||
<ms-main-container>
|
||||
<el-card v-loading="result.loading">
|
||||
<span v-if="!reportId">{{$t('commons.not_performed_yet')}}</span>
|
||||
<el-card v-loading="result.loading" v-if="reportId">
|
||||
<el-row>
|
||||
<el-col :span="16">
|
||||
<el-row>
|
||||
|
@ -147,13 +148,13 @@
|
|||
this.$warning(this.$t('report.generation_error'));
|
||||
break;
|
||||
case 'Starting':
|
||||
this.$warning("测试处于开始状态,请稍后查看报告!");
|
||||
this.$warning(this.$t('report.start_status'));
|
||||
break;
|
||||
case 'Reporting':
|
||||
this.$info(this.$t('report.being_generated'));
|
||||
break;
|
||||
case 'Running':
|
||||
this.$warning("测试处于运行状态,请稍后查看报告!");
|
||||
this.$warning(this.$t('report.run_status'));
|
||||
break;
|
||||
case 'Completed':
|
||||
default:
|
||||
|
@ -205,6 +206,7 @@
|
|||
}
|
||||
},
|
||||
getReport() {
|
||||
if (this.reportId) {
|
||||
this.result = this.$get("/performance/report/" + this.reportId, res => {
|
||||
let data = res.data;
|
||||
this.status = data.status;
|
||||
|
@ -214,6 +216,7 @@
|
|||
this.initReportTimeInfo();
|
||||
}
|
||||
});
|
||||
}
|
||||
this.initBreadcrumb();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -92,7 +92,8 @@ export default {
|
|||
'remove': 'Remove',
|
||||
'remove_cancel': 'Remove Cancel',
|
||||
'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',
|
||||
},
|
||||
workspace: {
|
||||
'create': 'Create Workspace',
|
||||
|
|
|
@ -91,7 +91,8 @@ export default {
|
|||
'remove': '移除',
|
||||
'remove_cancel': '移除取消',
|
||||
'remove_success': '移除成功',
|
||||
'tips': '认证信息已过期,请重新登录'
|
||||
'tips': '认证信息已过期,请重新登录',
|
||||
'not_performed_yet': '尚未执行',
|
||||
},
|
||||
workspace: {
|
||||
'create': '创建工作空间',
|
||||
|
|
|
@ -91,7 +91,8 @@ export default {
|
|||
'remove': '移除',
|
||||
'remove_cancel': '移除取消',
|
||||
'remove_success': '移除成功',
|
||||
'tips': '认認證資訊已過期,請重新登入'
|
||||
'tips': '认認證資訊已過期,請重新登入',
|
||||
'not_performed_yet': '尚未執行',
|
||||
},
|
||||
workspace: {
|
||||
'create': '創建工作空間',
|
||||
|
|
Loading…
Reference in New Issue