diff --git a/client/src/components/bill-line-search-select/bill-line-search-select.component.jsx b/client/src/components/bill-line-search-select/bill-line-search-select.component.jsx index 66a67c7d5..dd5558f85 100644 --- a/client/src/components/bill-line-search-select/bill-line-search-select.component.jsx +++ b/client/src/components/bill-line-search-select/bill-line-search-select.component.jsx @@ -12,7 +12,18 @@ const BillLineSearchSelect = ({ options, disabled, ...restProps }, ref) => { disabled={disabled} ref={ref} showSearch - optionFilterProp="line_desc" + // optionFilterProp="line_desc" + filterOption={(inputValue, option) => { + console.log(inputValue); + return ( + (option.line_desc && + option.line_desc + .toLowerCase() + .includes(inputValue.toLowerCase())) || + (option.oem_partno && + option.oem_partno.toLowerCase().includes(inputValue.toLowerCase())) + ); + }} notFoundContent={"Removed."} {...restProps} > @@ -29,6 +40,7 @@ const BillLineSearchSelect = ({ options, disabled, ...restProps }, ref) => { part_type={item.part_type} line_desc={item.line_desc} part_qty={item.part_qty} + oem_partno={item.oem_partno} style={{ ...(item.removed ? { textDecoration: "line-through" } : {}), }}