修复查询申购单与申购单明细数据不一致

prod
1178634255 2 years ago
parent d2013754a9
commit aee0cc3375

@ -51,6 +51,7 @@
style="width: 90%" style="width: 90%"
:clearable="false" :clearable="false"
value-format="yyyy-MM-dd HH:mm:ss" value-format="yyyy-MM-dd HH:mm:ss"
:disabled-date="disabledArrivalDate"
> >
</el-date-picker> </el-date-picker>
</el-form-item> </el-form-item>
@ -220,6 +221,7 @@ export default {
id: null, id: null,
billNo: null, billNo: null,
createTime: "", createTime: "",
arrivalTime: '',
remark: "", remark: "",
deptCode: null, deptCode: null,
invCode: null, invCode: null,
@ -294,7 +296,9 @@ export default {
if (this.formData.arrivalTime == "" || this.formData.arrivalTime == null) { if (this.formData.arrivalTime == "" || this.formData.arrivalTime == null) {
return this.$message.error("到货时间不能为空!"); return this.$message.error("到货时间不能为空!");
} }
if (this.formData.arrivalTime<this.formData.createTime) {
return this.$message.error("到货时间不能比单据日期早!!!");
}
for (let i = 0; i < this.codeArray.length; i++) { for (let i = 0; i < this.codeArray.length; i++) {
if (this.$isBlank(this.codeArray[i].count) || this.codeArray[i].count == "0") { if (this.$isBlank(this.codeArray[i].count) || this.codeArray[i].count == "0") {
return this.$message.error('单据数量不能为0'); return this.$message.error('单据数量不能为0');
@ -318,6 +322,9 @@ export default {
} }
}); });
}, },
disabledArrivalDate(time) {
return time.getTime() < new Date(this.formData.createTime).getTime()
},
submitFunction(status) { submitFunction(status) {
let tMessage = status === '1' ? '保存' : '提交'; let tMessage = status === '1' ? '保存' : '提交';
this.loading = true; this.loading = true;

Loading…
Cancel
Save