新增单据未选择分库bug

fencang
anthonywj 3 years ago
parent 48f437d366
commit 57b89e9565

@ -674,7 +674,11 @@ export default {
}, },
invChange() { invChange() {
this.subInvList = []; this.subInvList = [];
this.filterQuery.invWarehouseCode = "";
if(this.$isNotBlank(this.filterQuery.invWarehouseCode)){
this.filterQuery.invWarehouseCode = "";
}
let query = { let query = {
pcode: this.filterQuery.locStorageCode pcode: this.filterQuery.locStorageCode
}; };

@ -564,6 +564,11 @@ export default {
this.$message.error('当前仓库不能为空'); this.$message.error('当前仓库不能为空');
return; return;
} }
if (this.formData.invWarehouseCode == null || this.formData.invWarehouseCode == '') {
this.$message.error('当前分库不能为空');
return;
}
let tQuery = Object.assign(JSON.parse(JSON.stringify(this.formData))); let tQuery = Object.assign(JSON.parse(JSON.stringify(this.formData)));
tQuery.orderId = this.idQuery.id; tQuery.orderId = this.idQuery.id;
tQuery.actDate = parseTime(this.formData.actDate, '{y}-{m}-{d} {h}:{i}:{s}'); tQuery.actDate = parseTime(this.formData.actDate, '{y}-{m}-{d} {h}:{i}:{s}');
@ -669,6 +674,10 @@ export default {
this.$message.error('当前仓库不能为空'); this.$message.error('当前仓库不能为空');
return; return;
} }
if (this.formData.invWarehouseCode == null || this.formData.invWarehouseCode == '') {
this.$message.error('当前分库不能为空');
return;
}
if (this.$isBlank(this.formData.fromCorp)) { if (this.$isBlank(this.formData.fromCorp)) {
this.$message.error('当前往来单位不能为空'); this.$message.error('当前往来单位不能为空');
return; return;
@ -874,6 +883,10 @@ export default {
}, },
locCHange() { locCHange() {
if (this.$isNotBlank(this.formData.invWarehouseCode)) {
this.formData.invWarehouseCode = "";
}
this.findStorageMethod(); this.findStorageMethod();
this.findSubInvByInv(this.formData.locStorageCode); this.findSubInvByInv(this.formData.locStorageCode);
}, },
@ -933,7 +946,7 @@ export default {
findSubStorageMethod() { findSubStorageMethod() {
let cQuery = { let cQuery = {
pcode: this.formData.fromCorpId, pcode: this.formData.fromCorpId,
filter:2, filter: 2,
}; };
filterSubByInv(cQuery) filterSubByInv(cQuery)
.then((response) => { .then((response) => {

@ -440,6 +440,10 @@ export default {
locStorageCode: [ locStorageCode: [
{required: true, message: "请选择当前仓库", trigger: "blur"} {required: true, message: "请选择当前仓库", trigger: "blur"}
], ],
invWarehouseCode: [
{required: true, message: "请选择当前分库", trigger: "blur"}
],
}, },
codeArray: [], codeArray: [],
fromOptions: [], fromOptions: [],

Loading…
Cancel
Save