chore: prettier format

This commit is contained in:
ValdiANS
2026-04-27 10:49:07 +07:00
parent 6cf8e463c6
commit f9d2a875e2
11 changed files with 280 additions and 148 deletions
@@ -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;