fix 测试步骤长度限制

This commit is contained in:
chenjianxing 2020-05-21 12:08:18 +08:00
parent f456f9a8e0
commit 0b0e8f69d8
1 changed files with 2 additions and 1 deletions

View File

@ -315,7 +315,8 @@
Object.assign(param, this.form);
for (let i = 0; i < param.steps.length; i++){
if (param.steps[i].desc.length > 300 || param.steps[i].result.length > 300) {
if ((param.steps[i].desc && param.steps[i].desc.length > 300) ||
(param.steps[i].result && param.steps[i].result.length > 300)) {
this.$warning(this.$t('test_track.case.step_desc') + ","
+ this.$t('test_track.case.expected_results') + this.$t('test_track.length_less_than') + '300');
return;