diff --git a/src/locales/en-US.ts b/src/locales/en-US.ts index 793259dc4..2ffdbba5d 100644 --- a/src/locales/en-US.ts +++ b/src/locales/en-US.ts @@ -1284,6 +1284,7 @@ export default { '收货数量不可以大于订单数量!': 'The received quantity cannot exceed the order quantity', 撤销报工成功:'Revocation of work report successful', 生产日期不能小于:'The date of production cannot be less than', + 生产日期不能大于当前系统日期:'The production date cannot be greater than the current system date', 发票回转:'Return of invoice', 发票回转成功:'The invoice has been successfully forwarded' }, diff --git a/src/locales/zh-CN.ts b/src/locales/zh-CN.ts index 30d9d58c2..9d42231a1 100644 --- a/src/locales/zh-CN.ts +++ b/src/locales/zh-CN.ts @@ -1280,6 +1280,7 @@ export default { '收货数量不可以大于订单数量!':'收货数量不可以大于订单数量', 撤销报工成功:'撤销报工成功', 生产日期不能小于:'生产日期不能小于', + 生产日期不能大于当前系统日期:'生产日期不能大于当前系统日期', 发票回转:'发票回转', 发票回转成功:'发票回转成功' }, diff --git a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/supplierdeliverBasicForm.vue b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/supplierdeliverBasicForm.vue index 6e1efa992..28fe2369e 100644 --- a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/supplierdeliverBasicForm.vue +++ b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/supplierdeliverBasicForm.vue @@ -322,10 +322,15 @@ const submitForm = async (formType, submitData) => { data.id = data.masterId } let flag = true + let currentTime = dayjs().valueOf() tableData.value.forEach(item=>{ if(item['minProduceDate']&&item['produceDate']currentTime){ + flag = false + message.error(`${item['itemCode']}${t('ts.生产日期不能大于当前系统日期')}`) } }) if(!flag){ @@ -428,8 +433,15 @@ const formFormDateChange = (field, val,row, index) => { console.log('formFormDateChange',field, val,row, index) if(field == 'produceDate'){ if(row['minProduceDate']&&valcurrentTime){ + val = currentTime + message.error(`${row['itemCode']}${t('ts.生产日期不能大于当前系统日期')}`) + // row['produceDate'] = currentTime } let produceDateStr = formatDate(val,'YYYYMMDD'); row.batch = produceDateStr