Commit fd22911b by lichengming

修改了入库

parent eaed550d
...@@ -51,6 +51,13 @@ export default { ...@@ -51,6 +51,13 @@ export default {
storageSelect storageSelect
}, },
data() { data() {
const valistorehouse = (rule, value, callback) => {
if (this.formObj.storehouse === '') {
callback(new Error('内容不能为空'))
} else {
callback()
}
}
return { return {
formId: '', formId: '',
id: '', id: '',
...@@ -99,7 +106,12 @@ export default { ...@@ -99,7 +106,12 @@ export default {
], ],
ruleValidate: { ruleValidate: {
storehouse: [ storehouse: [
{ required: true, message: '库房号不能为空', trigger: 'blur' } {
required: true,
message: '库房号不能为空',
trigger: 'blur',
validator: valistorehouse
}
] ]
}, },
showEditModal: false, showEditModal: false,
...@@ -183,6 +195,7 @@ export default { ...@@ -183,6 +195,7 @@ export default {
console.log(data) console.log(data)
data.ids = this.id data.ids = this.id
this._instockSubmit(data) this._instockSubmit(data)
this._hideLoading()
} else { } else {
this.$Message.error('表单验证失败!') this.$Message.error('表单验证失败!')
this._hideLoading() this._hideLoading()
......
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