2
0
mirror of https://github.com/inventree/InvenTree.git synced 2026-03-31 08:31:04 +00:00

Add copy function to more columns (#11635)

This commit is contained in:
Oliver
2026-03-31 00:22:28 +11:00
committed by GitHub
parent 77744aeeac
commit 4c0a3c5545
4 changed files with 8 additions and 1 deletions

View File

@@ -151,7 +151,9 @@ export default function BuildAllocatedStockTable({
accessor: 'sku',
title: t`Supplier Part`,
render: (record: any) => record?.supplier_part_detail?.SKU,
sortable: true
sortable: true,
copyable: true,
copyAccessor: 'supplier_part_detail.SKU'
}
];
}, []);

View File

@@ -39,6 +39,7 @@ export function PartCategoryTable({ parentId }: Readonly<{ parentId?: any }>) {
accessor: 'name',
sortable: true,
switchable: false,
copyable: true,
render: (record: any) => (
<Group gap='xs' wrap='nowrap' justify='space-between'>
<Group gap='xs' wrap='nowrap'>
@@ -60,6 +61,7 @@ export function PartCategoryTable({ parentId }: Readonly<{ parentId?: any }>) {
DescriptionColumn({}),
{
accessor: 'pathstring',
copyable: true,
sortable: true
},
{

View File

@@ -72,6 +72,7 @@ export function RelatedPartTable({
accessor: 'ipn',
title: t`IPN`,
switchable: true,
copyable: true,
render: (record: any) => {
const part = getPart(record);
return part.IPN;

View File

@@ -68,6 +68,7 @@ export function StockLocationTable({ parentId }: Readonly<{ parentId?: any }>) {
{
accessor: 'name',
switchable: false,
copyable: true,
render: (record: any) => (
<Group gap='xs'>
{record.icon && <ApiIcon name={record.icon} />}
@@ -78,6 +79,7 @@ export function StockLocationTable({ parentId }: Readonly<{ parentId?: any }>) {
DescriptionColumn({}),
{
accessor: 'pathstring',
copyable: true,
sortable: true
},
{