mirror of
https://github.com/inventree/InvenTree.git
synced 2025-11-13 11:26:42 +00:00
Bug fix for pack quantity display (#10810)
This commit is contained in:
@@ -13,7 +13,6 @@ import { ApiEndpoints } from '@lib/enums/ApiEndpoints';
|
|||||||
import { ModelType } from '@lib/enums/ModelType';
|
import { ModelType } from '@lib/enums/ModelType';
|
||||||
import { UserRoles } from '@lib/enums/Roles';
|
import { UserRoles } from '@lib/enums/Roles';
|
||||||
import { apiUrl } from '@lib/functions/Api';
|
import { apiUrl } from '@lib/functions/Api';
|
||||||
import { formatDecimal } from '@lib/functions/Formatting';
|
|
||||||
import type { TableFilter } from '@lib/types/Filters';
|
import type { TableFilter } from '@lib/types/Filters';
|
||||||
import type { TableColumn } from '@lib/types/Tables';
|
import type { TableColumn } from '@lib/types/Tables';
|
||||||
import { IconPackageImport } from '@tabler/icons-react';
|
import { IconPackageImport } from '@tabler/icons-react';
|
||||||
@@ -112,7 +111,6 @@ export function SupplierPartTable({
|
|||||||
{
|
{
|
||||||
accessor: 'pack_quantity',
|
accessor: 'pack_quantity',
|
||||||
sortable: true,
|
sortable: true,
|
||||||
|
|
||||||
render: (record: any) => {
|
render: (record: any) => {
|
||||||
const part = record?.part_detail ?? {};
|
const part = record?.part_detail ?? {};
|
||||||
|
|
||||||
@@ -120,7 +118,7 @@ export function SupplierPartTable({
|
|||||||
|
|
||||||
if (part.units) {
|
if (part.units) {
|
||||||
extra.push(
|
extra.push(
|
||||||
<Text key='base'>
|
<Text key='base' size='sm'>
|
||||||
{t`Base units`} : {part.units}
|
{t`Base units`} : {part.units}
|
||||||
</Text>
|
</Text>
|
||||||
);
|
);
|
||||||
@@ -128,7 +126,7 @@ export function SupplierPartTable({
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<TableHoverCard
|
<TableHoverCard
|
||||||
value={formatDecimal(record.pack_quantity)}
|
value={record.pack_quantity}
|
||||||
extra={extra}
|
extra={extra}
|
||||||
title={t`Pack Quantity`}
|
title={t`Pack Quantity`}
|
||||||
/>
|
/>
|
||||||
|
|||||||
Reference in New Issue
Block a user