Browse Source

!324 Judgment of adding infinite string

Merge pull request !324 from 王卫宁/wwn
tags/v0.5.0-beta
mindspore-ci-bot Gitee 5 years ago
parent
commit
6d71fc852f
1 changed files with 4 additions and 1 deletions
  1. +4
    -1
      mindinsight/ui/src/views/train-manage/scalar.vue

+ 4
- 1
mindinsight/ui/src/views/train-manage/scalar.vue View File

@@ -1869,7 +1869,7 @@ export default {
} else if (valueFirst.indexOf(' ') > -1) {
this.thresholdErrorMsg = this.$t('scalar.noSpace');
isValidate = false;
} else if (isNaN(valueFirst)) {
} else if (isNaN(valueFirst) || valueFirst.indexOf('Infinity') > -1) {
this.thresholdErrorMsg = this.$t('scalar.placeHolderNumber');
isValidate = false;
}
@@ -1889,6 +1889,9 @@ export default {
} else if (isNaN(valueFirst) || isNaN(valueSec)) {
this.thresholdErrorMsg = this.$t('scalar.placeHolderNumber');
isValidate = false;
} else if (valueFirst.indexOf('Infinity') > -1 || valueSec.indexOf('Infinity') > -1) {
this.thresholdErrorMsg = this.$t('scalar.placeHolderNumber');
isValidate = false;
} else {
if (this.thresholdRelational === this.$t('scalar.or')) {
if (


Loading…
Cancel
Save