mirror of
https://gitlab.com/mbugroup/lti-web-client.git
synced 2026-05-25 07:45:47 +00:00
chore: prettier format
This commit is contained in:
@@ -153,8 +153,14 @@ const InventoryAdjustmentTable = () => {
|
||||
updateFilter('productFilter', values.product_id || '');
|
||||
updateFilter('warehouseFilter', values.warehouse_id || '');
|
||||
updateFilter('transactionTypeFilter', values.transaction_type || '');
|
||||
updateFilter('productName', productIdValue?.label ? String(productIdValue.label) : '');
|
||||
updateFilter('warehouseName', warehouseIdValue?.label ? String(warehouseIdValue.label) : '');
|
||||
updateFilter(
|
||||
'productName',
|
||||
productIdValue?.label ? String(productIdValue.label) : ''
|
||||
);
|
||||
updateFilter(
|
||||
'warehouseName',
|
||||
warehouseIdValue?.label ? String(warehouseIdValue.label) : ''
|
||||
);
|
||||
filterModal.closeModal();
|
||||
setSubmitting(false);
|
||||
},
|
||||
@@ -216,7 +222,10 @@ const InventoryAdjustmentTable = () => {
|
||||
val: OptionType | OptionType[] | null
|
||||
) => {
|
||||
const warehouse = val as OptionType | null;
|
||||
formik.setFieldValue('warehouse_id', warehouse?.value ? String(warehouse.value) : null);
|
||||
formik.setFieldValue(
|
||||
'warehouse_id',
|
||||
warehouse?.value ? String(warehouse.value) : null
|
||||
);
|
||||
};
|
||||
|
||||
const handleFilterTransactionTypeChange = useCallback(
|
||||
@@ -236,7 +245,10 @@ const InventoryAdjustmentTable = () => {
|
||||
);
|
||||
if (found) return found;
|
||||
if (tableFilterState.productName) {
|
||||
return { value: formik.values.product_id, label: tableFilterState.productName };
|
||||
return {
|
||||
value: formik.values.product_id,
|
||||
label: tableFilterState.productName,
|
||||
};
|
||||
}
|
||||
return null;
|
||||
}, [formik.values.product_id, productOptions, tableFilterState.productName]);
|
||||
@@ -248,10 +260,17 @@ const InventoryAdjustmentTable = () => {
|
||||
);
|
||||
if (found) return found;
|
||||
if (tableFilterState.warehouseName) {
|
||||
return { value: formik.values.warehouse_id, label: tableFilterState.warehouseName };
|
||||
return {
|
||||
value: formik.values.warehouse_id,
|
||||
label: tableFilterState.warehouseName,
|
||||
};
|
||||
}
|
||||
return null;
|
||||
}, [formik.values.warehouse_id, warehouseOptions, tableFilterState.warehouseName]);
|
||||
}, [
|
||||
formik.values.warehouse_id,
|
||||
warehouseOptions,
|
||||
tableFilterState.warehouseName,
|
||||
]);
|
||||
|
||||
const transactionTypeValue = useMemo(() => {
|
||||
if (!formik.values.transaction_type) return null;
|
||||
|
||||
Reference in New Issue
Block a user