forked from github/dataease
fix: 数据源检测时间超出范围后,置为初始值
This commit is contained in:
parent
5765be7af1
commit
66933da1e9
@ -34,7 +34,7 @@
|
||||
<el-form-item :label="$t('system_parameter_setting.ds_check_time')" >
|
||||
<el-form :inline="true" :disabled="show">
|
||||
<el-form-item >
|
||||
<el-input v-model="formInline.dsCheckInterval" type="number" min="1" @change="onSimpleCronChange()" />
|
||||
<el-input size="mini" v-model="formInline.dsCheckInterval" type="number" min="1" @change="onSimpleCronChange()" />
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item class="form-item">
|
||||
@ -276,21 +276,14 @@ export default {
|
||||
if (this.formInline.dsCheckIntervalType === 'minute') {
|
||||
if (this.formInline.dsCheckInterval < 1 || this.formInline.dsCheckInterval > 59) {
|
||||
this.$message({ message: this.$t('cron.minute_limit'), type: 'warning', showClose: true })
|
||||
this.taskForm.extraData.simple_cron_value = 59
|
||||
this.formInline.dsCheckInterval = 1
|
||||
}
|
||||
return
|
||||
}
|
||||
if (this.formInline.dsCheckIntervalType === 'hour') {
|
||||
if (this.formInline.dsCheckInterval < 1 || this.formInline.dsCheckInterval > 23) {
|
||||
this.$message({ message: this.$t('cron.hour_limit'), type: 'warning', showClose: true })
|
||||
this.taskForm.extraData.simple_cron_value = 23
|
||||
}
|
||||
return
|
||||
}
|
||||
if (this.formInline.dsCheckIntervalType === 'day') {
|
||||
if (this.formInline.dsCheckInterval < 1 || this.formInline.dsCheckInterval > 31) {
|
||||
this.$message({ message: this.$t('cron.day_limit'), type: 'warning', showClose: true })
|
||||
this.taskForm.extraData.simple_cron_value = 31
|
||||
this.formInline.dsCheckInterval = 1
|
||||
}
|
||||
return
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user