mirror of
https://github.com/frappe/erpnext.git
synced 2026-02-19 17:45:04 +00:00
fix: dont update rate of free item on save
(cherry picked from commit 6591e76a63)
This commit is contained in:
@@ -821,7 +821,7 @@ class AccountsController(TransactionBase):
|
|||||||
and item.get("use_serial_batch_fields")
|
and item.get("use_serial_batch_fields")
|
||||||
)
|
)
|
||||||
):
|
):
|
||||||
if fieldname == "batch_no" and not item.batch_no:
|
if fieldname == "batch_no" and not item.batch_no and not item.is_free_item:
|
||||||
item.set("rate", ret.get("rate"))
|
item.set("rate", ret.get("rate"))
|
||||||
item.set("price_list_rate", ret.get("price_list_rate"))
|
item.set("price_list_rate", ret.get("price_list_rate"))
|
||||||
item.set(fieldname, value)
|
item.set(fieldname, value)
|
||||||
|
|||||||
Reference in New Issue
Block a user