Browse Source

修改供应商发货申请生产日期

master_hella_20240701
zhaoxuebing 9 months ago
parent
commit
291acc374b
  1. 17
      src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue
  2. 7
      src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/supplierdeliverRequestMain.data.ts
  3. 4
      src/views/wms/supplierManage/purchaseclaim/purchaseclaimRequestMain/index.vue

17
src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue

@ -58,6 +58,7 @@
@handleDeleteTable="handleDeleteTable"
@searchTableSuccess="searchTableSuccess"
@submitForm="submitForm"
@formFormDateChange="formFormDateChange"
/>
<!-- 详情 -->
@ -73,7 +74,6 @@
:apiDelete="SupplierdeliverRequestDetailApi.deleteSupplierdeliverRequestDetail"
:Echo="Echo"
@searchTableSuccessDetail="searchTableSuccessDetail"
@formFormDateChange="formFormDateChange"
/>
<!-- 导入 -->
@ -599,7 +599,12 @@ const handleDeleteTable = (item, index) => {
//
const submitForm = async (formType, data) => {
data.subList = tableData.value //
let isHave = data.subList.some((item) => item.produceDate > item.expireDate)
let isHave = data.subList.some((item) => {
console.log("CCCCC",item.expireDate)
if(item.expireDate != null){
item.produceDate > item.expireDate
}
})
if (isHave) {
message.error('生产日期不可以大于过期日期')
formRef.value.formLoading = false
@ -670,10 +675,10 @@ const searchFormClick = (searchData) => {
}
const formFormDateChange = (field, val,row, index) => {
console.log("AAAAA",field)
console.log("BBBBB",row)
console.log("CCCCC",val)
console.log("DDDDD",index)
if(field == 'produceDate'){
let produceDateStr = formatDate(val,'YYYYMMDD');
row.batch = produceDateStr
}
}
/** 初始化 **/

7
src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/supplierdeliverRequestMain.data.ts

@ -25,6 +25,7 @@ const requestsettingData = data?.list[0] || {}
// 获取当前操作人的部门
import { useUserStore } from '@/store/modules/user'
import { TableColumn } from '@/types/table'
import { tr } from 'element-plus/es/locale'
const userStore = useUserStore()
const userDept = userStore.userSelfInfo.dept
// id 转str 否则form回显匹配不到
@ -579,6 +580,9 @@ export const SupplierdeliverRequestDetail = useCrudSchemas(reactive<CrudSchema[]
table: {
width: 150
},
tableForm: {
disabled: true
}
},
{
label: '替代批次',
@ -1084,9 +1088,6 @@ export const SupplierdeliverRequestDetailRules = reactive({
produceDate: [
{ required: true, message: '请输入生产日期', trigger: 'blur' }
],
expireDate: [
{ required: true, message: '请输入过期日期', trigger: 'blur' }
],
packQty: [
{ required: true, message: '请输入包装数量', trigger: 'blur' }
],

4
src/views/wms/supplierManage/purchaseclaim/purchaseclaimRequestMain/index.vue

@ -481,8 +481,8 @@
getList() //
}
const inputStringBlur =(headerItem,index,row) =>{
console.log("headerItem:",headerItem)
console.log("row:",row)
// console.log("headerItem:",headerItem)
//console.log("row:",row)
if(headerItem == 'singlePrice'){
// =
row.amount = row.qty * row.singlePrice

Loading…
Cancel
Save