Browse Source

Merge branch 'hella_online_20241017' into master_hella

hella_online_20241024
陈薪名 1 month ago
parent
commit
c1b04d7665
  1. 10
      src/views/wms/deliversettlementManage/customerreturn/customerreturnRequestMain/customerreturnRequestMain.data.ts
  2. 82
      src/views/wms/deliversettlementManage/customerreturn/customerreturnRequestMain/index.vue
  3. 5
      src/views/wms/deliversettlementManage/saleShipmentMainRequest/index.vue

10
src/views/wms/deliversettlementManage/customerreturn/customerreturnRequestMain/customerreturnRequestMain.data.ts

@ -1492,11 +1492,6 @@ export const CustomerreturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
searchAllSchemas: BalanceCopy.allSchemas,
searchPage: BalanceApi.getBalanceByLocation,
searchCondition:[
{
key: 'available',
value: 'TRUE',
isMainValue: false
},
{
message: '请选择从库位代码!',
key: 'locationCode',
@ -1515,11 +1510,6 @@ export const CustomerreturnRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
searchAllSchemas: BalanceCopy.allSchemas, // 查询弹窗所需类
searchPage: BalanceApi.getBalanceByLocation, // 查询弹窗所需分页方法
searchCondition:[
{
key: 'available',
value: 'TRUE',
isMainValue: false
},
{
message: '请选择从库位代码!',
key: 'locationCode',

82
src/views/wms/deliversettlementManage/customerreturn/customerreturnRequestMain/index.vue

@ -93,7 +93,7 @@
:isShowButton="false"
:isShowReduceButton="false"
@submitForm="submitFormLabel"
@searchTableSuccess="searchTableSuccess"
@searchTableSuccess="searchTableSuccessLabel"
/>
<!-- 标签打印 -->
@ -144,6 +144,86 @@ const onEnter = async (field,value)=>{
console.log('onEnter',field,value)
}
//
const searchTableSuccessLabel = (formField, searchField, val, formRef, type, row ) => {
nextTick(() => {
console.log('searchTableSuccess',formField, searchField, val, formRef, type, row)
CustomerreturnRequestMain.allSchemas.formSchema.forEach(item => {
if(item.field == 'deliverRecordNumber') {
if(customerCode.value != null){
item.componentProps.searchCondition = [
{
key: 'customerCode',
value: customerCode.value ,
isMainValue: false
}]
}
}
})
console.log(128, customerCode.value)
if (type == 'tableForm') {
if(formField == 'packingNumber') {
row['packingNumber'] = val[0]['packingNumber']
row['containerNumber'] = val[0]['containerNumber']
row['batch'] = val[0]['batch']
row['inventoryStatus'] = val[0]['inventoryStatus']
row['fromLocationCode'] = val[0]['locationCode']
row['itemCode'] = val[0]['itemCode']
row['uom'] = val[0]['uom']
}else if(formField == 'packUnit'){
row['packUnit'] = val[0]['packUnit']
row['packQty'] = val[0]['packQty']
} else {
row[formField] = val[0][searchField]
}
} else {
const setV = {}
if (formField == 'customerCode') {
setV['deliverRecordNumber'] = ''
setV['q1Number'] = ''
tableData.value = []
}
if(formField == 'deliverRecordNumber') {
setV['deliverRecordNumber'] = val[0]['number']
setV['deliverPlanNumber'] = val[0]['deliverPlanNumber']
// setV['customerCode'] = val[0]['customerCode']
// setV['customerDockCode'] = val[0]['customerDockCode']
//
DeliverRecordDetailApi.getDeliverRecordDetailPageCustomerreturn({pageSize:999,masterId:val[0]['masterId']}).then(res => {
res.list.forEach(obj => {
let value = null
value = obj.fromLocationCode
obj.fromLocationCode = obj.toLocationCode
obj.toLocationCode = ''
obj.packingNumber = '' //
CustomerreturnRequestDetail.allSchemas.tableFormColumns.map(item =>{
if(item.field == 'packingNumber') {
item.isInpuFocusShow = false
item.tableForm.isInpuFocusShow = false
item.tableForm.disabled = true
}
})
})
if (res) {
tableData.value = [...res.list]
originTableData.value = [...res.list]
}
}).catch(err => {
console.log(err)
message.error('错误')
})
} else {
setV[formField] = val[0][searchField]
}
formRef.setValues(setV)
}
})
}
//
const searchTableSuccess = (formField, searchField, val, formRef, type, row ) => {
nextTick(() => {
console.log('searchTableSuccess',formField, searchField, val, formRef, type, row)

5
src/views/wms/deliversettlementManage/saleShipmentMainRequest/index.vue

@ -178,6 +178,7 @@ const updataTableColumns = (val) => {
tableColumns.value = val
}
const { tableObject, tableMethods } = useTable({
getListApi: SaleShipmentDetailApi.getSaleShipmentDetailPage //
})
@ -349,7 +350,7 @@ const openForm = (type: string, row?: any) => {
const inputNumberChange = (field, val,row, index) => {
if(field=='qty'){
if(row['subSettleQty']!=null&&row['qty']>row['subSettleQty']){
message.error(`物料${row['itemCode']}大数量${row['subSettleQty']}`)
message.error(`${row['itemCode']}物料开票数量${row['qty']}于库存数量${row['subSettleQty']}`)
}
}
console.log('inputNumberChange',field, val,row, index)
@ -364,7 +365,7 @@ const submitForm = async (formType, submitData) => {
tableData.value.forEach(item=>{
if(item['subSettleQty']!=null&&item['qty']>item['subSettleQty']){
flag = false
message.error(`物料${item['itemCode']}大数量${item['subSettleQty']}`)
message.error(`${item['itemCode']}物料开票数量${item['qty']}于库存数量${item['subSettleQty']}`)
}
})
if(!flag){

Loading…
Cancel
Save