From d10c3215a02c9b36748a361639fca43a6d6d12eb Mon Sep 17 00:00:00 2001 From: zhang_li <2235006734@qqq.com> Date: Thu, 11 Jul 2024 16:52:05 +0800 Subject: [PATCH 1/9] =?UTF-8?q?=E6=89=98=E8=A7=84=E6=A0=BC=E9=BB=98?= =?UTF-8?q?=E8=AE=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../supplierdeliverRequestMain/index.vue | 98 +++++++++---------- 1 file changed, 49 insertions(+), 49 deletions(-) diff --git a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue index 85b694f7a..f80b4e3e1 100644 --- a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue +++ b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue @@ -154,7 +154,6 @@ :footButttondata="footButttondata" @footButtonClick="footButtonClick" @formSelectChange="formSelectChangeLabel" - @visibleChange='visibleChange' /> { } genLabelId.value = row.masterId // await getDetailList() - await getGenerateLabelList(row) + await getGenerateLabelList(row) formLabelRef.value.open('create', row, null, 'createLabel') //创建标签页面 createLabel 标题 } }) @@ -628,27 +627,33 @@ const footButttondata = ref([ defaultButtons.formCloseBtn(null) // BOM关闭 ]) // 获取箱规格 -const getGenerateLabelList=async(row)=>{ +const getGenerateLabelList = async (row) => { const params1 = { - masterId: row.masterId, - pageSize: '500', - pageNo: '1', - sort: '', - by: 'ASC' - } - await SupplierdeliverRequestDetailApi.getGenerateLabelList(params1).then((res) => { - detatableData1.value = res - detatableData1.value.forEach((item) => { - item.packUnitInitOptions = item.boxPackaging - let obj = item?.boxPackaging[0] - if (obj) { - item.packUnit= obj.packUnit - item.packQty = obj.packQty - } - item.secondPackUnit= '' - item.secondPackQty = '' - }) + masterId: row.masterId, + pageSize: '500', + pageNo: '1', + sort: '', + by: 'ASC' + } + await SupplierdeliverRequestDetailApi.getGenerateLabelList(params1).then((res) => { + detatableData1.value = res + detatableData1.value.forEach((item) => { + item.packUnitInitOptions = item.boxPackaging + item.secondPackUnitInitOptions = item.palletPackaging || [] + let obj = item?.boxPackaging[0] + if (obj) { + item.packUnit = obj.packUnit + item.packQty = obj.packQty + } + // 有托规格显示托规格,没有显示第一条规格 + item.secondPackUnit = obj.parentPackUnit + ? obj.parentPackUnit + : item?.secondPackUnitInitOptions[0]?.packUnit + item.secondPackQty = obj.parentPackUnit + ? obj.parentPackQty + : item?.secondPackUnitInitOptions[0]?.packQty }) + }) } // 下一步 const labelFormRef = ref() @@ -658,12 +663,12 @@ const footButtonClick = async (val) => { if (!validateForm) { return } - let isNext = detatableData1.value.some((item)=>{ - return !item.packUnit || !item.packQty + let isNext = detatableData1.value.some((item) => { + return !item.packUnit || !item.packQty }) - if(isNext){ + if (isNext) { message.warning('有数据没有选择箱规格') - return; + return } const data = JSON.parse(JSON.stringify(detatableData1.value)) labelFormRef.value.openLabel(data) @@ -677,12 +682,25 @@ const formSelectChangeLabel = (field, val, row) => { let obj = row.boxPackaging.find((item) => item.packUnit == val) if (obj) { row.packQty = obj.packQty + // 获取托规格 + const params1 = { + itemCode: row.itemCode, + packUnit: row.packUnit + } + SupplierdeliverRequestDetailApi.getGenerateLabelParentList(params1).then((res) => { + if (res?.length > 0) { + row.secondPackUnit = res[0].packUnit + row.secondPackQty = res[0].packQty + } else { + row.secondPackUnit = row?.secondPackUnitInitOptions[0]?.packUnit + row.secondPackQty = row?.secondPackUnitInitOptions[0]?.packQty + } + }) } else { row.packQty = '' + row.secondPackUnit = '' + row.secondPackQty = '' } - row.secondPackUnit = '' - row.secondPackQty = '' - } // 设置托 if (field == 'secondPackUnit') { @@ -694,23 +712,7 @@ const formSelectChangeLabel = (field, val, row) => { } } } -// tableForm下拉框弹出隐藏 -const visibleChange=(field, val, row, index)=>{ - row.secondPackUnitInitOptions=[] - if(field=='secondPackUnit'){ - if(val){ - // 获取托规格 - const params1 = { - itemCode: row.itemCode, - packUnit: row.packUnit - } - SupplierdeliverRequestDetailApi.getGenerateLabelParentList(params1).then((res) => { - row.secondPackUnitInitOptions = res - }) - } - } -} // 获取部门 用于详情 部门回显 const { wsCache } = useCache() @@ -1000,10 +1002,9 @@ const { getList: getDetailList } = detatableMethods // 生成标签按钮操作 const submitFormLabel = async (list) => { try { - - let data = { - subList:list - } + let data = { + subList: list + } await message.confirm(t('ts.是否为此数据生成标签?')) labelFormRef.value.isLoading = true await SupplierdeliverRequestMainApi.genLabel(data) @@ -1016,7 +1017,6 @@ const submitFormLabel = async (list) => { labelFormRef.value.formLoading = false labelFormRef.value.dialogTableVisible = false labelFormRef.value.isLoading = false - } } const clearInput = async (field, row, index) => { From 61c6309855627077ab402652b1852226edaa9cee Mon Sep 17 00:00:00 2001 From: gaojs <757918719@qq.com> Date: Thu, 11 Jul 2024 16:53:40 +0800 Subject: [PATCH 2/9] =?UTF-8?q?WMS=20=E2=80=94=E2=80=94>=20bug=20=20?= =?UTF-8?q?=E5=8C=85=E8=A3=85=E8=A7=84=E6=A0=BC=E4=B8=AD=E9=80=89=E6=8B=A9?= =?UTF-8?q?=E7=88=B6=E5=8C=85=E8=A3=85=E5=90=8E=EF=BC=8C=E5=BA=94=E8=AF=A5?= =?UTF-8?q?=E5=B8=A6=E5=87=BA=E5=8C=85=E8=A3=85=E7=B1=BB=E5=9E=8B=E4=B8=94?= =?UTF-8?q?=E4=B8=8D=E5=8F=AF=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../itemManage/packageunit/index.vue | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/src/views/wms/basicDataManage/itemManage/packageunit/index.vue b/src/views/wms/basicDataManage/itemManage/packageunit/index.vue index 1e2341a23..a648c1948 100644 --- a/src/views/wms/basicDataManage/itemManage/packageunit/index.vue +++ b/src/views/wms/basicDataManage/itemManage/packageunit/index.vue @@ -80,11 +80,10 @@ const tableColumns = ref(Packageunit.allSchemas.tableColumns) // 查询页面返回 const searchTableSuccess = (formField, searchField, val, formRef) => { nextTick(() => { - // if(val[0].parentCode){ - // message.error('该规格为子包装,请重新选择') - // return - // } const setV = {} + if(formField == 'parentCode'){ + setV['type'] = val[0]['type'] + } setV[formField] = val[0][searchField] formRef.setValues(setV) }) @@ -178,6 +177,9 @@ const openForm = (type: string, row?: any) => { if (item.field == 'manageBalance') { item.componentProps.disabled = true } + if (item.field == 'type') { + item.componentProps.disabled = false + } }) }else { Packageunit.allSchemas.formSchema.forEach((item) => { @@ -190,6 +192,9 @@ const openForm = (type: string, row?: any) => { if (item.field == 'manageBalance') { item.componentProps.disabled = false } + if (item.field == 'type') { + item.componentProps.disabled = true + } }) } basicFormRef.value.open(type, row) From 43fd5a23271685c08379f7bf2207a7af18df45fd Mon Sep 17 00:00:00 2001 From: gaojs <757918719@qq.com> Date: Thu, 11 Jul 2024 17:22:56 +0800 Subject: [PATCH 3/9] =?UTF-8?q?WMS:=20=E2=80=94=E2=80=94>=20bug=20=20?= =?UTF-8?q?=E5=8F=91=E8=B4=A7=E8=AE=B0=E5=BD=95=E5=8C=85=E8=A3=85=E8=A7=84?= =?UTF-8?q?=E6=A0=BC=E6=B2=A1=E6=9C=89=E6=98=BE=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../deliver/deliverRecordMain/deliverRecordMain.data.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/views/wms/deliversettlementManage/deliver/deliverRecordMain/deliverRecordMain.data.ts b/src/views/wms/deliversettlementManage/deliver/deliverRecordMain/deliverRecordMain.data.ts index 2192b55f1..c5249f5e5 100644 --- a/src/views/wms/deliversettlementManage/deliver/deliverRecordMain/deliverRecordMain.data.ts +++ b/src/views/wms/deliversettlementManage/deliver/deliverRecordMain/deliverRecordMain.data.ts @@ -530,6 +530,10 @@ export const DeliverRecordDetail = useCrudSchemas(reactive([ { label: '包装规格', field: 'packUnit', + isSearch: false, + isTable: false, + isForm:false, + isDetail:false, sort: 'custom', table: { width: 150 From 1965e3ae3a37a05a38bd46219d7a6d3b399395ca Mon Sep 17 00:00:00 2001 From: zhang_li <2235006734@qqq.com> Date: Thu, 11 Jul 2024 17:41:35 +0800 Subject: [PATCH 4/9] =?UTF-8?q?=E5=89=8D=E7=AB=AF=E5=A2=9E=E5=8A=A0?= =?UTF-8?q?=E6=A0=A1=E9=AA=8C=EF=BC=9A=E5=BD=93=E5=AD=98=E5=9C=A8=E6=89=98?= =?UTF-8?q?=E6=97=B6=EF=BC=8C=E6=89=98=E7=9A=84=E5=8C=85=E8=A3=85=E6=95=B0?= =?UTF-8?q?=E9=87=8F=E8=A6=81=E5=A4=A7=E4=BA=8E=E7=AE=B1=E7=9A=84=E5=8C=85?= =?UTF-8?q?=E8=A3=85=E6=95=B0=E9=87=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../supplierdeliver/supplierdeliverRequestMain/index.vue | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue index f80b4e3e1..86eff1d93 100644 --- a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue +++ b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue @@ -670,6 +670,13 @@ const footButtonClick = async (val) => { message.warning('有数据没有选择箱规格') return } + let isNext1 = detatableData1.value.some((item) => { + return item.secondPackQty && item.packQty && parseFloat(item.packQty) > parseFloat(item.secondPackQty) + }) + if (isNext1) { + message.warning('托的包装数量要大于箱的包装数量,请修改') + return + } const data = JSON.parse(JSON.stringify(detatableData1.value)) labelFormRef.value.openLabel(data) } else if (val == 'close') { From 5d4292c6a09c7ce585179eda1e2f77b72a259210 Mon Sep 17 00:00:00 2001 From: zhang_li <2235006734@qqq.com> Date: Thu, 11 Jul 2024 17:44:14 +0800 Subject: [PATCH 5/9] =?UTF-8?q?=E5=A4=B1=E5=8E=BB=E7=84=A6=E7=82=B9?= =?UTF-8?q?=E6=A0=A1=E9=AA=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/BasicForm/src/BasicForm.vue | 170 +++++++++++++----- .../itemManage/bom/bom.data.ts | 22 ++- 2 files changed, 141 insertions(+), 51 deletions(-) diff --git a/src/components/BasicForm/src/BasicForm.vue b/src/components/BasicForm/src/BasicForm.vue index e162d86d9..0d0a1d608 100644 --- a/src/components/BasicForm/src/BasicForm.vue +++ b/src/components/BasicForm/src/BasicForm.vue @@ -844,79 +844,171 @@ const onBlur = async (field, e) => { let formSchemaObj = formSchema.value.find((item) => item.field == field)?.componentProps if (formSchemaObj?.enterSearch) { - if (formSchemaObj.verificationPage) { - let searchCondition1 = formSchema.value.find((item) => item.field == field).componentProps - .searchCondition //获取data.ts参数信息 - let verificationParams = formSchema.value.find((item) => item.field == field).componentProps - .verificationParams //获取失去焦点参数信息 + if (formSchemaObj.searchPage) { + //获取data.ts参数信息 + let searchCondition = + formSchema.value.find((item) => item.field == field)?.componentProps?.searchCondition || [] + //获取失去焦点参数信息 + let verificationParams = + formSchema.value.find((item) => item.field == field)?.componentProps?.verificationParams || + [] console.log('走新方法啦') + searchCondition = [...searchCondition, ...verificationParams] if (e && isString(e)) { let setV = {} setV[field] = '' let params = {} // 循环参数设置参数为key:value格式 - if (searchCondition1 && searchCondition1.length > 0) { - for (let i = 0; i < searchCondition1.length; i++) { - if (searchCondition1[i].isMainValue) { - params[searchCondition1[i].key] = formRef.value.formModel[searchCondition1[i].value] - ? formRef.value.formModel[searchCondition1[i].value] + // if (searchCondition1 && searchCondition1.length > 0) { + // for (let i = 0; i < searchCondition1.length; i++) { + // searchCondition1[i].isSearch = true + // if (searchCondition1[i].isMainValue) { + // params[searchCondition1[i].key] = formRef.value.formModel[searchCondition1[i].value] + // ? formRef.value.formModel[searchCondition1[i].value] + // : props.detailData + // ? props.detailData[searchCondition1[i].value] + // : '' + // // 是否含有空参数情况 + // let isNull = false + // if (params[searchCondition1[i].key] == '' || params[searchCondition1[i].key] == undefined) { + // isNull = true + // } + // if (isNull) { + // message.warning( + // searchCondition1[i].message ? searchCondition1[i].message : '前置条件未选择!' + // ) + // return + // } + // } else { + // // 扩展 转换为筛选条件进行查询 + // if (searchCondition1[i].isSearch) { + // if (searchCondition1[i].isFormModel) { + // //用formModel中的值 + // if (searchCondition1[i].required) { + // if ( + // formRef.value.formModel[searchCondition1[i].value] == '' || + // formRef.value.formModel[searchCondition1[i].value] == undefined + // ) { + // message.warning( + // searchCondition1[i].message + // ? searchCondition1[i].message + // : '前置条件未选择!' + // ) + // return + // } + // } + // } + // params[searchCondition1[i].key] = searchCondition1[i].value + // } else { + // params[searchCondition1[i].key] = searchCondition1[i].value + // } + // } + // } + // } + // 判断查询条件中,是否存在指向主表的数据 + const _searchCondition = {} + if (searchCondition && searchCondition.length > 0) { + // 转换筛选条件所需 + let filters: any[] = [] + for (var i = 0; i < searchCondition.length; i++) { + // searchCondition.forEach((item) => { + // 查询条件为主表某字段,需要赋值主表数据,数据来源是详情的,赋值需要从row中获取 + if (searchCondition[i].isMainValue) { + _searchCondition[searchCondition[i].key] = formRef.value.formModel[ + searchCondition[i].value + ] + ? formRef.value.formModel[searchCondition[i].value] : props.detailData - ? props.detailData[searchCondition1[i].value] + ? props.detailData[searchCondition[i].value] + : // : row + // ? row[searchCondition[i].value] + e + ? e.trim() : '' // 是否含有空参数情况 let isNull = false - if (params[searchCondition1[i].key] == '' || params[searchCondition1[i].key] == undefined) { + if ( + _searchCondition[searchCondition[i].key] == '' || + _searchCondition[searchCondition[i].key] == undefined + ) { isNull = true } if (isNull) { message.warning( - searchCondition1[i].message ? searchCondition1[i].message : '前置条件未选择!' + searchCondition[i].message ? searchCondition[i].message : '前置条件未选择!' ) return } - } else { + } + // else if (searchCondition[i].isTableRowValue) { + // if (searchCondition[i].required) { + // if (row[searchCondition[i].value] == '' || row[searchCondition[i].value] == undefined) { + // message.warning( + // searchCondition[i].message ? searchCondition[i].message : '前置条件未选择!' + // ) + // return + // } + // } + // row[searchCondition[i].value] + // //查询当前table表数据的值 + // _searchCondition[searchCondition[i].key] = row[searchCondition[i].value] + // } + else { // 扩展 转换为筛选条件进行查询 - if (searchCondition1[i].isSearch) { - if (searchCondition1[i].isFormModel) { + if (searchCondition[i].isSearch) { + if (searchCondition[i].isFormModel) { //用formModel中的值 - if (searchCondition1[i].required) { + if (searchCondition[i].required) { if ( - formRef.value.formModel[searchCondition1[i].value] == '' || - formRef.value.formModel[searchCondition1[i].value] == undefined + formRef.value.formModel[searchCondition[i].value] == '' || + formRef.value.formModel[searchCondition[i].value] == undefined ) { message.warning( - searchCondition1[i].message - ? searchCondition1[i].message - : '前置条件未选择!' + searchCondition[i].message ? searchCondition[i].message : '前置条件未选择!' ) return } } + filters.push({ + action: searchCondition[i].action, + column: searchCondition[i].key, + value: formRef.value.formModel[searchCondition[i].value] + ? formRef.value.formModel[searchCondition[i].value] + : e.trim() + }) + } else { + filters.push({ + action: searchCondition[i].action, + column: searchCondition[i].key, + value: searchCondition[i].value + }) } - params[searchCondition1[i].key] = searchCondition1[i].value } else { - params[searchCondition1[i].key] = searchCondition1[i].value + _searchCondition[searchCondition[i].key] = searchCondition[i].value } } } - } - // 循环参数设置参数为key:value格式 - if (verificationParams && verificationParams.length > 0) { - for (let i = 0; i < verificationParams.length; i++) { - params[verificationParams[i].key] = e?.trim() + if (filters.length > 0) { + _searchCondition.isSearch = true + _searchCondition.filters = filters } } - console.log(333,params) + let obj = { + by: 'ASC', + pageNo: 1, + pageSize: 20 + } + params = { ..._searchCondition, ...obj } + // console.log(333,params) if (!formSchemaObj?.multiple && e.indexOf(',') > -1) { message.alert('该输入框只能输入一条数据') formRef.value.setValues(setV) return } - await formSchemaObj.verificationPage(params).then((res) => { + await formSchemaObj.searchPage(params).then((res) => { let arr1 = e.split(',') let list = ref([]) - list.value = res - console.log(222, list.value) + list.value = res.list if (list.value?.length == 0) { message.alert('暂无数据') formRef.value.setValues(setV) @@ -932,19 +1024,7 @@ const onBlur = async (field, e) => { formRef.value.setValues(setV) return } - // emit('searchTableSuccess', formField, searchField, list.value, formRef.value, 'form') - // callback(list.value) }) - // emit( - // 'onBlur', - // field, - // e, - // formSchemaObj.componentProps.searchField, - // formSchemaObj, - // formRef.value, - // 'form', - // obj - // ) } } else { if ( diff --git a/src/views/wms/basicDataManage/itemManage/bom/bom.data.ts b/src/views/wms/basicDataManage/itemManage/bom/bom.data.ts index e8729c17f..31f22135a 100644 --- a/src/views/wms/basicDataManage/itemManage/bom/bom.data.ts +++ b/src/views/wms/basicDataManage/itemManage/bom/bom.data.ts @@ -32,10 +32,13 @@ export const Bom = useCrudSchemas(reactive([ searchTitle: '物料基础信息', // 查询弹窗标题 searchAllSchemas: Itembasic.allSchemas, // 查询弹窗所需类 searchPage: ItembasicApi.selectItembasicPageToFgAndSemibasicPage, // 查询弹窗所需分页方法 - verificationPage: ItembasicApi.getItemListByCodes, // 失去焦点校验输入框的数据内容存在 verificationParams: [{ - key: 'codes', + key: 'code', + action: '==', value: '', + isMainValue: false, + isSearch: 'true', + isFormModel: true }], // 失去焦点校验参数 } } @@ -58,10 +61,13 @@ export const Bom = useCrudSchemas(reactive([ searchTitle: '物料基础信息', // 查询弹窗标题 searchAllSchemas: Itembasic.allSchemas, // 查询弹窗所需类 searchPage: ItembasicApi.selectTypeToItembasic, // 查询弹窗所需分页方法 - verificationPage: ItembasicApi.getItemListByCodes, // 失去焦点校验输入框的数据内容存在 verificationParams: [{ - key: 'codes', + key: 'code', + action: '==', value: '', + isMainValue: false, + isSearch: 'true', + isFormModel: true }], // 失去焦点校验参数 } } @@ -114,12 +120,16 @@ export const Bom = useCrudSchemas(reactive([ searchCondition: [{ key: 'available', value: 'TRUE', - isMainValue: false + isMainValue: false, }], verificationPage: ProcessApi.getProcessByCodes, // 失去焦点校验输入框的数据内容存在 verificationParams: [{ - key: 'codes', + key: 'code', + action: '==', value: '', + isMainValue: false, + isSearch: 'true', + isFormModel:true }], // 失去焦点校验参数 } } From 2f36630c543852432186b31591b2771104e1f28f Mon Sep 17 00:00:00 2001 From: zhang_li <2235006734@qqq.com> Date: Thu, 11 Jul 2024 17:46:43 +0800 Subject: [PATCH 6/9] =?UTF-8?q?=E5=A4=B1=E5=8E=BB=E7=84=A6=E7=82=B9bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/BasicForm/src/BasicForm.vue | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/components/BasicForm/src/BasicForm.vue b/src/components/BasicForm/src/BasicForm.vue index 0d0a1d608..271d790f8 100644 --- a/src/components/BasicForm/src/BasicForm.vue +++ b/src/components/BasicForm/src/BasicForm.vue @@ -841,10 +841,9 @@ const onChange = (field, cur) => { */ const onBlur = async (field, e) => { isExecute.value = false - let formSchemaObj = formSchema.value.find((item) => item.field == field)?.componentProps if (formSchemaObj?.enterSearch) { - if (formSchemaObj.searchPage) { + if (formSchemaObj.searchPage && formSchemaObj.verificationParams) { //获取data.ts参数信息 let searchCondition = formSchema.value.find((item) => item.field == field)?.componentProps?.searchCondition || [] From 7c309c141b562c7986bc1693a16d7a33fdfd4e68 Mon Sep 17 00:00:00 2001 From: zhang_li <2235006734@qqq.com> Date: Thu, 11 Jul 2024 17:55:19 +0800 Subject: [PATCH 7/9] =?UTF-8?q?=E7=89=A9=E6=96=99=E5=8C=85=E8=A3=85?= =?UTF-8?q?=E4=BF=A1=E6=81=AF=EF=BC=8C=E6=A0=87=E5=87=86=E6=88=90=E6=9C=AC?= =?UTF-8?q?=E5=A4=B1=E5=8E=BB=E7=84=A6=E7=82=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 12 ++++++++++- .../itempackage/itempackage.data.ts | 20 +++++++++++++++++-- .../stdcostprice/stdcostprice.data.ts | 10 +++++++++- 3 files changed, 38 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 7c997d5fa..b50a3f14d 100644 --- a/README.md +++ b/README.md @@ -31,6 +31,7 @@ form: { isFormModel:true, // filters中添加筛选的数据--取于formModel required:true, // 前置添加必有,和isFormModel结合使用 message: '请选择客户代码!', // 前置添加没填的提示语 + }, { key: 'itemCode', @@ -44,7 +45,16 @@ form: { value:'TRUE', // 指查询具体值 isMainValue: false // 表示查询条件不是主表的字段的值 } - ] + ], + // 失去焦点校验参数 + verificationParams: [{ + key: 'code', + action: '==', + value: '', + isMainValue: false, + isSearch: 'true', + isFormModel: true + }] } } **tableForm明细列表查询弹窗配置** diff --git a/src/views/wms/basicDataManage/itemManage/itempackage/itempackage.data.ts b/src/views/wms/basicDataManage/itemManage/itempackage/itempackage.data.ts index fba8c3a25..bc2db8a9f 100644 --- a/src/views/wms/basicDataManage/itemManage/itempackage/itempackage.data.ts +++ b/src/views/wms/basicDataManage/itemManage/itempackage/itempackage.data.ts @@ -34,7 +34,15 @@ export const Itempackaging = useCrudSchemas(reactive([ key: 'available', value: 'TRUE', isMainValue: false - }] + }], + verificationParams: [{ + key: 'code', + action: '==', + value: '', + isMainValue: false, + isSearch: 'true', + isFormModel: true + }], // 失去焦点校验参数 } } }, @@ -78,7 +86,15 @@ export const Itempackaging = useCrudSchemas(reactive([ action: '==', isSearch: true, isMainValue: false - }] + }], + verificationParams: [{ + key: 'code', + action: '==', + value: '', + isMainValue: false, + isSearch: 'true', + isFormModel: true + }], // 失去焦点校验参数 } } }, diff --git a/src/views/wms/basicDataManage/itemManage/stdcostprice/stdcostprice.data.ts b/src/views/wms/basicDataManage/itemManage/stdcostprice/stdcostprice.data.ts index 6dca2f1d6..2ea5edca4 100644 --- a/src/views/wms/basicDataManage/itemManage/stdcostprice/stdcostprice.data.ts +++ b/src/views/wms/basicDataManage/itemManage/stdcostprice/stdcostprice.data.ts @@ -70,7 +70,15 @@ export const Stdcostprice = useCrudSchemas(reactive([ key: 'available', value: 'TRUE', isMainValue: false - }] + }], + verificationParams: [{ + key: 'code', + action: '==', + value: '', + isMainValue: false, + isSearch: 'true', + isFormModel: true + }], // 失去焦点校验参数 } } }, From faa422acb49ba54255f65f35164fa2ed40153cb0 Mon Sep 17 00:00:00 2001 From: zhang_li <2235006734@qqq.com> Date: Thu, 11 Jul 2024 18:03:29 +0800 Subject: [PATCH 8/9] =?UTF-8?q?SCP=20=E4=BE=9B=E5=BA=94=E5=95=86=E5=8F=91?= =?UTF-8?q?=E8=B4=A7=E7=94=B3=E8=AF=B7=20=E7=94=9F=E6=88=90=E6=A0=87?= =?UTF-8?q?=E7=AD=BE=E6=97=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../supplierdeliverRequestMain/labelForm.vue | 22 +++++++++---------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/labelForm.vue b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/labelForm.vue index 65dbdc44a..83247227f 100644 --- a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/labelForm.vue +++ b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/labelForm.vue @@ -438,24 +438,24 @@ const blurOne = (oneRow, twoRow) => { // 托信息修改的時候箱数据自动排列 // 判断箱信息是否存在 if (oneRow.packUnit && oneRow.packQty) { - oneRow.packageList.forEach((cur, key) => { - cur.children = [] + // oneRow.packageList.forEach((cur, key) => { + twoRow.children = [] // 数量除以托数量获取余数 - cur.xLastNumber = parseFloat(cur.xNumber) % parseFloat(oneRow.packQty) - for (let j = 0; j < cur.xNumber; j++) { + twoRow.xLastNumber = parseFloat(twoRow.xNumber) % parseFloat(oneRow.packQty) + for (let j = 0; j < twoRow.xNumber; j++) { twoId.value++ // 如果有余数 - if (cur.xLastNumber) { + if (twoRow.xLastNumber) { // 最后一条信息直接展示余数的信息 - if (j == cur.xNumbery - 1) { - cur.children.push({ + if (j == twoRow.xNumbery - 1) { + twoRow.children.push({ id: twoId.value, xPoNumber: j + 1, - qtyTwo: cur.xLastNumber + qtyTwo: twoRow.xLastNumber }) } else { // 其他数据展示一托的全部箱数和全部数量 - cur.children.push({ + twoRow.children.push({ id: twoId.value, xPoNumber: j + 1, qtyTwo: oneRow.packQty @@ -463,14 +463,14 @@ const blurOne = (oneRow, twoRow) => { } } else { // 如果沒有余数,直接展示一托的全部箱数和全部数量 - cur.children.push({ + twoRow.children.push({ id: twoId.value, xPoNumber: j + 1, qtyTwo: oneRow.packQty }) } } - }) + // }) } } //在托下方的箱数量失去焦点 From b5762ad1f375cf16557f06c132e24481d226a76e Mon Sep 17 00:00:00 2001 From: zhang_li <2235006734@qqq.com> Date: Thu, 11 Jul 2024 18:36:43 +0800 Subject: [PATCH 9/9] =?UTF-8?q?SCP=20=E4=BE=9B=E5=BA=94=E5=95=86=E5=8F=91?= =?UTF-8?q?=E8=B4=A7=E7=94=B3=E8=AF=B7=20=E7=94=9F=E6=88=90=E6=A0=87?= =?UTF-8?q?=E7=AD=BE=E6=97=B6=EF=BC=8C=E6=83=B3=E5=B0=91=E5=8F=91=E5=87=A0?= =?UTF-8?q?=E7=AE=B1=EF=BC=8C=E6=8A=8A=E7=AE=B1=E7=A7=BB=E5=87=BA=E5=90=8E?= =?UTF-8?q?=EF=BC=8C=E4=BF=AE=E6=94=B9=E5=89=A9=E4=BD=99=E7=AE=B1=E4=B8=AD?= =?UTF-8?q?=E7=9A=84=E6=95=B0=E9=87=8F=E3=80=82=E6=97=A0=E6=B3=95=E8=BF=9B?= =?UTF-8?q?=E8=A1=8C=E4=BF=AE=E6=94=B9=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../supplierdeliverRequestMain/labelForm.vue | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/labelForm.vue b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/labelForm.vue index 83247227f..ee81020ce 100644 --- a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/labelForm.vue +++ b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/labelForm.vue @@ -475,11 +475,11 @@ const blurOne = (oneRow, twoRow) => { } //在托下方的箱数量失去焦点 const blurTwo = (oneRow, twoRow, threeRow) => { - if (parseFloat(threeRow.qtyTwo) > parseFloat(oneRow.packQty)) { - message.warning('数量最多为' + oneRow.packQty) - threeRow.qtyTwo = oneRow.packQty - return - } + // if (parseFloat(threeRow.qtyTwo) > parseFloat(oneRow.packQty)) { + // message.warning('数量最多为' + oneRow.packQty) + // threeRow.qtyTwo = oneRow.packQty + // return + // } let num = 0 twoRow.children.forEach((item) => { num += parseFloat(item.qtyTwo) || 0 @@ -488,10 +488,10 @@ const blurTwo = (oneRow, twoRow, threeRow) => { } // 箱数量失去焦点 const blurThree = (oneRow, twoRow, thereeRow) => { - if (parseFloat(thereeRow.qtyTwo) > parseFloat(oneRow.packQty)) { - message.warning('每箱个数最多' + oneRow.packQty) - thereeRow.qtyTwo = oneRow.packQty - } + // if (parseFloat(thereeRow.qtyTwo) > parseFloat(oneRow.packQty)) { + // message.warning('每箱个数最多' + oneRow.packQty) + // thereeRow.qtyTwo = oneRow.packQty + // } let num = 0 twoRow.children.forEach((item) => { num += parseFloat(item.qtyTwo) || 0