Commit 609889a7 authored by xiaoman's avatar xiaoman

bugfix: 钱币编辑校验失败的问题

parent a62735c5
...@@ -206,20 +206,24 @@ export default { ...@@ -206,20 +206,24 @@ export default {
this.$router.push({ path: '/goods/list' }) this.$router.push({ path: '/goods/list' })
}, },
handleEdit: function() { handleEdit: function() {
editGoods(this.goods) this.$refs.goods.validate((valid) => {
.then(response => { if (valid) {
this.$notify.success({ editGoods(this.goods)
title: '成功', .then(response => {
message: '创建成功' this.$notify.success({
}) title: '成功',
this.$router.push({ path: '/goods/list' }) message: '创建成功'
}) })
.catch(response => { this.$router.push({ path: '/goods/list' })
MessageBox.alert('业务错误:' + response.data.errmsg, '警告', { })
confirmButtonText: '确定', .catch(response => {
type: 'error' MessageBox.alert('业务错误:' + response.data.errmsg, '警告', {
}) confirmButtonText: '确定',
}) type: 'error'
})
})
}
})
}, },
uploadOverrun: function() { uploadOverrun: function() {
this.$message({ this.$message({
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment