Cleanup
This commit is contained in:
parent
2712375ae9
commit
26bb06cb29
|
|
@ -14,7 +14,6 @@ import {
|
|||
import { AddItemButton } from '@lib/components/AddItemButton';
|
||||
import { identifierString } from '@lib/functions/Conversion';
|
||||
import type { ApiFormFieldType } from '@lib/types/Forms';
|
||||
import { useWhyDidYouUpdate } from '../../../functions/debug';
|
||||
import { InvenTreeIcon } from '../../../functions/icons';
|
||||
import { StandaloneField } from '../StandaloneField';
|
||||
|
||||
|
|
@ -268,13 +267,6 @@ function TableFieldComponent({
|
|||
[error]
|
||||
);
|
||||
|
||||
useWhyDidYouUpdate(`TableField-${fieldName}`, {
|
||||
definition,
|
||||
fieldName,
|
||||
value,
|
||||
error
|
||||
});
|
||||
|
||||
return (
|
||||
<Table
|
||||
highlightOnHover
|
||||
|
|
|
|||
|
|
@ -37,7 +37,6 @@ import {
|
|||
RenderStockItem,
|
||||
RenderStockLocation
|
||||
} from '../components/render/Stock';
|
||||
import { useWhyDidYouUpdate } from '../functions/debug';
|
||||
import { useCreateApiFormModal } from '../hooks/UseForm';
|
||||
import {
|
||||
useBatchCodeGenerator,
|
||||
|
|
@ -266,12 +265,6 @@ function BuildOutputFormRow({
|
|||
record: any;
|
||||
withQuantityColumn?: boolean;
|
||||
}>) {
|
||||
useWhyDidYouUpdate('BuildOutputFormRow', {
|
||||
props,
|
||||
record,
|
||||
withQuantityColumn
|
||||
});
|
||||
|
||||
const stockItemColumn = useMemo(() => {
|
||||
if (record.serial) {
|
||||
return `# ${record.serial}`;
|
||||
|
|
@ -588,13 +581,6 @@ function BuildAllocateLineRow({
|
|||
record: any;
|
||||
sourceLocation: number | undefined;
|
||||
}>) {
|
||||
useWhyDidYouUpdate('BuildAllocateLineRow', {
|
||||
props,
|
||||
output,
|
||||
record,
|
||||
sourceLocation
|
||||
});
|
||||
|
||||
const [quantity, setQuantity] = useState<number>(props.item?.quantity ?? 0);
|
||||
|
||||
const stockField: ApiFormFieldType = useMemo(() => {
|
||||
|
|
@ -706,14 +692,6 @@ export function useAllocateStockToBuildForm({
|
|||
lineItems: any[];
|
||||
onFormSuccess: (response: any) => void;
|
||||
}) {
|
||||
useWhyDidYouUpdate('useAllocateStockToBuildForm', {
|
||||
buildId,
|
||||
output,
|
||||
outputId,
|
||||
build,
|
||||
lineItems
|
||||
});
|
||||
|
||||
const [sourceLocation, setSourceLocation] = useState<number | undefined>(
|
||||
undefined
|
||||
);
|
||||
|
|
@ -856,8 +834,6 @@ function BuildConsumeItemRow({
|
|||
[props.changeFn]
|
||||
);
|
||||
|
||||
useWhyDidYouUpdate('BuildConsumeItemRow', { props, record, quantity });
|
||||
|
||||
return (
|
||||
<Table.Tr key={`table-row-${record.pk}`}>
|
||||
<Table.Td>
|
||||
|
|
|
|||
|
|
@ -26,7 +26,6 @@ import type {
|
|||
} from '@lib/types/Forms';
|
||||
import dayjs from 'dayjs';
|
||||
import type { TableFieldRowProps } from '../components/forms/fields/TableField';
|
||||
import { useWhyDidYouUpdate } from '../functions/debug';
|
||||
import useBackgroundTask from '../hooks/UseBackgroundTask';
|
||||
import { useCreateApiFormModal, useEditApiFormModal } from '../hooks/UseForm';
|
||||
import { useGlobalSettingsState } from '../states/SettingsStates';
|
||||
|
|
@ -311,12 +310,6 @@ function SalesOrderAllocateLineRow({
|
|||
record: any;
|
||||
sourceLocation?: number | null;
|
||||
}>) {
|
||||
useWhyDidYouUpdate('SalesOrderAllocateLineRow', {
|
||||
props,
|
||||
record,
|
||||
sourceLocation
|
||||
});
|
||||
|
||||
// Statically defined field for selecting the stock item
|
||||
const stockItemField: ApiFormFieldType = useMemo(() => {
|
||||
return {
|
||||
|
|
|
|||
|
|
@ -56,7 +56,6 @@ import {
|
|||
import { Thumbnail } from '../components/images/Thumbnail';
|
||||
import { StatusRenderer } from '../components/render/StatusRenderer';
|
||||
import { RenderStockLocation } from '../components/render/Stock';
|
||||
import { useWhyDidYouUpdate } from '../functions/debug';
|
||||
import { InvenTreeIcon } from '../functions/icons';
|
||||
import {
|
||||
useApiFormModal,
|
||||
|
|
@ -679,18 +678,6 @@ function StockOperationsRow({
|
|||
}) {
|
||||
const rowId = props.rowId;
|
||||
|
||||
useWhyDidYouUpdate('StockOperationsRow', {
|
||||
props,
|
||||
transfer,
|
||||
changeStatus,
|
||||
add,
|
||||
setMax,
|
||||
merge,
|
||||
transferMerge,
|
||||
returnStock,
|
||||
record
|
||||
});
|
||||
|
||||
const statusOptions: ApiFormFieldChoice[] = useMemo(() => {
|
||||
return (
|
||||
StatusFilterOptions(ModelType.stockitem)()?.map((choice) => {
|
||||
|
|
|
|||
|
|
@ -7,7 +7,6 @@ import { useMemo, useState } from 'react';
|
|||
import RemoveRowButton from '../components/buttons/RemoveRowButton';
|
||||
import { StandaloneField } from '../components/forms/StandaloneField';
|
||||
import type { TableFieldRowProps } from '../components/forms/fields/TableField';
|
||||
import { useWhyDidYouUpdate } from '../functions/debug';
|
||||
import { useCreateApiFormModal } from '../hooks/UseForm';
|
||||
import { useGlobalSettingsState } from '../states/SettingsStates';
|
||||
import { RenderPartColumn } from '../tables/ColumnRenderers';
|
||||
|
|
@ -111,12 +110,6 @@ function TransferOrderAllocateLineRow({
|
|||
record: any;
|
||||
sourceLocation?: number | null;
|
||||
}>) {
|
||||
useWhyDidYouUpdate('TransferOrderAllocateLineRow', {
|
||||
props,
|
||||
record,
|
||||
sourceLocation
|
||||
});
|
||||
|
||||
const [quantity, setQuantity] = useState<number | ''>(
|
||||
props.item?.quantity ?? ''
|
||||
);
|
||||
|
|
|
|||
Loading…
Reference in New Issue