Browse Source

提示

hella_online_20240829
wangyufei 4 months ago
parent
commit
dacca1e12b
  1. 6
      src/views/wms/deliversettlementManage/deliverplan/deliverPlanMain/index.vue

6
src/views/wms/deliversettlementManage/deliverplan/deliverPlanMain/index.vue

@ -157,10 +157,14 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
})
if (type == 'tableForm') {
if(formField == 'itemCode') {
let itemCodes = val.filter(item=>tableData.value.find(item1=>item1['itemCode']==item['itemCode']))
if(itemCodes.length>0){
itemCodes = itemCodes.map(item=>(item['itemCode']))
message.warning(`物料${itemCodes.join(',')}已经存在`)
}
val = val.filter(item=>!tableData.value.find(item1=>item1['itemCode']==item['itemCode']))
if(val.length==0) return
val.forEach(item=>{
if(tableData.value.find(item1=>item1['itemCode'] == item['itemCode'])) return
const newRow = JSON.parse(JSON.stringify({...tableFormKeys,...item}))
row[formField] = item[searchField]
newRow['uom'] = item['customerUom']

Loading…
Cancel
Save