diff --git a/frontend/src/pages/ConsumableLogs.jsx b/frontend/src/pages/ConsumableLogs.jsx index b752e7f..7dd2af1 100644 --- a/frontend/src/pages/ConsumableLogs.jsx +++ b/frontend/src/pages/ConsumableLogs.jsx @@ -21,6 +21,7 @@ import { Col, Statistic, Divider, + Popover, } from 'antd'; import { HistoryOutlined, @@ -228,6 +229,47 @@ function ConsumableLogs() { width: 150, render: value => value || '-', }, + { + title: 'SN序列号', + dataIndex: 'snList', + key: 'snList', + width: 150, + render: (snList, record) => { + if (!snList || snList.length === 0) { + return '-'; + } + if (record.operationType !== 'in' && record.operationType !== 'out') { + return '-'; + } + if (snList.length <= 3) { + return ( + + {snList.map((sn, index) => ( + + {sn} + + ))} + + ); + } + const content = ( +
+ {snList.map((sn, index) => ( + + {sn} + + ))} +
+ ); + return ( + + + {snList.length} 个SN 🔍 + + + ); + }, + }, { title: '备注', dataIndex: 'notes',