From 46ddccccd5b797feaa52973fa36922df6a98d6f6 Mon Sep 17 00:00:00 2001 From: zhang_li <2235006734@qqq.com> Date: Sat, 13 Jul 2024 13:06:10 +0800 Subject: [PATCH] =?UTF-8?q?BOM=E5=AD=97=E6=AE=B5=E4=B8=AD=E7=9A=84?= =?UTF-8?q?=E7=89=A9=E6=96=99=E6=89=B9=E6=AC=A1=E7=94=B1=E5=85=A8=E9=83=A8?= =?UTF-8?q?=E6=89=8B=E5=B7=A5=E5=A1=AB=E5=86=99=E5=BD=A2=E5=BC=8F=E6=94=B9?= =?UTF-8?q?=E4=B8=BA=E7=B3=BB=E7=BB=9F=E9=BB=98=E8=AE=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../productscrapRequestMain/index.vue | 22 ++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/src/views/wms/productionManage/productscrap/productscrapRequestMain/index.vue b/src/views/wms/productionManage/productscrap/productscrapRequestMain/index.vue index 55a76f671..8f48623fe 100644 --- a/src/views/wms/productionManage/productscrap/productscrapRequestMain/index.vue +++ b/src/views/wms/productionManage/productscrap/productscrapRequestMain/index.vue @@ -119,6 +119,7 @@ import * as StdcostpriceApi from '@/api/wms/stdcostprice' import * as defaultButtons from '@/utils/disposition/defaultButtons' import * as BomDismantleApi from "@/api/wms/bomDismantle" import * as BomApi from "@/api/wms/bom"; +import * as BalanceApi from "@/api/wms/balance"; // 制品报废申请 defineOptions({ name: 'ProductscrapRequestMain' }) @@ -211,6 +212,22 @@ const buttonBaseClickBom = (val) => { detailBomRef.value.dialogVisible = false } } +const banchBomPage = async (fromLocationCode,item) => { + const params = { + location_code:fromLocationCode, + itemCode:item.itemCode, + pageSize: 20, + pageNo: 1, + sort:'' , + by: 'ASC', + } + const list = await BalanceApi.getBanchBomPage(params) + const obj =list[0] + console.log(list); + return obj + +} + // 新增 tableform 按钮 const buttonOperationClick = async (row, label, index)=> { if (row.itemCode == '') { @@ -227,7 +244,8 @@ const buttonOperationClick = async (row, label, index)=> { bomModelVisible.value = true await getDetailListBom() console.log(row.fromLocationCode); - detatableDataBom.tableList.forEach(item => { + detatableDataBom.tableList.forEach(async item => { + console.log(333,item) ProdcutscrapBomScrap.allSchemas.tableFormColumns.map((bomItem) => { if (bomItem.field == 'batch') { let condition = [{ @@ -256,6 +274,8 @@ const buttonOperationClick = async (row, label, index)=> { }else { item.qty = item.bomQty * row.qty } + const obj = await banchBomPage(row.fromLocationCode, item) + item.batch = obj.batch }) detailBomRef.value.open('create', row, null,'viewDetail')//查看明细数据 }