优化代码

main
GaoF 2024-08-20 09:09:50 +08:00
parent de0dddba77
commit 9c1122ea52
3 changed files with 73 additions and 25 deletions

View File

@ -25,7 +25,7 @@ export const detailColumns = [
},
{
title: '完工数量',
dataIndex: 'amount',
dataIndex: 'finishAmount',
width: 200,
resizable: true,
align: 'center',
@ -33,7 +33,7 @@ export const detailColumns = [
},
{
title: '入库数量',
dataIndex: 'amount',
dataIndex: 'storeAmount',
width: 200,
resizable: true,
align: 'center',
@ -41,7 +41,7 @@ export const detailColumns = [
},
{
title: '基本完工数量',
dataIndex: 'basicAmount',
dataIndex: 'basicFinishAmount',
width: 200,
resizable: true,
align: 'center',
@ -49,7 +49,7 @@ export const detailColumns = [
},
{
title: '基本入库数量',
dataIndex: 'basicAmount',
dataIndex: 'basicStoreAmount',
width: 200,
resizable: true,
align: 'center',
@ -79,17 +79,17 @@ export const detailColumns = [
align: 'center',
ellipsis: true
},
{
title: '包装数量',
dataIndex: 'name',
width: 200,
resizable: true,
align: 'center',
ellipsis: true
},
// {
// title: '包装数量',
// dataIndex: 'name',
// width: 200,
// resizable: true,
// align: 'center',
// ellipsis: true
// },
{
title: '采集失败数',
dataIndex: 'name',
dataIndex: 'collectFailAmount',
width: 200,
resizable: true,
align: 'center',
@ -97,15 +97,31 @@ export const detailColumns = [
},
{
title: '采集成功率',
dataIndex: 'name',
dataIndex: 'collectSuccessRate',
width: 200,
resizable: true,
align: 'center',
ellipsis: true
},
{
title: '生产率',
dataIndex: 'name',
title: '生产日期',
dataIndex: 'collectSuccessRate',
width: 200,
resizable: true,
align: 'center',
ellipsis: true
},
{
title: '生产类型',
dataIndex: 'collectSuccessRate',
width: 200,
resizable: true,
align: 'center',
ellipsis: true
},
{
title: '生产类型',
dataIndex: 'collectSuccessRate',
width: 200,
resizable: true,
align: 'center',
@ -139,7 +155,7 @@ export const modalColumns = [
},
{
title: '条码类型',
dataIndex: 'unitName',
dataIndex: 'barcodeType',
width: 200,
resizable: true,
align: 'center',
@ -163,7 +179,7 @@ export const modalColumns = [
},
{
title: '数量',
dataIndex: '',
dataIndex: 'amount',
width: 200,
resizable: true,
align: 'center',
@ -179,7 +195,7 @@ export const modalColumns = [
},
{
title: '基本数量',
dataIndex: 'parentBarcode',
dataIndex: 'basicAmount',
width: 200,
resizable: true,
align: 'center',
@ -187,7 +203,7 @@ export const modalColumns = [
},
{
title: '基本单位',
dataIndex: 'baseUnitNames',
dataIndex: 'baseUnitName',
width: 200,
resizable: true,
align: 'center',
@ -195,10 +211,42 @@ export const modalColumns = [
},
{
title: '子码数',
dataIndex: 'parentBarcode',
dataIndex: 'subAmount',
width: 200,
resizable: true,
align: 'center',
ellipsis: true
}
},
{
title: '批次',
dataIndex: 'specification',
width: 200,
resizable: true,
align: 'center',
ellipsis: true
},
{
title: '打码时间',
dataIndex: 'subAmount',
width: 200,
resizable: true,
align: 'center',
ellipsis: true
},
{
title: '扫描时间',
dataIndex: 'scanTime',
width: 200,
resizable: true,
align: 'center',
ellipsis: true
},
{
title: '扫描人',
dataIndex: 'createUserName',
width: 200,
resizable: true,
align: 'center',
ellipsis: true
},
]

View File

@ -43,7 +43,7 @@ export const reportColumns = [
},
{
title: '创建人',
dataIndex: 'createUser',
dataIndex: 'createUserName',
width: 200,
resizable: true,
align: 'center',

View File

@ -130,14 +130,14 @@
if (expanded) {
producePackageBarcodeApi
.producePackageBarcodeTreeChildrenList({
reportDetailId: record.id,
reportDetailId: record.reportDetailId,
reportId: record.reportId,
parentBarcode: record.barcode
})
.then((res) => {
record.children = res
record.children.forEach((item) => {
if (item.subAmount > 0) item.children = []
item.children = []
})
})
}