mirror of
https://github.com/frappe/erpnext.git
synced 2026-03-18 09:47:14 +00:00
fix: Increase quantity by 1 UOM when adding an item from the selector in POS
(cherry picked from commit bbab850135)
This commit is contained in:
committed by
Mergify
parent
20d0e95d7c
commit
0d3802873b
@@ -556,7 +556,9 @@ erpnext.PointOfSale.Controller = class {
|
|||||||
const item_row_exists = !$.isEmptyObject(item_row);
|
const item_row_exists = !$.isEmptyObject(item_row);
|
||||||
|
|
||||||
const from_selector = field === "qty" && value === "+1";
|
const from_selector = field === "qty" && value === "+1";
|
||||||
if (from_selector) value = flt(item_row.stock_qty) + flt(value);
|
if (from_selector) {
|
||||||
|
value = flt(item_row.qty) + 1; // increase qty by 1 UOM
|
||||||
|
}
|
||||||
|
|
||||||
if (item_row_exists) {
|
if (item_row_exists) {
|
||||||
if (field === "qty") value = flt(value);
|
if (field === "qty") value = flt(value);
|
||||||
|
|||||||
Reference in New Issue
Block a user