Skip to content

Commit

Permalink
feat: 增加制品预加载功能管理页面 #2683
Browse files Browse the repository at this point in the history
  • Loading branch information
lannoy0523 committed Nov 4, 2024
1 parent faf90b2 commit d73c959
Showing 1 changed file with 18 additions and 14 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -177,20 +177,24 @@ export default {
this.$emit('update:visible', false)
},
handleUpdate() {
if (this.strategy.preloadCron === '') {
this.strategy.preloadCron = null
}
if (this.createMode) {
createStrategy(this.strategy).then(() => {
this.$message.success('新建配置成功')
this.close(true)
})
} else {
updateStrategy(this.strategy).then(() => {
this.$message.success('更新配置成功')
this.close(true)
})
}
this.$refs['form'].validate((valid) =>{
if (valid) {
if (this.strategy.preloadCron === '') {
this.strategy.preloadCron = null
}
if (this.createMode) {
createStrategy(this.strategy).then(() => {
this.$message.success('新建配置成功')
this.close(true)
})
} else {
updateStrategy(this.strategy).then(() => {
this.$message.success('更新配置成功')
this.close(true)
})
}
}
})
}
}
}
Expand Down

0 comments on commit d73c959

Please sign in to comment.