IO-1572 Search bill lines by act price.

This commit is contained in:
Patrick Fic
2021-12-13 13:22:02 -08:00
parent 28cc092bb7
commit a933a1d587

View File

@@ -20,7 +20,11 @@ const BillLineSearchSelect = ({ options, disabled, ...restProps }, ref) => {
.toLowerCase() .toLowerCase()
.includes(inputValue.toLowerCase())) || .includes(inputValue.toLowerCase())) ||
(option.oem_partno && (option.oem_partno &&
option.oem_partno.toLowerCase().includes(inputValue.toLowerCase())) option.oem_partno
.toLowerCase()
.includes(inputValue.toLowerCase())) ||
(option.act_price &&
option.act_price.toString().startsWith(inputValue.toString()))
); );
}} }}
notFoundContent={"Removed."} notFoundContent={"Removed."}
@@ -40,13 +44,14 @@ const BillLineSearchSelect = ({ options, disabled, ...restProps }, ref) => {
line_desc={item.line_desc} line_desc={item.line_desc}
part_qty={item.part_qty} part_qty={item.part_qty}
oem_partno={item.oem_partno} oem_partno={item.oem_partno}
act_price={item.act_price}
style={{ style={{
...(item.removed ? { textDecoration: "line-through" } : {}), ...(item.removed ? { textDecoration: "line-through" } : {}),
}} }}
> >
{`${item.removed ? `(REMOVED) ` : ""}${item.line_desc}${ {`${item.removed ? `(REMOVED) ` : ""}${item.line_desc}${
item.oem_partno ? ` - ${item.oem_partno}` : "" item.oem_partno ? ` - ${item.oem_partno}` : ""
}`} }${item.act_price ? ` - $${item.act_price}` : ``}`}
</Option> </Option>
)) ))
: null} : null}