mirror of
https://github.com/frappe/erpnext.git
synced 2026-03-22 03:35:43 +00:00
fix: add multiple item issue in stock entry (#45544)
(cherry picked from commit 5a023dc8d4)
Co-authored-by: Ejaaz Khan <67804911+iamejaaz@users.noreply.github.com>
This commit is contained in:
@@ -906,7 +906,12 @@ frappe.ui.form.on("Stock Entry Detail", {
|
|||||||
var d = locals[cdt][cdn];
|
var d = locals[cdt][cdn];
|
||||||
$.each(r.message, function (k, v) {
|
$.each(r.message, function (k, v) {
|
||||||
if (v) {
|
if (v) {
|
||||||
frappe.model.set_value(cdt, cdn, k, v); // qty and it's subsequent fields weren't triggered
|
// set_value trigger barcode function and barcode set qty to 1 in stock_controller.js, to avoid this set value manually instead of set value.
|
||||||
|
if (k != "barcode") {
|
||||||
|
frappe.model.set_value(cdt, cdn, k, v); // qty and it's subsequent fields weren't triggered
|
||||||
|
} else {
|
||||||
|
d.barcode = v;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
refresh_field("items");
|
refresh_field("items");
|
||||||
|
|||||||
Reference in New Issue
Block a user