mirror of
https://github.com/inventree/InvenTree.git
synced 2026-09-10 06:37:17 +00:00
- Prevent negative pre-fill values
(cherry picked from commit f8328cd1db)
Co-authored-by: Oliver <oliver.henry.walters@gmail.com>
This commit is contained in:
co-authored by
Oliver
parent
2754f8c938
commit
7f9d89d144
@@ -907,7 +907,7 @@ export function useReceiveLineItems(props: LineItemsForm) {
|
||||
// here would make the backend treat this line as if the user
|
||||
// had explicitly chosen the PO's default, blocking any override.
|
||||
location: elem.destination ?? null,
|
||||
quantity: elem.quantity - elem.received,
|
||||
quantity: Math.max(0, elem.quantity - elem.received),
|
||||
expiry_date: null,
|
||||
batch_code: '',
|
||||
serial_numbers: '',
|
||||
|
||||
Reference in New Issue
Block a user