+
所有测试
diff --git a/frontend/src/performance/components/project/MsProject.vue b/frontend/src/performance/components/project/MsProject.vue
index d3272fdcd6..bc31fe2655 100644
--- a/frontend/src/performance/components/project/MsProject.vue
+++ b/frontend/src/performance/components/project/MsProject.vue
@@ -5,18 +5,19 @@
- 项目
+ {{$t('commons.project')}}
-
-
-
+
+
@@ -43,17 +44,17 @@
-
+
-
+
-
+
@@ -71,7 +72,7 @@
return {
createVisible: false,
result: {},
- btnTips: "添加项目",
+ btnTips: this.$t('project.create'),
condition: "",
items: [],
form: {},
@@ -99,7 +100,7 @@
},
edit(row) {
this.createVisible = true;
- this.form = row;
+ this.form = Object.assign({}, row);
},
submit(formName) {
this.$refs[formName].validate((valid) => {
@@ -111,7 +112,7 @@
this.result = this.$post("/project/" + saveType, this.form, () => {
this.createVisible = false;
this.list();
- Message.success('保存成功');
+ Message.success(this.$t('commons.save_success'));
});
} else {
return false;
@@ -119,17 +120,15 @@
});
},
del(row) {
- this.$confirm('这个项目确定要删除吗?', '提示', {
- confirmButtonText: '确定',
- cancelButtonText: '取消',
+ this.$confirm(this.$t('project.delete_confirm'), this.$t('commons.prompt'), {
+ confirmButtonText: this.$t('commons.confirm'),
+ cancelButtonText: this.$t('commons.cancel'),
type: 'warning'
- }).then(() => {
+ }, () => {
this.$get('/project/delete/' + row.id, () => {
- Message.success('删除成功');
+ Message.success(this.$t('commons.delete_success'));
this.list();
});
- }).catch(() => {
-
});
},
list() {
diff --git a/frontend/src/performance/components/project/RecentProject.vue b/frontend/src/performance/components/project/RecentProject.vue
index 5ad0b05a3f..4c21e9486e 100644
--- a/frontend/src/performance/components/project/RecentProject.vue
+++ b/frontend/src/performance/components/project/RecentProject.vue
@@ -1,11 +1,13 @@
-
+
{{$t('project.recent')}}
-
- {{ recentProject.name }}
+
+
+ {{ p.name }}
@@ -18,12 +20,7 @@
this.recentProjects = response.data;
});
},
- methods: {
- goTest(project) {
- window.console.log(project);
- // this.$router.push({path: '/allTest', params: {projectId: project.id, projectName: project.name}});
- }
- },
+ methods: {},
data() {
return {
recentProjects: [],
diff --git a/frontend/src/performance/components/router/router.js b/frontend/src/performance/components/router/router.js
index 9c3cbdb91d..22ef26fb81 100644
--- a/frontend/src/performance/components/router/router.js
+++ b/frontend/src/performance/components/router/router.js
@@ -85,11 +85,11 @@ const router = new VueRouter({
}
},
{
- path: "/allTest",
+ path: "/allTest/:projectId",
+ name: "allTest",
components: {
content: AllTestPlan
},
- props: true,
},
{
path: "/project",
diff --git a/frontend/src/performance/components/testPlan/AllTestPlan.vue b/frontend/src/performance/components/testPlan/AllTestPlan.vue
index 675e6769be..dd781cb92f 100644
--- a/frontend/src/performance/components/testPlan/AllTestPlan.vue
+++ b/frontend/src/performance/components/testPlan/AllTestPlan.vue
@@ -80,16 +80,13 @@