fix(测试计划): 修复测试方式为自动时通过按钮禁止

This commit is contained in:
wenyann 2020-08-05 18:22:56 +08:00
parent f10fef30bf
commit dd049e7893

View File

@ -366,6 +366,7 @@
this.$nextTick(() => { this.$nextTick(() => {
if (this.testCase.method == 'auto') { if (this.testCase.method == 'auto') {
if (this.$refs.apiTestDetail && this.testCase.type == 'api') { if (this.$refs.apiTestDetail && this.testCase.type == 'api') {
this.$refs.apiTestDetail.init(); this.$refs.apiTestDetail.init();
} else if (this.testCase.type == 'performance') { } else if (this.testCase.type == 'performance') {
this.$refs.performanceTestDetail.init(); this.$refs.performanceTestDetail.init();
@ -432,10 +433,13 @@
this.$post('/test/plan/edit/status/' + planId); this.$post('/test/plan/edit/status/' + planId);
}, },
stepResultChange() { stepResultChange() {
if (this.testCase.method == 'manual') {
this.isFailure = this.testCase.steptResults.filter(s => { this.isFailure = this.testCase.steptResults.filter(s => {
return !s.executeResult || s.executeResult === 'Failure' || s.executeResult === 'Blocking'; return !s.executeResult || s.executeResult === 'Failure' || s.executeResult === 'Blocking';
}).length > 0; }).length > 0;
} }
}
} }
} }
</script> </script>